[OS] Java, Java Tools and OS services

gregb gregb at grotto-networking.com
Thu Apr 24 13:11:41 EDT 2008


Thanks for the quick reply Jun Ma. I'll pass on the JAXB for right now
and dig straight into the OSJava code. I downloaded it and was able to
get it to build within Netbeans 6.1. The big attraction of JAXB was
since it is derived directly from the schema it would be up to date
with the Schema. Agree with you on JNI, its quite ugly, I've looked at
it myself several times but never deemed it worth the hassle.

What I didn't see from the code is whether there is a way (via Java
and the executable) to stop computations at in intermediate point
(e.g. I'm using MILP solvers such as CBC and sometimes just happy to
grab a feasible or improved solution).  What files should I look at
for this?

If I can pull this stuff together, I'll try to put together a tutorial
for newbies on using Java and OS particularly locally.

Regards

Greg B.


On Apr 23, 5:55 pm, "Jun Ma" <m... at northwestern.edu> wrote:
> Greg,
> Thanks for the comments. My answers below.
>
> > I had a couple questions concerning the Java code.  It looks to me
> > that the Java code doesn't use the JNI mechanisms but rather an
> > operating system call to launch the native C++ executable.  Is this
> > correct?
>
> This is correct.
> We used JNI for a while, but for various reasons we switched to using the
> executable.
> JNI is not stable and when used on the server, exceptions that happen within
> JNI can crash the server.
> On the other hand, a call through the executable is cleaner, more flexible
> and robust.
> Compared with the time it takes to run the optimization, the overhead of
> launching the process is trivial.
>
> > Has anyone used JAXB (Java XML Bindings) on the schemas?
>
> Long time ago, I used it (before I came up with the OSInstance) and recently
> some other users also reported using it.
> You can use JAXB, or feel free to use our customized binding, which is the
> standard OSInstance object.
> Our binding (i.e. OSInstance) is cleaner, closer to the semantics of
> "optimization" and facilitates computation besides just parsing.
> But JAXB should be fine.
>
> > I just ran OSiL (OSgL) through the schema-to-Java compiler (known as XJC)
> > and had
> > a few name collisions in the conversion to Java (that can be fixed
> > through some JAXB mechanisms). This generates a ton of Java classes
> > that can be used to form model instances.
>
> This is another reason that we use OSInstance.
>
> > Unfortunately, there seems
> > to be a bug in in JAXB not correctly handling the double INF and -INF
> > values correctly. I sent a message to the JAXB folks on this.  If
> > folks are interested in Java I can let folks know how this experiment
> > works out. I'll also be looking at the Web Services tools applied to
> > the WSDL files.
>
> It would definitely be very helpful. Actually it would be very good that
> there are some documented formal procedure for interested users to try JAXB.
> We would be grateful if you can tell us how the experiment works out.
>
> Thanks Greg,
>
> Jun Ma
> IEMS
> Northwestern University
>
> > Regards
>
> > Greg B.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Optimization Services (OS)" group.
To post to this group, send email to optimizationservices at googlegroups.com
To unsubscribe from this group, send email to optimizationservices-unsubscribe at googlegroups.com
For more options, visit this group at http://groups.google.com/group/optimizationservices?hl=en
-~----------~----~----~----~------~----~------~--~---



More information about the OS mailing list