Hi,
I used following code in MyBean to print CLASSPATH when the bean service
unit receiver request:

String classpathValue = System.getProperty("java.class.path");
System.out.println("CLASSPATH" + classpathValue);

It seems that only the following is being added to already existing
CLASSPATH

;D:\installation\apache-servicemix-3.2.2\bin\..\conf;D:\installation\apache-servicemix-3.2.2\bin\..\lib\classworlds-1.0.1.jar

What do I do to add resources to classpath ??

Thanks,
Harshit


Ashwin Karpe wrote:
> 
> Hi,
> 
> My sense is that the maven build did not succeed in placing an artifact
> into the Maven repository. My original answer below is correct and the
> resources directory is on the classpath since it is used in order to
> deploy the artifact into the servicemix server. 
> 
> BTW, did you verify that the SA does contain the SU and the artifact in
> the folder structure, I mentioned below. This could be easily verified by
> looking in the SA jar file.
> 
> The correct path is with respect to the resources diectory and should be
> "./MyPropFolder/MyPropFile.txt". Please check your deployment artifact to
> see if the file has been placed in the deployable jar.
> 
> Cheers,
> 
> Ashwin...
> 
> 
> [email protected] wrote:
>> 
>> Thanks for response!
>> I have tried each of the following, none of them work
>> 
>> "MyPropFile.txt"
>> "MyPropFolder/MyPropFile.txt"
>> "./MyPropFolder/MyPropFile.txt"
>> "../MyPropFolder/MyPropFile.txt"
>> "./MyPropFile.txt"
>> "./resources/MyPropFolder/MyPropFile.txt"
>> "../resources/MyPropFolder/MyPropFile.txt"
>> "../../resources/MyPropFolder/MyPropFile.txt"
>> 
>> Please Help!
>> 
>> Regards,
>> Harshit
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Reading-file-with-relative-URL-from-Bean-tp21560027p21581778.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Reply via email to