[ 
https://issues.apache.org/activemq/browse/SM-952?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

ahornbeck updated SM-952:
-------------------------

    Attachment: ClassLoaderXmlPreprocessor.java.patch

It looks like Honi provieded the fix in his original post.  Here is a patch 
using his file.

The fix is  'libraryElement.getFirstChild())...' instead of 
'locationElement.getFirstChild())...'.

> ClassLoaderXmlPreprocessor not able to load shared libraries from xbean.xml
> ---------------------------------------------------------------------------
>
>                 Key: SM-952
>                 URL: https://issues.apache.org/activemq/browse/SM-952
>             Project: ServiceMix
>          Issue Type: Bug
>          Components: servicemix-common
>    Affects Versions: 3.2
>            Reporter: Honi Jain
>            Priority: Critical
>             Fix For: 3.2
>
>         Attachments: ClassLoaderXmlPreprocessor.java, 
> ClassLoaderXmlPreprocessor.java.patch
>
>
> If we dont specify location child node but specify library child node of 
> parent node classpath in xbean.xml we are getting Null Pointer Exception when 
> we deploy our service assembly in servicemix.
> getClassLoader method of ClassLoaderXmlPreprocessor  parses the xbean.xml for 
> the tag 'classpath'. For loading shared-libraries it searches for the child 
> nodes with tag name 'library'.  After it found all the child library nodes it 
> adds to the arraylist for the shared library using the child node list of 
> 'location'. This will give null pointer exception if no location node is 
> there. Even if location node is present when the code will try to look for 
> shared library it will give an error.
> I am attaching the patch file ClassLoaderXmlPreprocessor  .java

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to