users@glassfish.java.net

RE: RE: JNI/CompositeApp/Glassfish

From: Markus Karg <karg_at_quipsy.de>
Date: Fri, 29 May 2009 12:14:13 +0200

The idea of EJB is to have a portable application which runs on any
application server on any operating system on any hardware platform. JNI
works only with a particular operating system and hardware platform.
These two core ideas are absolutely not compatible. It just makes no
sense to use EJB directly with JNI. If native stuff is needed in an
enterprise application, it has to be provided in the form of a JCA 1.5
adapter. This is the official Java EE solution to bind portable
applications (EJB) to platform-specific code (JNI). What problem do you
have with that?

 

From: Martin, Ray [mailto:armart3_at_tycho.ncsc.mil]
Sent: Freitag, 29. Mai 2009 12:08
To: users_at_glassfish.dev.java.net
Subject: RE: JNI/CompositeApp/Glassfish

 

Very smart people created JNI.

Very smart people created EJB.

 

These very smart people make sure that JNI cannot operate within EJB -
why would people do something like that?

 

i have fuddled for months building a system around glassfish - now it
looks like i am back to ServiceMix, where i was a year ago

 

________________________________

From: Martin, Ray
Sent: Thursday, May 28, 2009 12:54 PM
To: users_at_glassfish.dev.java.net
Subject: JNI/CompositeApp/Glassfish

Does anyone have a JNI application running in Glassfish?

 

I have a third party JNI app (Netica). It runs fine from the command
line.

 

i have an EJBModule and a BPEL project added to a composite app. The
composite app is deployed to Glassfish and runs fine - receiving and
responding to SOAP message.

 

i then add the JNI app to the EJBModule and deploy the composite app to
Glassfish.

 

there are two SOAP messages to the composite app - setup and activate.

 

i issue the setup message - the request and response occur.

i issue the activate message - the JNI app runs - all is good - the
results are stored in the database.

after the JNI app should be completed, the memory usage starts to climb.

 

any suggestions?