Jdeveloper 11g : Generating webservices with streaming attachments support

Hi,
We are trying to create a Java Webservice with support for streaming attachments. In 10g we are using the Attachments API from the oracle.webservices.attachments package.
In Jdev 10g we were doing it the following way:
public String getXMLFile(String name,String fileName,Attachments atts) throws RemoteException
try
AttachmentFactory factory = AttachmentFactory.newInstance();
Attachment imageAtt = factory.createAttachment(fileName, "text/plain", new FileInputStream(fileName));
atts.getOutgoingAttachments().addAttachment(imageAtt);
} catch (Exception e) {
System.out.println(e.getMessage());
return "Hello " + name;
This webservice is deployed in Oracle AS.
How do we do it in Jdev 11g and we want to deploy the service in WLS 10.1.3. If we try to create a webservice over this class in Jdev 11g we get the error :"no-arg default constructor not present".
Any pointers would be highly appreciated.
Thanks and Regards,
Pritom

Hi Vishal,
I created the class as mentioned in the link. But when I try to test the web service, I get the following error :
weblogic.application.ModuleException: [HTTP:101216]Servlet: "oracle.apps.ddr.testFileDownload" failed to preload on startup in Web application: "Application7-Project1-context-root".
javax.xml.ws.WebServiceException: Annotation @com.sun.xml.internal.ws.developer.StreamingAttachment(parseEagerly=true, dir=, memoryThreshold=40000) is not recognizable, atleast one constructor of class com.sun.xml.internal.ws.developer.StreamingAttachmentFeature should be marked with @FeatureConstructor
     at com.sun.xml.ws.binding.WebServiceFeatureList.getWebServiceFeatureBean(WebServiceFeatureList.java:176)
     at com.sun.xml.ws.binding.WebServiceFeatureList.parseAnnotations(WebServiceFeatureList.java:148)
     at com.sun.xml.ws.binding.WebServiceFeatureList.<init>(WebServiceFeatureList.java:113)
Any ideas on how I can make it work ?
Thanks and Regards,
Pritom

Similar Messages

  • How to configure my oracle jdeveloper 11g preview 4 with oracle 8i database

    hi every one
    my requrirement is to configure my oracle jdeveloper 11g preview 4 with oracle 8i database with (thin driver)
    thanks in advance

    Prapan,
    JDev 11g TP4 comes with 11g JDBC drivers, which do not support connecting to any database v 9.0.1 or earlier.
    So, back to you... depends upon what you want to do. If you want to write your own code to connect to a database using 11g, get ahold of some JDBC drivers that support 8i and have away. If you're talking about getting the database development stuff (e.g. the embedded SQLDeveloper) to work, you're probably out of luck.
    So, please define "configure my oracle jdeveloper 11g preview 4 with oracle 8i database"
    John

  • Possibility & Drawback  Using JDeveloper 11g ADF Faces with Oracle 10g DB

    We are new to ADF Faces, would like to use JDeveloper 11g ADF Faces with Oracle 10g database (Enterprise Edition). As we are new to JDeveloper 11g ADF BC, so we want to know about the Possibility & the Drawback.
    Edited by: eng.shahed on Apr 5, 2010 11:21 AM

    i dont think so any drawbacks using Jdeveloper with any database.....its a open product ... You can use it with Sybase, MySQL, Oracle etc etc..

  • JDeveloper 11g/Weblogic Webservices: Is there a test page like OC4J?

    Hi All,
    I am using JDevelope r 11.1.2.2.0.
    I have begun the process of going from a JDeveloper 10/OC4J environment, to a JDeveloper 11g/Weblogic environment.
    My initial steps to migrate the code (mainly webservices) was to go through a process of generating the web services from the WSDL and the dependent schemas.
    I also refactored the previous web service implementation to make it better to Unit test etc, and seperate it out from the generated stubs, as it's always a pain to regenerate the stubs.
    However, this seems fine, the unit tests run fine, but when I come to deploy the the integrated weblogic server I run across a problem.
    Well, not a problem as such, but in the OC4J world, you used a get a nice HTML generated page at the end point, with this you could paste XML in and submit them to the web service.
    However this isn't the case in what I have produced. I am not sure what actually generated it previously, if it was jdev 10 or oc4j or something else?
    Is this the intention on weblogic, or am i doing something wrong? I only get a very basic web page with a link to the WSDL ant nothing much else.
    I have been banging my head against a wall for a day or so with this, and any help appreciated, it would be really useful to get that test page up.
    Thanks
    Norm
    Edited by: user2631187 on 14-Jun-2012 06:24

    Additionally, there seems to be an issue with the bindings in the WSDL (see below)
    We have 2 bindings and there seems only one servlet mapping in the web.xml, where in Jdeveloper 10 there were 2.
    Does anyone know why this is ?
    *<binding name="EToNSoap12" type="tns:EToNSoap">*
    *<soap12:binding transport="http://schemas.xmlsoap.org/soap/http"/>*
    *<operation name="EToNrequest">*
    *<soap12:operation style="document" soapAction="http://www.******/Schemas/ETON/EToNrequest"*
    soapActionRequired="false"/>
    *<input>*
    *<soap12:body use="literal"/>*
    *</input>*
    *<output>*
    *<soap12:body use="literal"/>*
    *</output>*
    *</operation>*
    *<operation name="EToNping">*
    *<soap12:operation style="document" soapAction="http://www******/Schemas/ETON/EToNping" soapActionRequired="false"/>*
    *<input>*
    *<soap12:body use="literal"/>*
    *</input>*
    *<output>*
    *<soap12:body use="literal"/>*
    *</output>*
    *</operation>*
    *</binding>*
    *<binding name="EToNSoap" type="tns:EToNSoap">*
    *<soap:binding transport="http://schemas.xmlsoap.org/soap/http"/>*
    *<operation name="EToNrequest">*
    *<soap:operation style="document" soapAction="******Schemas/ETON/EToNrequest"/>*
    *<input>*
    *<soap:body use="literal"/>*
    *</input>*
    *<output>*
    *<soap:body use="literal"/>*
    *</output>*
    *</operation>*
    *<operation name="EToNping">*
    *<soap:operation style="document" soapAction="http://www.****/Schemas/ETON/EToNping"/>*
    *<input>*
    *<soap:body use="literal"/>*
    *</input>*
    *<output>*
    *<soap:body use="literal"/>*
    *</output>*
    *</operation>*
    *</binding>*

  • Jdeveloper pl/sql webservices with Nested Tables

    Hello
    I am using JDeveloper 10.1.3.1.0,I have created pl/sql webservice using the nested tables. This will insert the object data into database tables.after deplying the webservice into external oc4j, when I test the webservice locally with url: http://localmachine:8888/PL_SQL_WS-Nest_Obj_Webservice-context-root/ObjWebserviceSoapHttpPort
    The above web-services working and I am able to insert into the database tables.
    Same when I want to access through the application server, I have changed the wsdl file soap address as
    <soap:address location="http://10.91.20.7:8888/PL_SQL_WS-Nest_Obj_Webservice-context-root/ObjWebserviceSoapHttpPort"/>
    When I access this url, I am able to give the input data
    http://10.91.20.7:8888/PL_SQL_WS-Nest_Obj_Webservice-context-root/ObjWebserviceSoapHttpPort
    but the out from the web-service is:
    <env:Envelope
    xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
    <env:Header/>
    <env:Body>
    <env:Fault
    xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
    <faultcode>env:Server</faultcode>
    <faultstring>Error creating target: DBConnImpMftest.ObjWebserviceUser</faultstring>
    <faultactor/>
    </env:Fault>
    </env:Body>
    </env:Envelope>
    Could any one help to solve the above issue?
    Kind regards
    Malathi

    try that !
    select a.*, case
    when a.item_type = 1 then b.inv_date
    when a.item_type = 3 then c.deb_date
    end as item_date
    from receipt_item a
    left join invoice b on a.item_id = b.invvi_id and a.item_type = 1
    left join Debit c on a.item_id = c.deb_id and a.item_type = 3

  • XmlMarshalException on using XI generated Webservice with WebDynpro

    Hi,
    i have a problem creating a WebDynpro application using a WebService model created by XI.
    When executing the service:
    public void onActionGO(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
    //@@begin onActionGO(ServerEvent)
    try {
    wdContext.currentRequest_MI_BESCHAFFUNG_MI_BESCHAFFUNGElement().modelObject().execute();
    wdThis.wdFirePlugToMIBeschaffungResultView();
    catch (Exception e) {
    wdComponentAPI.getMessageManager().reportException( e.getLocalizedMessage(), false );
    //@@end
    I get the following error message:
    Service call exception; nested exception is: com.sap.engine.services.webservices.jaxrpc.exceptions.XmlMarshalException: XML Serialization Error. Property [DATA] of class [de.gisa.mibeschaffung.model.proxies.types.RFC_READ_TABLE] must exist and can not be null. This is required by schema description.
    The classes generated by the WSDL import are prefixed by ComplexType. So could this be the culprit here? Also the generated classes are in the de.gisa.mibeschaffung package not in the de.gisa.mibeschaffung.model.proxies.types package.
    I appreciate your input!
    regards
    Dirk

    How do you suggest converting those inputs?
    Using a Netweaver Developer Studio generated model (from a
    WSDL description in turn generated by XI) should shield one from the actual programming tasks required to do that.
    Am i mistaken about that?

  • Best tutorial using open source technology with jdeveloper 11g for beginner

    Best tutorial based on Jdeveloper 11g myfaces, Spring , hibernate and oracle xe or mysql using tomcat server.
    Is there any tutorial like followed link. Using jdeveloper 11g.
    http://www.javaguicodexample.com/javawebjpajsfmysqldatabase12.html
    also like netbean tutorial in jdeveloper 11g.
    http://netbeans.org/kb/67/web/jastrologer-intro.html
    http://netbeans.org/kb/67/web/jastrologer-validate.html
    http://netbeans.org/kb/67/web/jastrologer-jsfformtags.html
    Jdeveloper 11g always go with wizard. I personally like visual jsf desinger of jdeveloper.
    But other thing i want to code. To understand properly.
    I am following following tutorial in jdeveloper 11g
    http://wowjava.wordpress.com/2010/01/21/jsf-database-application/
    Edited by: prafull on May 26, 2010 5:37 PM

    There isn't an end to end tutorial with the stack you are looking at, but:L
    You can start with this tutorial that uses EclipseLink for JPA to build the model layer:
    http://www.oracle.com/technology/obe/obe11jdev/ps1/ejb/ejb.html
    Here is a little example of how you can use Trinidad components (open source) in JDeveloper 11g for visual JSF development:
    http://blogs.oracle.com/shay/2009/02/using_trinidad_in_jdeveloper_1.html
    using MySQL would just mean adding the MySQL JDBC driver to JDeveloper, and to the integrated WebLogic - like this:
    http://jobinesh.blogspot.com/2009/06/adf-with-mysql.html

  • Bug JDeveloper 11g JSP

    A JSP does not get run in JDeveloper 11g.
    Error gets generated:
    Error initializing server: At least one valid code-source or import-shared-library element is required for shared-library "oracle.expression-evaluator:11.1.1" in //JDeveloper/system11.1.1.0.17.45.24/o.j2ee/embedded-oc4j/config/server.xml.

    JSP gets run if JDeveloper 11g is started with:
    jdev.exe -singleuser

  • Generating Webservice using HTTPS in  XI.

    Hi Experts,
         I have generated webservice in XI using http , and i have tested using infopath soap client, its working fine.  I have generated webservice in XI using htpps using the same scenario,  when i am testing using infopath as soap client and tested, its giving error, request is not hitting the XI system at all. do i need to configure any certificate in infopath or in XI server, please can anyone advice. i have configured HPPTS without client authentication in SOAP adapter.
    Thanks,
    Dhanush

    Hi Experts,
      I am not able to get exact answer after reading the sap.help.com, sap notes.
    My scenario is RFC < ---> SOAP ( webservice) ,  i have generated webservice with the HTTPS and secured port of XI,  When i copy and past in IE browser, its showing status is OK,  but request is not hitting the XI system. what are things to be taken care at soap client and XI server side, do i need to install any certificats at client side or server side. please advice me.
    Thanks,
    Siva

  • Unable to Create PLSQL Webservice in JDeveloper 11g

    Hi,
    i have created webservice for PL/SQL for functions with out TYPE data types as parameter..
    but i am unable to create a webservice for procedure having
    Freight_Pkg.PROCEDURE get_freight(
    p_sbl_source_line_tab IN OUT SYK_SBL_SOURCE_LINE_TAB_TYPE
    ,l_total_freight OUT NUMBER
    ,l_err_code OUT NUMBER
    ,l_err_mesg OUT VARCHAR2
    and when i try to create web service it generates below Warning
    =========================================
    Log Message of WebService
    ========================================
    Generating PL/SQL Web Service
    Generating WSDL and mapping file
    WARNING: OWS-00077 The Value Type class: SykSblSourceLineBase does not have a valid Java Bean pattern.
    Adding service files to deployment profile
    Service generation finished
    Generation complete.
    Please let me know the procedure for creating Webservice for PLSQL of Table Type Parameters passing as IN parameter in Procedure.
    Thanks,
    Vijay

    Vijay,
    Is this configured with Oracle E-Business Suite? If yes, please note that JDeveloper 11g is not certified with Oracle Apps 11i/R12.
    How to find the correct version of JDeveloper to use with eBusiness Suite 11i or Release 12.x [ID 416708.1]
    Configuring JDeveloper For Use With Oracle Applications 11i and R12 [ID 330236.1]
    If this is not related to EBS, post your question in the appropriate forum for a better/faster response.
    JDeveloper and ADF
    JDeveloper and ADF
    Thanks,
    Hussein

  • Jdeveloper 11g - JAX-RPC 1.1 method is not supported in WLS 8.1 clients.

    Hi,
    I am using Jdeveloper 11g and migrating a web Service Proxy created using jdeveloper 10g.
    I imported all the proxy classes and when I try to run web service client In Jdeveloper 11g I get the following error
    "JAX-RPC 1.1 method is not supported in WLS 8.1 clients. If you are attempting to run an OC4J 10.1.3 JAX-RPC client in WLS, please see the Web Service Migration Guide for instructions."
    Please advise on how to solve this?
    which is the offending jar/library file in Jdeveloper 11g which is causing the above error?.
    Is the above problem there in the WebLogic Server Runtime also?
    Please let me know.
    2) I cannot generate web server proxies also with jdev11g because the wsdl has overloaded methods omitting the name property within the input and output message, ie, they have a null name. therefore Jdeveloper 11g is using the library which
    when called with an overloaded operation that contains null input/output message names, a duplicate error occurs because it sees other operations with the same name. so it is effectively not allowing to create the web service proxies.
    Thanks,
    Appreciate your quick response to the above

    Have you checked the 'Web Service Migration Guide' mentioned in the error message?
    Timo

  • Calling a Axis2 Secure Web Service with JDeveloper 11g

    We are attempting call a Blackboard (Axis2) web service using Oracle JDeveloper 11g. We are currently unable to generate the security header required, could anyone please point me in the right direction?
    I have following the following steps highlighting my issue. What steps might I be missing? Should I have created a keystore? Should I implement this with the metro stack? Any help or suggestions to go in a different direction would be greatly appreciated.
    1. Install JDeveloper 11.1.1.5.0 (accept defaults)
    2. Open JDeveloper
    3. Create a Project by selecting File > New > Generic Project > Finish
    4. Right-click newly created project and select New
    a. Select Web Services in the Categories
    b. Select Web Service Proxy, then Next
    c. Next
    d. Select JAX-WS Style, then Next
    e. Enter http://gpstc.blackboard.com/webapps/ws/services/Context.WS?wsdl for the WSDL Document URL, then Next
    f. Next
    g. Remove “:80” from the Endpoint URL in each row, the first row should be http://gpstc.blackboard.com/webapps/ws/services/Context.WS, then Next
    h. Next
    i. I don’t see an option for WSSOAP12Binding which this webservice utilizes, so I selected “oracle/wss11_username_token_with_message_protection_client_policy”
    j. Next
    k. Finish
    5. As a test, add the following code after “// Add your code to call the desired methods.”
    GetServerVersionResponse myv = new GetServerVersionResponse();
    myv = contextWSPortType.getServerVersion(new GetServerVersion());
    System.out.println(myv.toString());
    6. Run the Project
    7. Received the following exception “Exception in thread "main" javax.xml.ws.soap.SOAPFaultException: WSDoAllReceiver: Incoming message does not contain required Security header"
    Currently running JDeveloper 11g with Oracle WebLogic Server 11gR1
    Attempting to connect to Blackboard, Release 9.1.50119.0
    Thanks, Adam Ham

    Hi,
    Did you configure the Axis2 in Jdeveloper?
    Best Regards
    Sunny

  • Generating WSDL for a webservice that accepts attachments

    Is there anyway to automaticaly generate a WSDL file for a webservice that accepts
    attachments? Seems like the ant tasks and workshop don't work with services using
    soap with attachments at all...
    Thanks,
    Leonardo.

    Attachments are supported in WLS 7.0.0.1. You can either
    map the attachments to the parameters or use handlers to
    to get to attachments.
    If the attachments are mapped to parameters the WSDL will
    be generated with the appropriate mime binding.
    regards,
    -manoj
    "Leonardo Bueno" <[email protected]> wrote in message
    news:3d63e861$[email protected]..
    Is there anyway to automaticaly generate a acceptsWSDL file for a webservice
    that
    attachments? Seems like the ant tasks and workshop don't work with services
    using
    soap with attachments at all...
    Thanks,
    Leonardo.
    [att1.html]

  • Stub generated in Jdev9i for webservice with 'Vector' return type

    Hi,
    In the OAF page that I am developing, I am trying to consume a web service generated in SAP PI using Jdeveloper. My Jdeveloper version is 9.0.3.5(I need to use this version since I need to deploy the OAF page in EBS11i). The stub generated based on the WSDL is given below.
    import oracle.soap.transport.http.OracleSOAPHTTPConnection;
    import org.apache.soap.encoding.soapenc.BeanSerializer;
    import org.apache.soap.encoding.SOAPMappingRegistry;
    import org.apache.soap.util.xml.QName;
    import java.util.Vector;
    import org.w3c.dom.Element;
    import java.net.URL;
    import org.apache.soap.Body;
    import org.apache.soap.Envelope;
    import org.apache.soap.messaging.Message;
    * Generated by the Oracle9i JDeveloper Web Services Stub/Skeleton Generator.
    * Date Created: Tue Jan 25 16:12:55 IST 2011
    * WSDL URL: file:/C://Working/XXXXXXX/RegConsComplaint_OB.wsdl
    public class RegConsComplaint_OBServiceStub
      public RegConsComplaint_OBServiceStub()
        m_httpConnection = new OracleSOAPHTTPConnection();
      public static void main(String[] args)
        try
          RegConsComplaint_OBServiceStub stub = new RegConsComplaint_OBServiceStub();
          // Add your own code here.
        catch(Exception ex)
          ex.printStackTrace();
      public String endpoint = "http://XXXXXX:8000/sap/xi/...../RegConsComplaint_OB";
      private OracleSOAPHTTPConnection m_httpConnection = null;
      private SOAPMappingRegistry m_smr = null;
      public Vector RegConsComplaint_OB(Element requestElem) throws Exception
        URL endpointURL = new URL(endpoint);
        Envelope requestEnv = new Envelope();
        Body requestBody = new Body();
        Vector requestBodyEntries = new Vector();
        requestBodyEntries.addElement(requestElem);
        requestBody.setBodyEntries(requestBodyEntries);
        requestEnv.setBody(requestBody);
        Message msg = new Message();
        msg.setSOAPTransport(m_httpConnection);
        msg.send(endpointURL, "http://sap.com/xi/WebService/soap1.1", requestEnv);
        Envelope responseEnv = msg.receiveEnvelope();
        Body responseBody = responseEnv.getBody();
        return responseBody.getBodyEntries();
    }I am wondering whether I will be able to use this stub generated by Jdeveloper since the input type is 'Element' and return type is 'Vector'; while in the Jdeveloper documentation the supported "primitive XML Schema types and arrays of primitive XML Schema types as parameters and return values for web services" do not include either of the two.
    Regards,
    Sujoy

    Hi Sujoy
    I have been having big problems consuming microsoft sharepoint webservices using jDeveloper 9i.
    Problems with jdk version compatability with jDev and NTLM authentication (Sharepoint).
    so switching to db connection using utl_http.
    Can you pls send me the code set for reference at [email protected]
    thanks.
    Regards
    Sachin

  • Problem with PPR in Jdeveloper 11g

    Hi All,
    I'm working with the Jdeveloper 11g.
    My problem is I have a command button/ Command link in a jspx page. Whenever I click on the command button or command or any action generating components the whole page is getting refreshed(PPR).
    I wrote some internal logic in the constructor so as to display the tree. It is calling the constructor again and again when I'm clicking on the sub nodes of the tree. I think the entire page is getting refreshed and the methods are calling again and again.
    Is there any way to overcome this problem.
    Could any one help me out.
    Thanking you,
    regards,
    Satish.

    Satish,
    I need more information to triage this issue. Do you have the partialSubmit attribute set to "true" on the command component? Does your JSPX contain an <af:document> tag?
    --RiC                                                                                                                                                                                                                                                                                                                                                                                               

Maybe you are looking for

  • WebHelp format does not display in Firefox

    I'm using RoboHelp 7 to produce a develoment platform documentation. When producing a WebHelp output I can display the contents locally via Firefox 2.0. The process is then to copy the whole set of files to a web server via Filezilla. No pb for acces

  • How do you print an envelope in Pages?

    I want ro print an envelope for my letter.  How do I do this in Pages?

  • ITunes is recognizing/using an OLD Library of mine.

    The Hard Drive (HD) of my iMac (2008) recently died, but I use an external HD to keep and organize all of my iTunes files. I had the HD replaced and I am in the process of setting up my computer as if it were new. Since my iTunes files and folders ar

  • [ADF-11.1.2] Security 401 error ONLY while navigating from 1 BTF to another

    Hi, I have 2 BTF in my Security-Enabled ADF application. First BTF has a Task Flow Call to another BTF. I then created 2 web pages for each BTF. Page A for first BTF and B for second BTF. If I open any page, it ask for Authentication and display the

  • Fm to read from SAP memory

    Hi, I need a fm whic will read the sub-equipments currnetly dismanteled for a superior equipment. I am using tcode ieo2 and enhancement IEQM0003 Plz help