Update Unbounded element using SOAP_CLIENT and JAXB classes

I am writing a custom worklist application using 10.1.3.3. I am able to successfully kick off my BPEL process from my Java application and I am even able to modify most of the fields defined in my XSD. My problem occurs when I try to update the unbounded elements. They are of complex type and each request can have an unlimited number of these elements.
I used JDeveloper's tool to generate the JAXB classes I'm using to interact and modify the payload of my task. I know that JAXB does not generate setter methods for unbounded elements. I should be able to get the list of elements and simply add to it. Unfortunately, the new list elements are not being saved when I marshall my payload and update the task with the new payload.
Any ideas on what I'm doing wrong or if there is another way to do this? I've posted code snippets below.
Thanks!
Quote Element from XSD:
<xsd:element name="Quote" nillable="true" minOccurs="0" maxOccurs="unbounded">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="WorksheetId" type="xsd:int" minOccurs="0"/>
<xsd:element name="QuoteId" type="xsd:int" minOccurs="0"/>
<xsd:element name="Description" nillable="true" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="250"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="Quantity" type="xsd:int" nillable="true" minOccurs="0"/>
<xsd:element name="UnitPrice" type="xsd:float" nillable="true" minOccurs="0"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
AddQuote java code:
JAXBContext jc = JAXBContext.newInstance("myproject.xml");
Unmarshaller u = jc.createUnmarshaller();
Task detailTask = wfSvcClient.getTaskQueryService().getTaskDetailsById(ctx, thisId);
Element detailPayload = detailTask.getPayloadAsElement();
ObjectFactory objFactory = new ObjectFactory();
XMLWorksheet xRequest = objFactory.createWorksheet();
xRequest = (XMLWorksheet)u.unmarshal(detailPayload.getFirstChild());
List quotes = xRequest.getQuote();
quotes.add(quote);
Marshaller m = jc.createMarshaller();
m.marshal(xRequest, detailPayload);
detailTask.setPayloadAsElement(detailPayload);
taskService.updateTask(ctx, detailTask);

who actually managed to make the SOAP_CLIENT working ?
What is the jar list and order you use ?
Does it work with java 5 ?
Thanks for the help!

