• 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
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

web application

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i have made client in swing
and the server is in servlet deployed on tomcat 5.5
so how can i communicate from swing to servlet
that should be non-http
and secondly can i use remote ejb calls
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This is a nice tutorial.
http://www-128.ibm.com/developerworks/java/library/j-tunnel/

Tomcat is not an EJB container so you will not be able to make EJB calls to it.

Servlets (out of the box anyway) are primarily designed for HTTP calls but as that article shows HTTP doesn't have to mean html. You can post and receive serialized java objects.
 
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Why can you not use HTTP?

Just to clarify Ben's response. You can call a remote EJB from a servlet. You can also call a remote EJB directly from you swing code.

However your EJB requires an application server like JBoss or WebLogic.

If you are going to use EJBs then you have no real reason to call servlets. Call the EJB directly from your swing controller.

This also fixes your problem of using HTTP as your communications to the EJB will use RMI. However you should make sure those ports are open on any firewall you may be using. I've been burned by that in the past when I didn't "own" the firewall.

Tom
[ March 17, 2005: Message edited by: Thomas Hubschman ]
 
Space pants. Tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic