I'm working on this gaming service, and I'm a bit confused about a few things.
Assuming my BBS is acting as the HUB, how can the service access other connections to send data between two NODES?
For example:
Digital man runs chess.js on Vertrauen, it connects to the HUB via the gaming service...
Deuce runs chess.js on Synchronix, it also connects..
Now I've got two clients connected to the HUB, who need to be able to communicate with each other.
Are service client connections stored in an array somewhere?
I think I'm missing something obvious.
There are 2 types of Synchronet services:
Dynamic (or normal) Services:
These services are the simplest to write and the Synchronet Services module does most of the work for you (opening the socket, binding the port, accepting incoming connections). For each incoming connection, there is a separate instance of the JavaScript (or native executable) to handle the client. Multiple concurrent clients means multiple concurrent instances of the service. fingerservice.js, gopherservice.js, nntpservice.js are
examples of dynamic services.
Static Services:
These services are executed when the Synchronet Services module starts up and stay running through-out the life of the services module (or they may
be executed stand-alone via JSexec). Static services are responsible for accepting their own connections and only one instance of the service script (or executable) exists to handle all simultaneous client connections. ircd.js and staticservice.js are examples of static services.
Re: services
By: Digital Man to MCMLXXIX on Thu Oct 08 2009 05:54 pm
There are 2 types of Synchronet services:
Dynamic (or normal) Services:
These services are the simplest to write and the Synchronet Services module does most of the work for you (opening the socket, binding the port, accepting incoming connections). For each incoming connection, there is a separate instance of the JavaScript (or native executable) to handle the client. Multiple concurrent clients means multiple concurrent instances of the service. fingerservice.js, gopherservice.js, nntpservice.js are examples of dynamic services.
Static Services:
These services are executed when the Synchronet Services module starts
up and stay running through-out the life of the services module (or they may be executed stand-alone via JSexec). Static services are responsible for accepting their own connections and only one instance of the service script (or executable) exists to handle all simultaneous client connections. ircd.js and staticservice.js are examples of static services.
Ok.. based on the above I'm guessing I didn't look hard enough for that documentation, so I apologisze... but that does mostly answer the question, so thank you.
It seems I need to make use of the latter "static service" as I'll need all of the socket connections to communicate with one another. I'll probably
hit another wall shortly after starting down that road, so don't be surprised if im back on here tomorrow with more.
Um, I just wrote that "documentation" in the post. :-) Think of it like a Wiki. :-)
You could have dynamic service instances communicate with eachother as well (using Queues, Sockets, or disk I/O). You don't *have* to use a static service.
Now I've got two clients connected to the HUB, who need to be able to communicate with each other.
Are service client connections stored in an array somewhere?
I think I'm missing something obvious.
Sysop: | fluid |
---|---|
Location: | wickliffe, ohio |
Users: | 5 |
Nodes: | 10 (0 / 10) |
Uptime: | 203:14:54 |
Calls: | 50 |
Files: | 15,838 |
Messages: | 50,771 |