Similar Messages

  • Using Timer and TimerTask classes in EJB's(J2EE)

    Does J2EE allow us to use Timer and TimerTask classes from java.util package in SessionBean EJB's ( Statless or Statefull )?.
    If J2EE does allow, I am not sure how things work in practical, Lets take simple example where a stateless SessionBean creates a Timer class
    and schedules a task to be executed after 5 hours and returns. Assuming
    GC kicks in many times in 5 hours, I wonder if the Timer object created by survives the GC run's so that it can execute the scheduled tasks.
    My gut feeling says that the Timer Object will not survive.. Just
    want to confirm that.
    I will be interested to know If there are any techiniques that can make
    the usage of Timer and TimeTask classes in EJB's possible as well as reliable with minmum impact on over all performance.

    Have a look at J2EE 1.4. I think they add a timer service for EJBs there...
    Kai

  • I am creating a slideshow with elements using photos and videos but the video sound doesnt play?

    I am creating a slideshow with elements using photos and videos but the video sound doesnt play?

     Hello jive
         I am playing it back in the slideshow editor/setting up part of
    programme where you determine photos/video to be included gaps between
    slides, music to play etc This goes through each phot and when comes
    to a video the background sound doesnt play, I am using windows 7 and
    elements 10.
         regards gins51

  • How to Use Pattern and Matcher class.

    HI Guys,
    I am just trying to use Pattern and Matcher classes for my requirement.
    My requirement is :- It should allow the numbers from 1-7 followed by a comma(,) again followed by the numbers from
    1-7. For example:- 1,2,3,4,5 or 3,6,1 or 7,1,3 something like that.
    But it should not allow 0,8 and 9. And also it should not allow any Alphabets and special characters except comma(,).
    I have written some thing like..
    Pattern p = Pattern.compile("([1-7])+([\\,])?([1-7])?");
    Is there any problem with this pattern ??
    Please help out..
    I am new to pattern matching concept..
    Thanks and regards
    Sudheer

    ok guys, this is how my code looks like..
    class  PatternTest
         public static void main(String[] args)
              System.out.println("Hello World!");
              String input = args[0];
              Pattern p = Pattern.compile("([1-7]{1},?)+");
              Matcher m = p.matcher(input);
              if(m.find()) {
                   System.out.println("Pattern Found");
              } else {
                   System.out.println("Invalid pattern");
    }if I enter 8,1,3 its accepting and saying Pattern Found..
    Please correct me if I am wrong.
    Actually this is the test code I am presenting here.. I original requirement is..I will be uploading an excel sheets containg 10 columns and n rows.
    In one of my column, I need to test whether the data in that column is between 1-7 or not..If I get a value consisting of numbers other than 1-7..Then I should
    display him the msg..
    Thanks and regards
    Sudheer

  • How to unmarshall list tags/unbounded elements using jax-ws auto generated classes in weblogic 12c

    hi
    i have a need wherein i need to create/host jax-ws webservice ( starting from wsdl) and in that service translate the xml using xsl to a different structure and call another webservice hosted to another server ( non-weblogic).
    so my approach is as soon as request comes to the service impl, i marshal the object to a xml then apply the required xsl transformation and then unmarshal the transformed xml to the object which can be used to trigger another webservice.
    This approach works fine for the xmls without list tags/unbounded elements , however it gives marshal exception whenever the xmls has list/unbounded elements.
    i am using jaxb and jax-ws generated class for marshalling and unmarshalling.
    so need some help on how to deal in this scenario?
    any help is appreciated

    hi
    i have a need wherein i need to create/host jax-ws webservice ( starting from wsdl) and in that service translate the xml using xsl to a different structure and call another webservice hosted to another server ( non-weblogic).
    so my approach is as soon as request comes to the service impl, i marshal the object to a xml then apply the required xsl transformation and then unmarshal the transformed xml to the object which can be used to trigger another webservice.
    This approach works fine for the xmls without list tags/unbounded elements , however it gives marshal exception whenever the xmls has list/unbounded elements.
    i am using jaxb and jax-ws generated class for marshalling and unmarshalling.
    so need some help on how to deal in this scenario?
    any help is appreciated

  • Lexical search using Pattern and Matcher class

    Hi Folks,
    Need some help with the following Query. I want to find out how I can implement
    the following by using Pattern / Matcher classes.
    I have a query that returns the following set of strings,
    aa
    abc
    def
    ghi
    glk
    gmonalaks
    golskalskdkdkd
    lkaldkdldldkdld
    mladlad
    n33ieler
    What I would like do is to find out any string that starts with g and Lexical occurs after ghi. So this will return
    ghi / glk / gmonalaks / golskalskdkdkd
    How can I accomplish the above, by using the following two classes.
    Pattern datePattern = Pattern.compile();
    Matcher dateMatcher = datePattern.matcher();
    Thanks a bunch...
    _Shoe Maker..                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

    Nothing in your specification requires a regex. Loop though the strings until you find the string "ghi". Then continue looping though the strings outputting those where the first characters is 'g' .

  • XSLT mapping - Mapping of unbounded elements using Altova Mapforce

    Hi,
    Please give guidance on doing XSLT mapping for unbounded elements in Altova Mapforce. I am not seeing any functions (like FOR loop etc.,) in the XSLT mapping screen for the same.
    I appreciate your input.
    Regards
    Ramesh

    HI,
    For XSLT Mapping refer this help to get functions,syntax etc-
    http://www.w3schools.com/xsl/default.asp
    Regards,
    Moorthy

  • Getting error while updating data element using Xquery Automator

    Hi,
    I am getting following error while i am trying to update a data element in my task.
    <Nov 28, 2011 5:02:40 PM IST> <Error> <oms> <BEA-000000> <automation.AutomationDispatcher: Failed to execute
    on/plugin/external/ACOI_TMIP_POC/1.0.0/CLARIFY_Task.automatedtask.acoi_tmip_poc.ResponseAutomation] due to E
    hile running Script resource [file:///D:/AshishWorkspace_WithOrchestration/ACOI_TMIP_POC/resources/CLARIFY_R
    exception location: ; SystemID: module with no systemId*; Line#: 15; Column#: -1*
    com.mslv.oms.automation.AutomationException: Exception thrown while running Script resource [file:///D:/Ashi
    rchestration/ACOI_TMIP_POC/resources/CLARIFY_Response.xquery]; exception location: ; SystemID: *module with
    e#: 15; Column#: -1
    the Xquery that i am using is pretty simple:
    declare namespace automator = "java:oracle.communications.ordermanagement.automation.plugin.ScriptSenderContextInvocation";
    declare namespace context = "java:com.mslv.oms.automation.TaskContext";
    declare namespace log = "java:org.apache.commons.logging.Log";
    declare namespace oms="urn:com:metasolv:oms:xmlapi:1";
    declare namespace prop = "OSM_POC";
    declare variable $xmlnsosm7POC := "";
    declare variable $log external;
    declare variable $automator external;
    declare variable $context external;
    let $CLFY_XML := //CLFY_XML
    let $Id_Number :=//Id_Number
    return
    automator:setUpdateOrder($automator,"true"),
    log:info($log,fn:concat('ID request number is: ', $Id_Number)),
    <ord:OrderDataUpdate xmlns="http://www.w3.org/2001/XMLSchema" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:odu="http://www.oracle.com/OMS/OrderDataUpdate" targetNameSpace="http://www.oracle.com/OMS/OrderDataUpdate" xmlns:ord="urn:com:metasolv:oms:xmlapi:1">
    <ord:Add path="/CLFY_ID">{data($Id_Number)}</ord:Add>
    </ord:OrderDataUpdate>
    Can anyone please tell me the reason due to which this error is coming.
    Thanking in advance
    Ashish Garg

    Hello.
    Ok I need you to tell me a little bit more about your automator, did you config an Xquery Automator with Event Type: Internal?
    You should declare namespace automator = "java:oracle.communications.ordermanagement.automation.plugin.ScriptReceiverContextInvocation";
    instead of
    declare namespace automator = "java:oracle.communications.ordermanagement.automation.plugin.ScriptSenderContextInvocation";
    And let my ask you, what are you trying to do with the next lines:
    let $CLFY_XML := //CLFY_XML
    let $Id_Number :=//Id_Number
    Becouse I think you are trying to acces the data on the task, If that is the reason, you should better use something like:
    let $order := ..//oms:GetOrder.Response
    let $orderId := $order/oms:_root/oms:orderHeader/oms:orderId
    with the above lines you are accesing the data that has been added to the task and the just acces the node that you nedd, for example here Im accesig the node
    orderId under OrderHeader
    Another thing is that if you want to update node which already exists in the task data, then you have to use something like:
    <OrderDataUpdate xmlns="http://www.metasolv.com/OMS/OrderDataUpdate/2002/10/25">
    <Update path="/orderHeader/orderId">{$orderId}</Update>
    </OrderDataUpdate>
    But if you have to add a new path you should have something like this:
    <OrderDataUpdate xmlns="http://www.metasolv.com/OMS/OrderDataUpdate/2002/10/25">
         <Add path="/OrderHeader">
              <Transaction>
                   <Name>{$orderId/text())}</Name>
              <ComponentKey>{$controlData/text()}</ComponentKey>
              </Transaction>
         </Add>
    </OrderDataUpdate>
    For the above transaction you should have in the dictionary the structure, OrderHeader in the root, and inside this the structure another node with the respective names
    <Transaction>
                   <Name>{$orderId/text())}</Name>
              <ComponentKey>{$controlData/text()}</ComponentKey>
              </Transaction>
    Another thing is that you should have all this structures in the Task Data of this Task.
    Hope this help
    Lucas.

  • UPDATE SQL query using WHERE and a date/time data type... Multiple changes...

    I'm using the LabView Database Connectivity Toolset and am using the following query...
    UPDATE IndexStation
    SET Signal_Size=200
    WHERE 'StartTime=12:05:23'
    Now the problem is that this command seems to update all rows in the table IndexStation... Not just specifically the row where StartTime=12:05:23
    I have tries all sorts of {} [] / ' " around certain characters and column names but it always seems to update all rows...
    I've begun to use the SQL query tab in Access to try and narrow down as to why this happens, but no luck!
    Any ideas!?
    Thanks,
    Chris.

    Chris Walter wrote:
    I completely agree about the Microsoft issue.
    But it seems no SQL based manual states that { } will provide a Date/Time constant.
    Is this an NI only implementation? Because I can't seem to get it to function correctly within LabView or in any SQL query.
    Chris.
    There is nothing about the database toolkit in terms of SQL syntax that would be NI specific. The database Toolkit simply interfaces to MS ADO/DAO and the actual SQL syntax is usually implemented in the database driver or database itself although I wouldn't be surprised if ADO/DAO does at times munch a bit with that too.
    The Database Toolkit definitely does not. So this might be a documentation error indeed. My understanding of SQL syntax is in fact rather limited so not sure which databases might use what delimiters to format date/time values. I know that SQL Server is rather tricky thanks to MS catering for the local date/time format in all their tools and the so called universal date/time format has borked on me on several occasions.
    Rolf Kalbermatter
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • What is the difference of using JavaBean and regular classes?

    Experts,
    I am new to JavaBean(not EJB), and wondering what is the difference of using JavaBean for JSP page compared with using regular Java class?
    I know there are Bean tags which save some lines, what else?
    What does "serialization" mean compared with "not serializable"?
    thanks very much.

    No.
    A JavaBean is a regular JavaClass that:
    1) implements java.io.Serializable
    2) Its data members are private, and its data is accessed via getters and setters. You must define the getters and setters. Getters retrive the property, and must be in the format:
    public PropertyType getPropertyName()
    for most cases. The exception is when the PropertyType is a boolean, in which case you use:
    public boolean isPropertyName()
    Setters assign values to the property, and are in the form:
    public void setPropertyName(PropertyType propValue)
    3) There is also a PropertyChangeEvent model that needs to be followed.
    A marker interface has no methods you need to implement. It just marks the class as supporting certain operations. In the case of Serializable, it means the class can be written to be an ObjectOutputStream for persistant storage.
    As far as an example of JavaBean persistance, take a search on the java.sun.com site for Serializeable
    Also, take a look at this: http://java.sun.com/developer/onlineTraining/Beans/beans02/
    It concentrates mainly on gui component beans, but not all beans need to be gui parts... There are other pages to look at, but I can't find them at the moment, and I have to run...

  • Try to update a table using resultset and nothing happens

    I am trying to update a table in my database.
    I already know the row I want to update by the reporttrikid in the where clause.
    Nothing happens when I run this code. It does not fail but my table never gets updated.
    I have done inserts and selects with no problem, but I must be doing something wrong when it comes to an update.
    Can someone please help?
    try
    conn = XCConfig.getInstance().getConnection();
    logger.debug("connection: " + conn);
    sql = "UPDATE " + REPORTTABLE + " SET " + REPORTTRKMISC + "=?" +
    " WHERE " + REPORTTRKID + "=?" ;
    logger.debug(sql);
    stmt = conn.prepareStatement(sql);
    logger.debug("sql TRKID: " + "");
    Iterator it = List.iterator();
    while (it.hasNext()){
         XCDocPriceFilter filter = (XCDocPriceFilter) it.next();
    //filterTrkId = filter.getTRKId();
         //trkid = Integer.parseInt(filterTrkId);
    trkid = filter.getTRKId();
    logger.debug("Update trkid: " + trkid);
    stmt.setString(1,trkMisc);
    stmt.setInt(2,trkid);
    rs = stmt.executeQuery();
    }//end iterator
    rc = true;
    }

    I am still not getting anything updated.
    I am using the following code.
    int updateCount = stmt.executeUpdate();
    logger.debug(updateCount + " records were updated!");
    The logger says it has been updated, when I go to the
    table the table has not changed.Is your connection in auto-commit mode? Maybe it hasn't committed it (yet). Did you also remember to close your JDBC resources (rs, stmt, conn)?

  • HT1925 I am getting "invalid signature" when I try to download or update iTunes? Using IE10. and Norton. What to do? Please suggest. Thanks

    I am using EI 10 and Norton. It will allow me to download iTunes, but not update. I cannot dowload apps from iTunes. Same error message.
    Thanks for help.

    That suggests that the installer is getting damaged during the download.
    I'd first try downloading an installer from the Apple website using a different web browser:
    http://www.apple.com/itunes/download/
    If you use Firefox instead of IE for the download (or vice versa), do you get a working installer?

  • Updating java when using JDK and JRE

    Ok, so after you make a program in java and compile it, you then install the new update of java. Wouldn't the virtual machine(JRE) or java development kit(JDK) notice something thats different and bring up an error?
    Do you have to use the same JDK as JRE that you have, because if you didn't have the most updated one, wouldn't there come up with an error?
    Last question, if you have used the command line to compile a program, then you know that you need to use javac to compile and java to run it. Well when you use the command javac to compile, then you are using the JDK; and if you use the java command to run it, then you are using JRE. This is just a question to make sure that I have this correct, So correct me if I'm wrong.

    brown16b wrote:
    Ok, so after you make a program in java and compile it, you then install the new update of java. Wouldn't the virtual machine(JRE) or java development kit(JDK) notice something thats different and bring up an error? Why? A newer Java version should be able to execute programs compiler for a prior version.
    Do you have to use the same JDK as JRE that you have, because if you didn't have the most updated one, wouldn't there come up with an error?Eh, what?
    Last question, if you have used the command line to compile a program, then you know that you need to use javac to compile and java to run it. Well when you use the command javac to compile, then you are using the JDK; and if you use the java command to run it, then you are using JRE. This is just a question to make sure that I have this correct, So correct me if I'm wrong.It's correct.

  • How to access SOAP message using JAXP and SOAP class?

    DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
    DocumentBuilder b = factory.newDocumentBuilder();
    FileInputStream fr = new FileInputStream(args[1]);
    Document doc = b.parse(fr);
    Envelope msgEnv = Envelope.unmarshall (doc.getDocumentElement()); <---
    the exception raised:
    java.lang.IllegalArgumentException: Root element of a SOAP message must be: 'htt
    p://schemas.xmlsoap.org/soap/envelope/:Envelope'
    And the xml file is:
    <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"...>
    </env:Envelope>

    The problem is that your DocumentBuilderFactory is not set to be namespace aware. If add a call to factory.setNamespaceAware(true) that should fix your problem.

  • I HAVE ELEMENTS 9 ON MY DESKTOP AND LAP TOP.LAP TOP IS ON WINDOWS 7 AND UPDATED TO ELEMENTS 9.03 AND CAMERA RAW 6.5 OK. WHEN I TRIED TO UPDATE ON MY DESKTOP WHICH RUNS ON WINDOWS 8 BOTH FAIL. IT ONLY SAYS TRY AGAIN LATER WHICH I HAVE DONE A NUMBER OF TIME

    ANYBODY ANY SUGGESTIONS FOR MY ABOVE PROBLEM

    Hi,
    Are you trying to use the Help -> Updates method?
    Both those patches need to be manually applied to PSE 9.
    Brian

Maybe you are looking for

  • Last Approver name in not appearing in the shopping basket

    Hi  SRM Gurus, We have Implemented N step Badi for our client .During Post Go Live we are facing this issue We have created a shopping basket and there are 3 approvers to approve. After the first approvers is approved the name is not appearing in the

  • Could not Auto-save your document ERROR

    Greetings, I am going through a nightmare at our school. Keynote regularly brings the above error and I am stuck now, Reinstall of Iwork,File Server and disabling auto save didnt help. This is the the log extract : 11/28/14 10:13:09.565 AM Keynote[10

  • Delta not reflecting in ODS

    Dear All,          I am pulling data from Ztable (R/3) using generic extraction. The data is on planned production. The fields are YEAR,MONTH,WEEK, UPLOAD-DATE , MATERIAL,QUANTITY. The R/3 user uploads a flat file every month into this Ztable. During

  • My sleep / wake button is stuck down and requires a great deal of force to unlock / lock the my iphone 4. help?

    The lock button is stuck dont and wont come back up. i can still lock the iphone 4 but it requires alot of force and i am afraid of breaking it. i have only had this phone for about 4 months and have had a case on it since day one. Someone please hel

  • Secure trash does not work in deleting a folder

    I downloaded a file with MAC Games and it is hidden in 2 folders - first folder name is 40 games for Mac - when i click on it second folder is called Program Files - click on that and it opens a folder with games that says cannot play using the versi