Quote:
But I still fail to understand how there could be issues be Session object in 2 different jars.
because you won't control which one you're loading :)
this gets you very randomic and non-predictible issues; this applies to all java applications, with the exceptions of different applications in an application server, but still you have to be careful: be aware of what you do, understand and setup classloader isolation.
If you want to keep it simple, never put duplicate classes in your classpath.
To make sure you don't have more duplicates, use a tool ass JBoss Tattletale
http://jboss.org/tattletale, it's a command line tool which inspects your application and produces a great report with warnings about this.
For in depth detaials, see also webinar #8 at :
http://www.jboss.org/webinarsBTW if you used Maven to manage your dependencies you would avoid all the mess.