Hello,

I developing a jcr base on jackrabbit. now i want the other application to
access it using webservice (cxf) . Now i have expose an interface to return
an java,io.InputStream 

@WebService
public interface JcrDocumentService
{
    @WebMethod
    InputStream getJcrFile(String jcrFilePath);
}

as simple as that...in my other application I access it like this:

InputStream stream =
jcrDocumentService.getJcrFile("photo/upload/test/test_signature.png");

frontend error:

Aug 29, 2009 2:51:36 PM org.apache.cxf.phase.PhaseInterceptorChain
doIntercept
INFO: Interceptor has thrown exception, unwinding now
org.apache.cxf.interceptor.Fault: Couldn't instantiate class. null. Nested
exception is java.lang.InstantiationException: null
        at
org.apache.cxf.aegis.databinding.XMLStreamDataReader.read(XMLStreamDataReader.java:49)
        at
org.apache.cxf.aegis.databinding.XMLStreamDataReader.read(XMLStreamDataReader.java:34)
        at
org.apache.cxf.interceptor.DocLiteralInInterceptor.getPara(DocLiteralInInterceptor.java:235)
        at
org.apache.cxf.interceptor.DocLiteralInInterceptor.handleMessage(DocLiteralInInterceptor.java:120)
        at org

        at
org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:226)
        at
org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442)
Caused by: org.apache.cxf.aegis.DatabindingException: Couldn't instantiate
class. null. Nested exception is java.lang.InstantiationException: null
        at 
org.apache.cxf.aegis.type.basic.BeanType.readObject(BeanType.java:165)
        at
org.apache.cxf.aegis.AegisXMLStreamDataReader.read(AegisXMLStreamDataReader.java:82)
        at
org.apache.cxf.aegis.databinding.XMLStreamDataReader.read(XMLStreamDataReader.java:47)
        ... 54 more
Caused by: java.lang.InstantiationException
        at
sun.reflect.InstantiationExceptionConstructorAccessorImpl.newInstance(InstantiationExceptionConstructorAccessorImpl.java:30)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
        at java.lang.Class.newInstance0(Class.java:350)
        at java.lang.Class.newIn

setup;

wicket 1.4
cxf 2.1.1
-- 
View this message in context: 
http://www.nabble.com/How-to-handle-InputStream-tp25200495p25200495.html
Sent from the cxf-user mailing list archive at Nabble.com.

Reply via email to