Creating a class shared by both applications only works if both use the same ClassLoader - I don't think you can rely on it.
As I said, Sun's design requires "Web Applications" to be completely separate and independent. The reason being they want to encourage the sale of web applications and interactions between web applications would cause endless debugging problems.
The solution is to run an entirely separate application that any web application servlet can talk to and share data. This is easily done - you have several options. Chapter 9 in my servlets &
JSP book works out an example using a Chat server as an example.
Bill