load resource as stream from an extension in jboss

load resource as stream from an extension in jboss

  
Hi,

I have a problem loading a resource in an extension when deployed in Jboss. I use the classloader to load the resource as stream and it returns the stream which is org.jboss.virtual.plugins.context.zip.CertificateReaderInputStream@175ebc34
and the url for the resource is using vfszip protocol.

vfszip:/apps/jbossas/server/outsystems/deploy/DAMAdapter.war/WEB-INF/lib/outsystems.nosxmlstructuretransformer.jar/com/fico/om/apm/utils/DM_XML_CONFIG.xml

How do i get access a resource within an extension?
Hello Pradeep,

I have tested this a bit and was able to access resources from an extension in the following way:

Using the current context's class loader you seem to be able to get something deployed to the "libraries" by getting the resource as stream like "../name_of_the_resource" and you can get something deployed to the application directory by getting "../../../name_of_the_resource".

You can take a look at the extension and eSpace in attachement and use it to get the following resources:

../test_binaries.txt
../../../test.txt

Let me know if this is enough to get you going.

Best regards,
Ricardo Silva
Thanks Ricardo.. I will check it out.

regards,
Pradeep V.B.