Q
Qu0ll
The basic architecture is an applet which communicates with a server over
the internet, repeatedly reads instructions from the server and behaves in
an appropriate manner (i.e. displays text on the screen). The reads from
the server are triggered by user actions in the applet. The key design
objective is to have the lag between when the user initiates the action to
when they see a result on the screen (a result of interaction with the
server) as small as possible.
So, to the possible implementations... I have identified at least 3 namely
NIO client and server, RMI client and server and applets/servlets.
I have implemented a solution with NIO and it works technically speaking but
I am not entirely happy with the lag. It has the pros that it's a highly
scalable solution but I am wondering if I can do better. It has one con
that I can think of in that it has to use a hard-code port and if that port
is already in use on the client machine then bad luck! Also, accessing that
port may have firewall/security issues.
So then there's RMI. I am hoping that perhaps this will result in less lag.
It has the pro that it's simple to code. It has the same cons as the NIO
solution namely hard-code port and firewall/security issues.
Then there's applets/servlets. This has the distinct advantage that the
port used is the standard HTTP port. I am not sure about the lag though.
Of course I could build an implementation of each and measure the
performance but I am hoping a bit of friendly advice will direct me straight
to the best solution. Which implementation is likely to produce the
smallest lag? Is there another (better) implementation? Any other
comments?
--
And loving it,
-Q
_________________________________________________
(e-mail address removed)
(Replace the "SixFour" with numbers to email me)
the internet, repeatedly reads instructions from the server and behaves in
an appropriate manner (i.e. displays text on the screen). The reads from
the server are triggered by user actions in the applet. The key design
objective is to have the lag between when the user initiates the action to
when they see a result on the screen (a result of interaction with the
server) as small as possible.
So, to the possible implementations... I have identified at least 3 namely
NIO client and server, RMI client and server and applets/servlets.
I have implemented a solution with NIO and it works technically speaking but
I am not entirely happy with the lag. It has the pros that it's a highly
scalable solution but I am wondering if I can do better. It has one con
that I can think of in that it has to use a hard-code port and if that port
is already in use on the client machine then bad luck! Also, accessing that
port may have firewall/security issues.
So then there's RMI. I am hoping that perhaps this will result in less lag.
It has the pro that it's simple to code. It has the same cons as the NIO
solution namely hard-code port and firewall/security issues.
Then there's applets/servlets. This has the distinct advantage that the
port used is the standard HTTP port. I am not sure about the lag though.
Of course I could build an implementation of each and measure the
performance but I am hoping a bit of friendly advice will direct me straight
to the best solution. Which implementation is likely to produce the
smallest lag? Is there another (better) implementation? Any other
comments?
--
And loving it,
-Q
_________________________________________________
(e-mail address removed)
(Replace the "SixFour" with numbers to email me)