Greetings!

As I have read the J2EE specifications I have found out that Web
Applications should only consist of static web content, jsps, servlets and
such, but is there any point to wrap my Java server application into a
servlet that starts up the server, maybe monitors its state, shuts it down
when needed etc.? I have tried this sort of a approach and built a simple
servlet that launches my server in its init() method. It seems to work
just fine, it can connect to database and it can sit down and wait for
client calls through a specific socket. But, if I put that server servlet
under the same Tomcat instance that serves my client servlets those
servlet apps seems not to be started at all..(server waiting for client
calls through a socket blocks the whole thing?). I put my server servlet
under a different Tomcat instance than client servlet apps and after that
"everything" seems to work just fine except that I keep getting some
strange behaviour with my client servlets - e.g. when trying to log in to
the system using my logger servlet it tells that a specific user id is
invalid even though it is not and it worked with the original system...

Has anyone done any similar work - wrapping server applications into
servlets? Is there some documents in the web on this topic? Any opinions?

One more thing; my client applets use JDK1.1 due to browser issues and
they communicate with my server using serialized "message" objects. Is it
right that if I build those serialized objects with JDK1.2/1.3/1.4 they
will not work in applets - the serialization/deserialization mechanism is
different? It seems that even if I run my server servlet under Tomcat
4.0.1 with JDK1.3.1 the client applets can handle the serialized messages
coming from the server - both objects created at runtime and objects read
from files (files are written using JDK1.1 and includes one big
serialized object each). This is not really any Tomcat issue but a Java
core issue but I was just wondering whether I can use Tomcat 4.0.1 and
Java2 or should I take an older Tomcat that works with JDK1.1.


I thank thee for any advice thy can give on these topics.


Teemu Hiltunen



--
To unsubscribe:   <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>

Reply via email to