Saminda,
Here's the code pointed out by Niall:
> ClassLoader loader = Thread.currentThread().getContextClassLoader();
> if (loader == null) {
> loader = this.getClass().getClassLoader();
> }
I wouldn't imagine it would be difficult to refactor such logic into a
replaceable method. What I'd like to know is, if you think it contradicts
OSGi behavior, what should it be to be OSGi compliant?
Paul
On Wed, Jun 11, 2008 at 6:08 AM, Saminda Abeyruwan <[EMAIL PROTECTED]>
wrote:
> Hi All,
>
> Regarding the TCCL, wonder checking null for TCCL and fallback to Class
> classloader would solve the whole problem. Even in embedded case, when
> check
> for TCCL it will give you the application classpath. i.e, Felix set
> application classpath to TCCL and it is not OSGi based. OSGi sepc doesn't
> cover this phenomenon properly and different OSGi implementation treats
> this
> differently. In Felix, TCCL wouldn't be null. Thus, if I assume correct, in
> order to get Struts bundle working struts beans have to be in application
> classpath. If that the case, it would contradict with OSGi modularity
> concept.
>
> Thank you!
>
> Saminda
>