jWebSocket Forum

[Search] Search   [Recent Topics] Recent Topics   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
Send message from server to client... Where to start ?  XML
Forum Index » Communication Models, Events, Channels, Tokens
Author Message
onlytoine

jWebSocket Forum User

Joined: 18/07/2011 14:27:39
Messages: 2
Offline

Hello,

I just installed a jWebSocket server (embedded into a webapp, using a context listener). And I try to understand how can I send a message from the server to the client...

Can you help me?

Regards,
Anthony
dromani

jWebSocket Forum Fan
[Avatar]

Joined: 14/02/2011 19:00:26
Messages: 72
Location: Spain
Offline

You need to:

· get the WebSocketConnector related to client
· create a new WebSocketServerTokenEven with WebSocketConnector
· create a new Token
· WebSocketServerTokenEven.sendToken(Token)
[WWW] [MSN]
onlytoine

jWebSocket Forum User

Joined: 18/07/2011 14:27:39
Messages: 2
Offline

Thanks for your reply!

I'm looking for a technical solution to enable communication between 2 clients, over the internet.

I know that websocket is not design for that goal, but I wonder if it should be achieved in the case where each client hosts its own websocket server?

Cheers,
Toine
aschulze

jWebSocket Owner
[Avatar]

Joined: 16/03/2010 18:15:55
Messages: 375
Location: Germany, Herzogenrath
Offline

Hi onlytoine,

if you are talking about Java Desktop apps e.g. in Swing that might be possible. Actually this is nothing different than connecting nodes in a grid or cluster. And we really connect our backend servers that way. However, if you are talking about browsers, this will not be possible with native browser support, since the browser cannot act as a server but as a client only. Of course, you could think about applets but you usually always will need a server anywhere to find the ip numbers in the world wide web, which often also will be hidden behind NAT routers.

So if you decide for WebSockets you will have to route the C2C traffic via a server, P2P is not supported by the WebSocket protocol, which is related to the WebSocket spec, not to jWebSocket as a framework.

Best Regards
Alex
[WWW]
ankit12121

jWebSocket Forum User

Joined: 14/11/2017 10:10:01
Messages: 6
Offline

Its a mind blowing and very easy access for me windows explorer windows 10 http://fileexplorerwindows.com here is a place where i can access my recent document and look my all the recent files which recently opened by me. If you are interested so guys click on the given link and read all precocious steps.
vivek2125

jWebSocket Forum User

Joined: 27/11/2017 09:54:38
Messages: 5
Offline

Nice this post, thank's a lot for sharing this. guys if you play online game then go our homepage free yahtzee and play the most popular and played by millions of people online game, its will be play in fully free and without any requirement.
Aaradhya

jWebSocket Forum User

Joined: 17/03/2018 09:59:45
Messages: 1
Offline

I happy to join this community Very Interesting and wonderfull information keep sharing propsys dll error

This message was edited 1 time. Last update was at 19/03/2018 06:24:33

Chakhna

jWebSocket Forum User

Joined: 17/04/2018 07:22:14
Messages: 1
Offline

Very Interesting and wonderfull information keep sharing get help with file explorer in windows 10
SamanthaYoung

jWebSocket Forum User

Joined: 22/06/2018 09:02:54
Messages: 1
Offline

This quota was great one and it must be followed by every person in this world. If we can be good we can do well. He is really a great personality and good author too. I have read many articles in best assignment help blog about this great person. Benjamin Franklin is a father of the nation of America. We can see his picture on the dollar note
 
Forum Index » Communication Models, Events, Channels, Tokens
Go to:   
Powered by JForum 2.1.9 © JForum Team