permaculture playing cards
The moose likes Sockets and Internet Protocols and the fly likes creating first Client server application Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Sockets and Internet Protocols
Bookmark "creating first Client server application" Watch "creating first Client server application" New topic

creating first Client server application

Jeena Jeen
Ranch Hand

Joined: Feb 11, 2009
Posts: 47
hi all,
I am not new to Java but new to j2ee. I don't know if it is the right place to ask this type of question. If not then please point me to the right place.
I want to make a client server application over http. I want to make a server that generates some data and over http i want to send this data to client.
Client will further process this data. That is my goal.
I have no clue how to start. I mean logic is not a problem but shall i make simple servlet and then use JMS to send data in queue or there is better way to do it??
Can anyone please help me to make things bit clear.
plzx help!
Thanks guys!!!
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63858

HTTP is not the appropriate technology for having a server contact a client.

[Asking smart questions] [About Bear] [Books by Bear]
Rob Spoor

Joined: Oct 27, 2005
Posts: 20275

HTTP can be used if the client queries the server for data, but if the server pushes the data then you would need an HTTP server on each client. You don't want that. You should use a different communication mechanism, like direct socket communication or JMS. At work we once used RMI for that.

How To Ask Questions How To Answer Questions
Jeena Jeen
Ranch Hand

Joined: Feb 11, 2009
Posts: 47
Hi all, Thanks for the reply. I want to make application focusing on only one client right now. So HTTP iwon't be any problem. I don't need to set up multiple http server on clients. Only one client receiving data.
So if I consider this kind of system then what should i use? So i was thinking like this.
create sever side application using jBoss and send message with JMS.
And on the other side client application also running JBOss and it can collect data from the queue.
Does it make any sense what I just said or not.
I agree. Here's the link:
subject: creating first Client server application
jQuery in Action, 3rd edition