-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Jason,

On 10/29/14 2:01 PM, Jason Ricles wrote:
> Yes Chris RMI is a pain in the ass and I have been trying to make
> a websocket client endpoint now. It however keeps closing and I am
> not to sure as of why right after the connection is open. 
> http://stackoverflow.com/questions/26636452/tomcat-clientendpoint-websocket-keeps-closing
>
> 
has the code, asked the questions on there and have not gotten any answers.
> If you could you may look at the code and reply in this email chain
> why it keeps closing right after it opens. It is straight forward
> (as of what i know understand) my ignorance was due to being new to
> tomcat and websockets so sorry for any of that.

I think your problem is not ignorance of Tomcat or even Websockets,
but perhaps Java itself. You should find a good Java programmer to
help you with this, preferably someone with familiarity with Websocket.

If you want to go it alone, grab the source for Tomcat and look at
some of the unit tests that involve Websocket. I haven't looked
myself, but I'll bet there's at least one unit test with a Java-based
client that connects to a Tomcat and exchanges a few messages.

Good luck,
- -chris

> On Wed, Oct 29, 2014 at 1:47 PM, Christopher Schultz < 
> ch...@christopherschultz.net> wrote:
> 
> Jason,
> 
> On 10/29/14 8:28 AM, Jason Ricles wrote:
>>>> foo is not a webapp, it is a separate program running on the 
>>>> computer as a daemon.
> 
> I understand that. I'm only suggesting that, since you have to 
> communicate with Websocket-speaking web application, maybe foo
> ought to be a Websocket client of that webapp.
> 
>>>> It has to do this stuff for it needed to be ran like this.
>>>> bar is basically the gui to the daemon, providing what is
>>>> happening on the machine to someone at another computer,
>>>> since the machine is headless these programs are being ran
>>>> on.
> 
> So you have a data-collection program (the foo daemon) and an 
> aggregating / reporting program (the webapp). It seems like it
> would be pretty simple to have the daemon push data to the webapp
> over Websocket. Then your data consumers (themselves Websocket
> clients) can get that same data pushed-out to them.
> 
> Maybe I'm being naive, but this seems fairly straightforward to
> me.
> 
>>>> So I am curious as to how having my foo program running
>>>> outside of bar how it can interact using websockets?
> 
> Grab the Tomcat Websocket client library and write your code to use
> it for communication. Or use any other Java-based Websocket client 
> library. Or write your daemon in something other than Java and use 
> whatever Websocket library is available (Perl? PHP? C++?).
> 
>>>> So far I have seen that they are disconnected and have no
>>>> clue about each other outside of using RMI.
> 
> RMI is a complete pain in the ass except under some very special 
> circumstances. It sounds like you might fit into those special 
> circumstances, so feel free to give it a try.
> 
> If it were me, I'd do it all with Websockets:
> 
> 1. Foo Daemon -> web aggregator 2. web aggregator -> data
> consumers
> 
> -chris
>> 
>> ---------------------------------------------------------------------
>>
>> 
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
>> For additional commands, e-mail: users-h...@tomcat.apache.org
>> 
>> 
> 
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJUUknaAAoJEBzwKT+lPKRYhhQQAMA/zavChbnv7qO1q0KhZaHe
VJABne/mhOEZM+Ot7N+Qyc1yaq6iO7dnoN6Zy8XzK1lqYrhPBAqFJWsEJqMtOKK8
bE/zzsIC25xOjXq0NcH6yLxo846mR6mPLyzDAK9KPNDAEeRRnBGZuiBQjA2VLppp
kSArdp8s6Z+JU3zCv5tkLA6ybDSvu1Mz2u/NjWeLl8RfaHgFOm4+TrPR+o0Mor4p
PKx37BfEdr0y8PkAKsweqMVFLDMvrHImEPAe0EkYcpajW4SOvI4ebvekBabfW77S
D6cL1zommbyMICHoDulGN7JYx3nOlQJ2MMpRmyWW2KMHJjHEWYXpXivmHqwrbEvl
ofAgByuzmIZao/xFznOSpFKODpETcGSHI/Y7HnSc0H58zpGT/1LiZ7CM/htx8F4c
L7xklGMjHGeXiZv1aMvAYriwgx5zNgwV36Ky0UOOg9ZGoGtklziWNVB6VsgMjSf0
1N/oYSmBo+LOAs2i/+3ghhWVkV1LrznN8OWe3HH5gHLUkL9Vh4yoFUJKMft9y5Zn
PFJ0SHr5zGyV8SI9cueS3auoa8hJ+Q8MmYTCxuD9+536327CXOGr6f/8XJVfpT7s
BJbNbzqFB9tL136jcze8UDdRLc0Ilj1A5xDf4PiN+h6E+BcSLr6mxDX2Yn7rH8YT
Ez5mppLdADCBYdwlZbJ0
=VrJi
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to