3 Replies Latest reply on Jun 25, 2007 6:17 AM by dimitris

    Calling native C++ legacy program from Message Driven Bean

    waikhom

      Hi,

      Could you please help me out on this problem:

      I am having a C++ program which does mathematical calculation and whan to reuse it in my JEE application. I thought of using MDB and call this C++ code using JNI. Does JBoss support calling native programs using JNI? I heard that using JNI call from EJB is not supported by specification.

      I also thought of keeping the C++ code as stand alone application by writing a C++ daemon program which will listen to message queue and process the request and send the response back to my J2EE env. This sounds interesting but since this is not in a container, there are many issues like fault tolerance and clustering of this C++ code in production env.

      If I can direct call this C++ code using JNI.. I can deploy it on production with all the advantages of having JBoss server.

      Please help me out on this issue.

      Thanks,

      Waikhom