Welcome to the new Gigaspaces XAP forum. To recover your account, please follow these instructions.

Ask Your Question
0

ExternalEntry help

I'm experimenting with the .NET API and I am able to write to a space using ExternalEntry.

When I take from the space, my .NET app throws a: {code} Unhandled Exception: System.Exception: Do not have knowledge of type at GigaSpaces.Converter.getObject(ExternalEntry ee) at GigaSpaces.Converter.getObject(Object ee) at GigaSpaces.GigaSpace.take(Object template, Transaction tx, Int64 timeOut) {code}

I'm assuming because I do not have a matching class on my .NET side that matches the class name I'm taking.

What I'm trying to accomplish is have a .NET client that writes to a space, Java services perform actions on these objects and write new ones, and the new objects are taken back by the .NET client.

Ideally, I do not want to have to maintain matching objects on both the Java and .NET side and would prefer that the .NET client interacts directly with ExternalEntry.

Am I barking up the wrong tree? Is this possible?

Thanks, Michael

{quote}This thread was imported from the previous forum. For your reference, the original is [available here|http://forum.openspaces.org/thread.jspa?threadID=2116]{quote}

asked 2007-07-19 12:08:05 -0500

mmorowitz gravatar image

updated 2013-08-08 09:52:00 -0500

jaissefsfex gravatar image
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
0

Michael,

The best approach to implement native interoperability with GigaSpaces is to go the POJO/PONO/POCO (will be part of 6.x) path.
The usage of the ExternalEntry within the product has been enhanced especially with the PONO and POCO API. There are several optimizations done that allows in fact .Net PONO/POCO API to provide better performance than the old ExternalEntry.
The underlying interoperability technology using GigaSpaces PBS library (Portable Binary Serialization) that allows GigaSpaces to marshal/demarshal (you can call this also GigaSpaces natural serialization/de-serialization) objects at their native runtime environment , send these to the space and later retrieve them back into another different runtime environment and materialize them within their natural runtime environment - i.e. .Net PONO written to the space and later read from the space by Java application with a POJO and vice versa.

The PBS technology will support also marshal/demarshal complex object graph in native manner - i.e. a POCO space entry written in C++ into the space with attribute that is an object graph (collection of values) could be read by Java application using matching POJO class. So we do not recommend using the ExternalEntry as generic mediator to implement interoperability , but to go directly via the programming language user Class.

You can find running example illustrating Java/.Net interoperability at:
\GigaSpacesEE6.0\dotnet\examples\DotNetJava - This is using POJO/PONO approach
\GigaSpacesEE5.2\dotnet\examples\DotNetJava - This is using ExternalEntry approach

Shay

answered 2007-07-21 21:08:01 -0500

shay hassidim gravatar image
edit flag offensive delete link more
0

So, to make this work, I've had to create a dotnet version of my result object and cast my take directly to that type.

So, at least I have something that works.

I had hoped that I would not have to maintain any dotnet domain classes, but rather deal only in ExternalEntries, but this hasn't been possible for me yet.

answered 2007-07-20 12:11:00 -0500

mmorowitz gravatar image
edit flag offensive delete link more

Comments

Thanks, Shay.

Ultimately I'd like to distribute this .NET client (as part of an Excel spreadsheet) within our organization. Invoking the .NET API on client machines produces the error message that I need to set JSHOMEDIR to the Gigaspaces install directory. I certainly don't want to distribute Gigaspaces to each of our client desktops.

Is there a way around this?

mmorowitz gravatar imagemmorowitz ( 2007-07-23 09:58:00 -0500 )edit

We are working these days providing Excel server demo that will avoid the need to have any GigaSpaces libraries at the client side. Please contact support for additional details about this demo.

Shay

shay hassidim gravatar imageshay hassidim ( 2007-08-09 17:52:02 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2007-07-19 12:08:05 -0500

Seen: 83 times

Last updated: Jul 20 '07