Archived

This forum has been archived. Please start a new discussion on GitHub.

Possible to generate slice code from .net dlls?

Hi,

I'm currently evaluating Ice as a replacement for WCF as our communication middleware. To be able to get some meaningful data for comparison, I wanted to see how ICE would perform on some of our most complex data structures.

My first attempt was to use the new native serialization option. But as this uses the .NET BinaryFormatter the performance isn't very good. I assume a type defined in the slice language would use another serialization method that would have far better performance. My next approach is then to get the "proper" ICE serialization of our types, but this requires a complete set of .ice definitions which would be very time consuming to create.

Is it possible to generate these .ice files from .net source or dlls? Or would we have to manually write slice code for all our types?

Comments

  • matthew
    matthew NL, Canada
    No, that isn't possible. Furthermore, history has shown us that such tools don't work very well (see the CORBA java to IDL mapping for an example).

    What type of data are you encoding? Is the data inherently big and complex, and so you'd expect the encoding to be slow?
  • Hi,

    I am trying to encode the complete graph of one of one of our most complex types. (The "policy" in our insurance model). This is by nature large and complex with objects of many other types as part of the object graph.

    I'll try to extract a smaller part of it and create the necessary slice definitions.

    Thanks for the quick response.
  • matthew
    matthew NL, Canada
    Keep in mind that with Slice this may not be the right approach. Since Ice has much more sophisticated object model than WCF you might consider a architecture that doesn't have large graphs of objects moving around the system. Although the performance of the Ice encoding is very fast, if you translate your system directly without taking advantage of the richer object model, you might not get the performance increase you anticipate.