• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need suggestion on exposing the Jar file.

 
Ranch Hand
Posts: 146
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


Dear Ranchers,

I need some suggestions,

Scenario
I have a jar file with 5 API's with input parameters and return types.

API 1 takes int as input parameter and return array of bytes.

All other API's return int as return type.


Problem Case :
Now, my problem is, this jar with all 5 api's should be exposed as single unit accessible by different systems.

It should be able to resolve all http based calls.

Either from a dot net system or from a j2ee server.



What can i use for that.

#1.servlet (If i use servlets how do they return byte arrays and integers. servlets say public void doPost())

#2.RMI

#3.TCP/IP



Need your valid suggestions on this








Thanks.
 
Ranch Hand
Posts: 378
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Looks like a candidate for Web Services. Expose your API through Web Services, you could try Axis Java to deploy your APIs as Web Services and use a relevant Web Services client from the client platform you want to use.

Or with modern application servers it shouldn't difficult to deploy your APIs as a Web Service.

Hope this helps.
 
ram kumar
Ranch Hand
Posts: 146
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Gamini Sirisena wrote:Looks like a candidate for Web Services. Expose your API through Web Services, you could try Axis Java to deploy your APIs as Web Services and use a relevant Web Services client from the client platform you want to use.

Or with modern application servers it shouldn't difficult to deploy your APIs as a Web Service.

Hope this helps.





Thanks first !

We discussed to deploy the jar as EJB(Stateless session Beans) and deploy that as web services.

Every API becomes an EJB method that exposesitself with return values and input parameters.

so that all http request from .net and j2ee systems are served.

Any other Suggestions - Welcome !

Also,

I hope the AXIS java tool is a deployer tool that deploys j2ee components as Web-Services.

Why dont we implement it using servlets ? Is it not possible ?

I hope it is not possible, since servlets cannot return any that API methods return.

They are basically public void doPost().

please clarify !


 
Marshal
Posts: 79239
377
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Not a beginner's topic. Moving.
 
Message for you sir! I think it is a tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic