class instantiation in referenced project causes ClassNotFoundException
I have a web project with an abstract class called AbstractModel.
This abstract class have many derived implementations. So far everything is good and working well.
I'd like to take the implementations outside of the web project, for they are not part of the actual project.
So I've created a simple java project, and copied one of the implemented classes (and excluded it from the original web project).
In the new project, called clients, I've made a project reference to the web project.
In the web project, I've added to the classpath of the web server (tomcat) the bin folder of the Clients project, so when the application could instantiate the derived class.
When I invoke the derived class instantiation, I get a ClassNotFoundException on the AbstractModel class.
I tried many things like adding classpath reference in the clients project to the bin folder of the web project. Nothing helped.
I see that the ClassLoader is looking for the AbstractModel in the bin folder of the clients project.
What am I doing wrong?