there is a jira issue with a patch. unfortunately someone has to build the "classloader" that can see all bundles.
what is really needed here is someone taking the time to build a generic serialization mechanism for osgi. wicket's serialization is pluggable so it can be hooked into that. -igor On Wed, Jun 22, 2011 at 11:59 PM, Harald Wellmann <harald.wellm...@gmx.de> wrote: > Am 22.06.2011 22:00, schrieb Igor Vaynberg: >>> >>> If the page class in bundle A directly references the component class C >>> from >>> bundle B (and not just an interface or base class of B from another >>> bundle >>> X), then the bundle class loader of A can load class C by delegation. >> >> >> not sure if that is true. >> >> given Wicket lives in bundle W >> we have a component bundle C which provides component CommentPanel and >> imports W >> we have an application bundle P which provides page PostPage and imports W >> and C >> >> someone does >> >> class PostPage extends page { PostPage() { add(new CommentPanel("c")); }} >> >> so PostPage has a reference to class CommentPanel from C >> wicket serializes PostPage. >> now wicket deserializes PostPage from disk. W classloader now needs to >> load PostPage and CommentPanel, but it sees neither of those because >> it doesnt import them. >> > > You're right, W's classloader cannot see the class from P or C. But the > thing is, when Wicket deserializes the page, it could use a derived > ObjectInputStream and override resolveClass() to use the class resolver > registered by the application. > > This resolver wraps the bundle class loader P of the application, which is > able to load both PostPage and CommentPanel. > > Regards, > Harald > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org