Premature EOF encountered with Document as a return type

I have created a web service that returns a Document object. I have successfully deployed the web service to my local OC4J standalone (9.0.3), and tested it within JDeveloper with a stub. The same web service is deployed to our test server running 9iAS 9.0.2, with OC4J 9.0.2. When I change my stub to point to the test server, I get the following error rather than the Document returned:
[SOAPException: faultCode=SOAP-ENV:IOException; msg=Premature EOF encountered; targetException=java.io.EOFException: Premature EOF encountered]
Thinking this was a OC4J version issue, I installed 9.0.3 standalone on the same machine. I am able to navigate to the web services page for my web service successfully, invoke the web service, and see the correct Document embedded within the SOAP response. I was unable to do this on the 9.0.2 OC4J instance. Unfortunately, I get the same error when running the stub from JDeveloper and pointing to the 9.0.3 web service.
In an probably unrelated note, I am trying to use the web services portlet, pointing to my stub to call my web service. With this, I get the following error:
ERROR: Failed to handle HTTP Request
oracle.xml.parser.v2.XMLDOMException: Object not supported in current implementation.
     at oracle.xml.parser.v2.XMLDocument.importNode(XMLDocument.java:1303)
     at oracle.portal.provider.v2.webservice.RPCWebServiceRenderer.expandResult(Unknown Source)
     at oracle.portal.provider.v2.webservice.RPCWebServiceRenderer.invokeService(Unknown Source)
     at oracle.portal.provider.v2.webservice.WebServiceRenderer.renderBody(Unknown Source)
     at oracle.portal.provider.v2.render.RenderManager.render(Unknown Source)
     at oracle.portal.provider.v2.DefaultPortletInstance.render(Unknown Source)
     at oracle.webdb.provider.v2.adapter.soapV1.ProviderAdapter.showPortlet(Unknown Source)
     at oracle.webdb.provider.v2.adapter.soapV1.ProviderAdapter.handleHttp(Unknown Source)
     at java.lang.reflect.Method.invoke(Native Method)
     at oracle.webdb.provider.v2.adapter.SOAPServlet.doHTTPCall(Unknown Source)
     at oracle.webdb.provider.v2.adapter.SOAPServlet.service(Unknown Source)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)
Thinking this is an xmlparser version issue, not sure which parser is taking precendence, the OC4J_Portal parser, my application parser, or the ORACLE_HOME parser.
I have thrashed on these issues for a little while, and hopefully I have missed something obvious here. Anything jump out at anyone?
Thanks!

Mike,
Thanks for the response. The reason I am inclined to use Document as a return type is for reuse. Our system is based on the creation of Document representations of content to be displayed, and we use framework code to transform given an xsl. I am trying to establish a pattern for publishing web services right from our existing processes that return the Document. I did play with Element, but would rather not go that way.
I think my web service is working fine now, actually. (Why it can't be tested from JDev, I'm not sure. I will try the server side proxy as you suggest). It is returning my xml content within the <return> of the response. The problem is transforming the result with an xsl. I have tried the web services portlet, which won't work for me because of my return type, and I'm now trying the OmniPortlet, which seems to be coming tantalizingly close to working ;). Not sure if you have used the OmniPortlet or not, but running it, I can see the return of the web service with my xml, which looks good, but then I get this error:
3/12/03 8:55 AM omniPortlet: [id=(null), instance=3915_OMNIPORTLET_49587206] XMLData.next => o
racle.webdb.reformlet.ReformletException: Error occured while fetching XML data.
Also, I've had problems getting the OmniPortlet to recognize my xsl filter for the xml being returned.
Anyone have any success using OmniPortlet consuming a web service that returns xml to be transformed with an xsl filter?
Thanks,
Jason

Similar Messages

  • [IPT_HttpSendError] HTTP encounters send error :.  Premature EOF encounter

    Hi,
    Although we haven't change the configuration we started experiencing following error:
    2009.01.29 at 15:34:30:364: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.Request:preTransmit Create Event Table row for Message Retries
    2009.01.29 at 15:34:30:364: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.Request:preTransmit timeToAck = Thu Jan 01 03:00:00 CET 1970
    2009.01.29 at 15:34:30:365: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.DbAccess:DbAccess:insertEvtTblRow Enter
    2009.01.29 at 15:34:30:365: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.DbAccess:DbAccess:insertEvtTblRow Event Type = 2
    2009.01.29 at 15:34:30:366: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.DbAccess:DbAccess:insertEvtTblRow EventId = 12
    2009.01.29 at 15:34:30:366: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.DbAccess:DbAccess:insertEvtTblRow Id = 33156:5:0:137
    2009.01.29 at 15:34:30:369: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.DbAccess:DbAccess:insertEvtTblRow Exit
    2009.01.29 at 15:34:30:372: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.Request:preTransmit Current TimeStamp isThu Jan 29 15:34:30 CET 2009
    2009.01.29 at 15:34:30:372: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.Request:preTransmit Retry shall happen at Thu Jan 29 17:34:30 CET 2009
    2009.01.29 at 15:34:30:372: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.Request:preTransmit business transaction info name null revision null
    2009.01.29 at 15:34:30:372: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.Request:preTransmit Exit
    2009.01.29 at 15:34:30:372: Thread-40: B2B - (DEBUG) DBContext commit: Enter
    2009.01.29 at 15:34:30:374: Thread-40: B2B - (DEBUG) DBContext commit: Transaction.commit()
    2009.01.29 at 15:34:30:374: Thread-40: B2B - (DEBUG) DBContext commit: Leave
    2009.01.29 at 15:34:30:375: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.Request:outgoingRequestPostColab Calling Send to transmit the message
    2009.01.29 at 15:34:30:375: Thread-40: B2B - (DEBUG) Protocol Name: HTTPS
    2009.01.29 at 15:34:30:375: Thread-40: B2B - (DEBUG) Version Name: 1.1
    2009.01.29 at 15:34:30:375: Thread-40: B2B - (DEBUG) Endpoint: https://example.test.com:8443/ibis/servlet/IBISHTTPUploadServlet/as2_me_in
    2009.01.29 at 15:34:30:375: Thread-40: B2B - (DEBUG) using SSL
    2009.01.29 at 15:34:30:375: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.transport.TransportInterface:send URL: HTTPS://EXAMPLE.TEST.COM:8443/IBIS/SERVLET/IBISHTTPUPLOADSERVLET/AS2_ME_IN
    2009.01.29 at 15:34:30:376: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.transport.TransportInterface:send TO Endpoint: 502 https:/example.test.com:8443/ibis/servlet/IBISHTTPUploadServlet/as2_me_in
    2009.01.29 at 15:34:30:376: Thread-40: B2B - (DEBUG)
    Protocol = HTTPS
    Version = 1.1
    Transport Header
    Content-Transfer-Encoding:binary
    Message-ID:<33156:5:0:137@as2me>
    MIME-version:1.0
    ACTION_NAME:PROCESS
    From:as2Fideltronik
    Disposition-Notification-To:[email protected]
    AS2-To:RUT_AS2
    User-Agent:AS2 Server
    Date:Thu, 29 Jan 2009 14:34:30 GMT
    DOCTYPE_NAME:PROCESS
    FROM_PARTY:as2me
    DOCTYPE_REVISION:1
    TO_PARTY:TP_AS2
    AS2-From:as2me
    AS2-Version:1.1
    Content-Disposition:attachment; filename=7.2
    Content-Type:application/XML; name=7.2
    Parameters
    -- listing properties --
    http.sender.timeout=0
    2009.01.29 at 15:34:30:464: Thread-40: B2B - (DEBUG) scheme null userName null realm null
    2009.01.29 at 15:34:45:178: B2BStarter thread: Deployment - (DEBUG) Query Configurations null Lifecycle status Active exclude design true
    2009.01.29 at 15:34:45:178: B2BStarter thread: BusinessLogicLayer - (DEBUG) Authorization disabled. UserBootstrapped:false, useAuthorization:true,
    2009.01.29 at 15:37:20:021: Thread-40: B2B - (WARNING)
    Message Transmission Transport Exception
    Transport Error Code is OTA-HTTP-SEND-1000
    StackTrace oracle.tip.transport.TransportException: [IPT_HttpSendError] HTTP encounters send error :.
         at oracle.tip.transport.TransportException.create(TransportException.java:91)
         at oracle.tip.transport.basic.HTTPSender.createTransportResponse(HTTPSender.java:754)
         at oracle.tip.transport.basic.HTTPSender.send(HTTPSender.java:598)
         at oracle.tip.transport.b2b.B2BTransport.send(B2BTransport.java:311)
         at oracle.tip.adapter.b2b.transport.TransportInterface.send(TransportInterface.java:1013)
         at oracle.tip.adapter.b2b.msgproc.Request.outgoingRequestPostColab(Request.java:1754)
         at oracle.tip.adapter.b2b.msgproc.Request.outgoingRequest(Request.java:972)
         at oracle.tip.adapter.b2b.engine.Engine.processOutgoingMessage(Engine.java:1166)
         at oracle.tip.adapter.b2b.xmlgwIntg.XMLGWIntegration.raiseOutboundMessage(XMLGWIntegration.java:168)
         at oracle.tip.adapter.b2b.xmlgwIntg.Outbound.onMessage(Outbound.java:297)
         at oracle.jms.AQjmsListenerWorker.dispatchOneMsg(AQjmsListenerWorker.java:316)
         at oracle.jms.AQjmsListenerWorker.run(AQjmsListenerWorker.java:129)
         at java.lang.Thread.run(Thread.java:534)
    Caused by: java.io.EOFException: Premature EOF encountered
         at HTTPClient.StreamDemultiplexor.read(StreamDemultiplexor.java:283)
         at HTTPClient.RespInputStream.read(RespInputStream.java:157)
         at HTTPClient.RespInputStream.read(RespInputStream.java:116)
         at HTTPClient.Response.readResponseHeaders(Response.java:997)
         at HTTPClient.Response.getHeaders(Response.java:713)
         at HTTPClient.Response.getStatusCode(Response.java:262)
         at HTTPClient.RetryModule.responsePhase1Handler(RetryModule.java:83)
         at HTTPClient.HTTPResponse.handleResponse(HTTPResponse.java:739)
         at HTTPClient.HTTPResponse.getStatusCode(HTTPResponse.java:196)
         at oracle.tip.transport.basic.HTTPSender.createTransportResponse(HTTPSender.java:721)
         ... 11 more
    2009.01.29 at 15:37:20:022: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.transport.TransportInterface:send Error in sending message
    2009.01.29 at 15:37:20:022: Thread-40: B2B - (INFORMATION) oracle.tip.adapter.b2b.msgproc.Request:outgoingRequestPostColab Request Message Transmission failed
    2009.01.29 at 15:37:20:022: Thread-40: B2B - (DEBUG) DBContext beginTransaction: Enter
    2009.01.29 at 15:37:20:022: Thread-40: B2B - (DEBUG) DBContext beginTransaction: Transaction.begin()
    2009.01.29 at 15:37:20:022: Thread-40: B2B - (DEBUG) DBContext beginTransaction: Leave
    2009.01.29 at 15:37:20:022: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.Request:outgoingRequestPostColab [IPT_HttpSendError] HTTP encounters send error :.
    Premature EOF encountered
    2009.01.29 at 15:37:20:023: Thread-40: BusinessLogicLayer - (DEBUG) Authorization disabled. UserBootstrapped:false, useAuthorization:true, configType:null
    2009.01.29 at 15:37:20:023: Thread-40: BusinessLogicLayer - (DEBUG) Push Stack: updateBusinessMessage
    2009.01.29 at 15:37:20:026: Thread-40: BusinessLogicLayer - (DEBUG) Pop Stack: updateBusinessMessage
    2009.01.29 at 15:37:20:026: Thread-40: B2B - (DEBUG) DBContext commit: Enter
    2009.01.29 at 15:37:20:027: Thread-40: B2B - (DEBUG) DBContext commit: Transaction.commit()
    2009.01.29 at 15:37:20:027: Thread-40: B2B - (DEBUG) DBContext commit: Leave
    2009.01.29 at 15:37:20:028: Thread-40: B2B - (DEBUG) oracle.tip.adapter.b2b.msgproc.Request:outgoingRequest Exit
    2009.01.29 at 15:37:20:028: Thread-40: B2B - (INFORMATION) oracle.tip.adapter.b2b.engine.Engine:processOutgoingMessage:
    ***** REQUEST MESSAGE *****
    Exchange Protocol: AS2 Version 1.1
    Transport Protocol: HTTPS
    Unique Message ID: <33156:5:0:137@as2me>
    Trading Partner: TEST_AS2
    Message Signed: No
    Payload encrypted: No
    Attachment: None
    ***** REQUEST MESSAGE *****
    2009.01.29 at 15:37:20:028: Thread-40: B2B - (INFORMATION) oracle.tip.adapter.b2b.engine.Engine:processOutgoingMessage Exit
    2009.01.29 at 15:37:20:028: Thread-40: B2B - (DEBUG) : Thu Jan 29 15:37:20 CET 2009 Exit Outbound onMessage
    2009.01.29 at 15:37:20:030: Thread-40: B2B - (DEBUG) DBContext commit: Enter
    2009.01.29 at 15:37:20:030: Thread-40: B2B - (DEBUG) DBContext commit: Leave
    2009.01.29 at 15:37:20:031: Thread-40: B2B - (DEBUG) : Thu Jan 29 15:37:20 CET 2009 Available memory Leave Outbound onMessage: 35505240
    2009.01.29 at 15:37:20:031: Thread-40: B2B - (DEBUG) : Thu Jan 29 15:37:20 CET 2009 Leave Outbound onMessage
    I assume that this might be caused by applying the latest MLR patch or due to some changes on the TP side.
    Please advise

    Hi Suhas,
    Yes, no matter the size of the XML file, it always sends it 6 times. Error occurs only at the end of the process, that is after 6th time the file has been sent. We tested it many times with new messages and each time the results are identical. There is no trace in b2b.log that the file is being sent again, transport log however shows 6 http send entries each time.
    Also, between the start of sending the message and the error occurring after 2-3 minutes (after 6th message is sent) the message is not removed from the ECX outbound queue (we are getting the XML from E-Bussines). It is removed after the error. It cannot manually dequeued during that time.
    Thank you
    Kamil,

  • Premature EOF encountered, no trailer found

    I am using Oracle 10g release 1 database in Windows XP machine
    I was trying to export a table using Enterprise Manager (Export to Files) option.
    I have created a directory and privileges has been granted on that directory to the appropriate answer .
    But after specifying the directory name and the export file name , when I click next its throwing this error
    Validation Error
    Examine and correct the following errors, then retry the operation:
    Error - Premature EOF encountered, no trailer found
    Let me know what should be done ?

    If you are not at the latest 10gR1 patchset, it is advisable to program it to avoid hitting a known bug. On the other hand there it has been reported this error with character set mismatches, so verify at the regedit the character set defined is consistent with the character set used in your session.
    ~ Madrid

  • Not able to read the wsdl file from server Premature EOF encounter

    Hi All,
    I am facing issue while accessing a web Service from server. Here is the clear view about it.
    I created a simple SyncBpel process in a composite and deployed in to the server and it is working fine. Later i created a new Asyn bpel process in a composite and in the external reference i dragged a web Service and imported the wsdl url from server of the SyncBpel and wired the Asynbpel process to webserive .
    Now here i am facing peculiar behavior which i am not able to trace it out.
    1) For the first time when i import the url of syncBpel from the server i am not facing any error and it is working fine as expected but when i close the Jdeveloper and open it i am not able to user the web Service and it is saying as "Not able to read the wsdl file from server Premature EOF encounter"
    2)When i close and open the Jdeveloper i can see the url of the wsdl which imported in webserver is changing from http://stcfmw03.satyam.com:8021/soa-infra/services/Tarak/synchronousBpel/bpelsync_client_ep?WSDL to http://stcfmw03.satyam.com:8021/soa-infra/services/Tarak/synchronousBpel/BPELsync.wsdl
    3)when I open and see the url http://stcfmw03.satyam.com:8021/soa-infra/services/Tarak/synchronousBpel/bpelsync_client_ep?WSDL I can see the soap address as *<soap:address location="http://stcfmw03.satyam.com:8021/soa-infra/services/Tarak/synchronousBpel!1.0*soa_5cfb8416-c106-40a2-a53b-9054bbe04b9c/bpelsync_client_ep"/>*
    I don’t understand why the soap end contains “*soa_5cfb8416-c106-40a2-a53b-9054bbe04b9c” and this kind of url for soap address is coming to all the bpel process which I am deploying in the server.
    I checked the in Jdeveloper where webproxy is uncheck and the server is also up but still I am facing issue of reading the error.
    Can someone please help in resolving the issue.
    I am using SOA 11g 11.1.1.5 and Jdeveloper 11.1.1.5
    Many thanks.
    Tarak
    Edited by: user11896572 on Jan 17, 2012 5:22 PM

    Hi,
    Setting default from the jdeveloper -
    During composite deployment from Jdeveloper (wizard driven), you will be given an option to choose the version of the composite and there will also be an option for you to choose if the composite needs to be deployed as default.
    Setting default from the em console -
    After deploying a composite, login to the em console and click on the composite that you want to set as default, and you will find a tab - "Set as Default". please note that this tab will not be seen, if the composite is already set as default.
    Refer -
    http://docs.oracle.com/cd/E12839_01/integration.1111/e10226/soacompapp_mang.htm
    8.2 Managing the State of Deployed SOA Composite Applications
    Thanks

  • Error deploying composite on SOA Suite 11g: premature EOF encountered

    I am getting the following error when trying to deploy a SOA composite from Jdev 11.1.1.2.0 (on XP) to SOA suite 11.1.1.2.0 (on linux):
    [10:36:43 AM] Error sending deployment request to server soa_server1 [xxx.xxx.x.xx:8001]
    java.io.EOFException: Premature EOF encountered
    More information:
    [10:35:34 AM] >>>> Warning: Unable to determine the target platform from the Profile. Using default...
    [10:35:34 AM] ---- Deployment started. ----
    [10:35:34 AM] Target platform is (Weblogic 10.3).
    [10:35:34 AM] Running dependency analysis...
    [10:35:34 AM] Building...
    [10:35:43 AM] Deploying profile...
    [10:35:43 AM] Updating revision id for the SOA Project 'validationForCC.jpr' to '1.0'..
    [10:35:43 AM] Wrote Archive Module to D:\po\CreditCardValidation\validationForCC\deploy\sca_validationForCC_rev1.0.jar
    [10:35:43 AM] Deploying sca_validationForCC_rev1.0.jar to soa_server1 [xxx.xxx.x.xx:8001]
    [10:35:43 AM] Processing sar=/D:/po/CreditCardValidation/validationForCC/deploy/sca_validationForCC_rev1.0.jar
    [10:35:43 AM] Adding sar file - D:\po\CreditCardValidation\validationForCC\deploy\sca_validationForCC_rev1.0.jar
    [10:35:43 AM] Preparing to send HTTP request for deployment
    [10:35:43 AM] Creating HTTP connection to host:xxx.xxx.x.xx, port:8001
    [10:35:43 AM] Sending internal deployment descriptor
    [10:35:43 AM] Sending archive - sca_validationForCC_rev1.0.jar
    [10:36:43 AM] Error sending deployment request to server soa_server1 [xxx.xxx.x.xx:8001]
    java.io.EOFException: Premature EOF encountered
    [10:36:43 AM] Error sending deployment request to server soa_server1 [xxx.xxx.x.xx:8001]
    java.io.EOFException: Premature EOF encountered
    [10:36:43 AM] #### Deployment incomplete. ####
    [10:36:43 AM] Error deploying archive file:/D:/po/CreditCardValidation/validationForCC/deploy/sca_validationForCC_rev1.0.jar
    (oracle.tip.tools.ide.fabric.deploy.common.SOARemoteDeployer)
    Who can help me solve this problem? The error always comes after exactly 1 minute.
    _[10:35:43 AM]_ Sending archive - sca_validationForCC_rev1.0.jar
    _[10:36:43 AM]_ Error sending deployment request to server soa_server1 [xxx.xxx.x.xx:8001]

    Problem is solved.
    The problem was caused by configuration of my computer.
    JDeveloper deployment needed to contact my application server by ip-adress and by alias.
    I could only ping to my application server by ip-adress.

  • REPOST: Topic: page/ContentFetcher: Premature EOF encountered

    Hi All,
    This is a repost as it is hampering my portal development.
    dbase = 8.1.7.1.1
    IAS = 1.0.2.2 (NT)
    I have installed the french language and after switching to this language several of my portlets cannot be contacted. JServ gives the following details.
    page/ContentFetcher Unexpected Exception, name=content-fetcher21
    java.io.EOFException: Premature EOF encountered at HTTPClient.StreamDemultiplexor.read(StreamDemultiplexor.java, Compiled Code)
    at HTTPClient.RespInputStream.read(RespInputStream.java, Compiled Code)
    at java.io.InputStream.read(InputStream.java:95)
    at java.io.InputStreamReader.fill(InputStreamReader.java, Compiled Code)
    at java.io.InputStreamReader.read(InputStreamReader.java:239)
    at oracle.webdb.page.ContentFetcher.run(ContentFetcher.java, Compiled Code).
    It works fine in the us language.
    Any ideas?
    Thanks
    Joel

    see Re: How to get a Page name?

  • Page/ContentFetcher: Premature EOF encountered

    Hi All,
    dbase = 8.1.7.1.1
    IAS = 1.0.2.2 (NT)
    I have installed the french language and after switching to this language several of my portlets cannot be contacted. JServ gives the following details.
    page/ContentFetcher Unexpected Exception, name=content-fetcher21
    java.io.EOFException: Premature EOF encountered
    at HTTPClient.StreamDemultiplexor.read(StreamDemultiplexor.java, Compiled Code)
    at HTTPClient.RespInputStream.read(RespInputStream.java, Compiled Code)
    at java.io.InputStream.read(InputStream.java:95)
    at java.io.InputStreamReader.fill(InputStreamReader.java, Compiled Code)
    at java.io.InputStreamReader.read(InputStreamReader.java:239)
    at oracle.webdb.page.ContentFetcher.run(ContentFetcher.java, Compiled Code).
    It works fine in the us language.
    Any ideas?
    Thanks
    Joel.

    see Re: How to get a Page name?

  • Overloading hassle with no args, different return types

    We're trying to create a document object that can be parsed from XML with xerces and then used as the model for a jtree and a styled-text editor. That means we want to:
    1. subclass stuff from org.w3c.dom
    2. implement interfaces from javax.swing.tree
    3. implement interfaces from javax.swing.text
    We figured that since they all represent similar tree structures, this would be a nice and clever thing to do.
    Hit a snag this morning:
    * org.w3c.dom.Node.getAttributes() returns NamedNodeMap
    * javax.swing.text.Element.getAttributes() returns AttributeSet
    So, our class gets a compile error on the conflicting return types for what it thinks is the same method.
    Any suggestions for what to do? Abandoning xerces isn't an option, and rewriting styled text ourselves isn't practial either.
    --Chris (invalidname)

    This is the problem with multiple inheritance. In C++, the problem is more pronounced because you can inherit two implmentations of the same method.
    In Java, whenever you inherit two methods with the same signature, even if the return types are the same, you have a similar problem. These two methods will likely have two different contracts, and you cannot fulfuill both contracts with one method.
    Example:
    interface Graphical { /** Draw object on screen */ void draw() { } }
    interface CardDeck { /** Draw a card */ void draw() { } }
    class CardGame implements Graphical, CardDeck { /** ??? */ void draw() { } }It is unfortunate that you're inheriting two different getAttributes() methods. You'll have to use composition and delegation instead of inheritance to get around the problem.

  • Populating ComboBox with CFC web service return type query

    I am just now learning Flex and am attempting my first app (I have been a CFer for years).
    Anyway, I am attempting to build an AIR app in Flex that simply has a login with a form to submit information into a database.
    Things are going ok, except I am stumped at something that I think should be simple...populating a combo box. I have a CFC (I am using CFCs as a web service to drive the app) that contains a method that simply returns a query. I want to use the results to populate the combo box display and value. I created the combo box and then dragged the method to the box to have FB create the code. It populates the list but with just [object Object]. This is a piece of cake in CF but I am not stumbling across the correct syntax in Flex. Any pointers would be appreciated.
    Here is my current code.
    <?xml version="1.0" encoding="utf-8"?>
    <s:WindowedApplication xmlns:fx="http://ns.adobe.com/mxml/2009"
                           xmlns:s="library://ns.adobe.com/flex/spark"
                           xmlns:mx="library://ns.adobe.com/flex/mx"
                           xmlns:users="services.users.*"
                           currentState="login"
                           xmlns:vinlookup="services.vinlookup.*"
                           xmlns:inventory="services.inventory.*"
                           creationComplete="init()">
        <fx:Script>
            <![CDATA[
                import mx.collections.ArrayCollection;
                import mx.controls.Alert;
                import mx.events.FlexEvent;
                import mx.rpc.events.FaultEvent;
                import mx.rpc.events.ResultEvent;
                import mx.utils.ObjectUtil;
                /*Login Code----------------------------------*/
                private var loginrs:Object;
                //Failed to connect to the wsdl service
                private function GeneralFailed_Handler(e:FaultEvent):void
                    Alert.show(e.fault.faultString, "Error connecting to the service");
                //Login Handler
                protected function submitBtn_clickHandler(event:MouseEvent):void
                    loginUserResult.token = users.loginUser(userName.text, password.text);
                //Result Handler for Account Authentication
                private function loginUserResult_resultHandler(e:ResultEvent):void
                    //check the result
                    //Alert.show(ObjectUtil.toString(e.result),"Login Results")
                    loginrs = new Object();
                    loginrs = e.result;
                    if(loginrs['loggedin'] == 'Y')
                        currentState = 'insertInventory';
                    }else{
                        Alert.show("Try Again Please.");
                /*VIN Lookup Code----------------------------------*/
                private var vinrs:Object;
                //VIN Lookup Handler
                protected function VINSubmitbtn_clickHandler(event:MouseEvent):void
                    getvinInfoResult.token = vinlookup.getvinInfo(vin.text, "BASIC");
                //Result Handler for Account Authentication
                private function vinLookupResult_resultHandler(e:ResultEvent):void
                    //check the result
                    Alert.show(ObjectUtil.toString(e.result),"Lookup Results")
                    vinrs = new Object();
                    vinrs = e.result;
                    if(vinrs == null)
                        Alert.show("The VIN did not decode. Try Again Please.");
                    else
                        bodyStyle.text = vinrs['VARBODYSTYLE'];
                        //Alert.show("Yes!");
                /*Item Type Combo Box Code----------------------------------*/   
                protected function comboBox_creationCompleteHandler(event:FlexEvent):void
                    getItemtypeResult.token = inventory.getItemtype();
            ]]>
        </fx:Script>
        <s:states>
            <s:State name="login"/>
            <s:State name="insertInventory"/>
        </s:states>
        <fx:Declarations>
            <s:CallResponder id="loginUserResult" result="loginUserResult_resultHandler(event)"/>
            <users:Users id="users" fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)" showBusyCursor="true"/>
            <s:CallResponder id="getvinInfoResult" result="vinLookupResult_resultHandler(event)"/>
            <vinlookup:Vinlookup id="vinlookup" fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)" showBusyCursor="true"/>
            <inventory:Inventory id="inventory" fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)" showBusyCursor="true"/>
            <s:CallResponder id="getItemtypeResult"/>
            <!-- Place non-visual elements (e.g., services, value objects) here -->
        </fx:Declarations>
        <s:Panel width="250" height="150" title="Login" horizontalCenter="0" verticalCenter="0" includeIn="login">
            <mx:Form width="100%" height="100%" horizontalCenter="0" verticalCenter="0">
                <mx:FormItem label="User Name">
                    <s:TextInput id="userName"/>
                </mx:FormItem>
                <mx:FormItem label="Password">
                    <s:TextInput id="password" displayAsPassword="true"/>
                </mx:FormItem>
                <mx:FormItem>
                    <s:Button label="Login" id="submitBtn" click="submitBtn_clickHandler(event)"/>
                </mx:FormItem>
            </mx:Form>
        </s:Panel>
        <s:Panel includeIn="insertInventory" width="400" height="400" title="Insert Inventory" horizontalCenter="0" verticalCenter="0">
            <mx:Form width="100%" height="100%" horizontalCenter="0" verticalCenter="0">
                <mx:FormItem label="VIN">
                    <s:TextInput id="vin"/>
                </mx:FormItem>
                <mx:FormItem id="vinSubmitbtn">
                    <s:Button label="Decode VIN" id="VINSubmitbtn" click="VINSubmitbtn_clickHandler(event)"/>
                </mx:FormItem>
                <mx:FormItem label="Body Style">
                    <s:TextInput id="bodyStyle"/>
                </mx:FormItem>
                <mx:FormItem label="Item Type">
                    <s:ComboBox id="comboBox" creationComplete="comboBox_creationCompleteHandler(event)">
                        <s:AsyncListView list="{getItemtypeResult.lastResult}"/>
                    </s:ComboBox>
                </mx:FormItem>
            </mx:Form>
        </s:Panel>
    </s:WindowedApplication>

    I figured it out with the help of the AS help. I switched to using a DropDownList and the first example in the help.

  • Column Function Return Type Number is forcing to cast to Decimal

    Hi - I am using Oracle 11g Release 11.2.0.2.0 and ODP.NET 4.112.3.0.
    Whenever I am trying to execute a package query with column function and return type is number, it is throwing cast exception whenever I am trying to cast it as GetInt32.
    The workaround we have for now is to get it decimal and cast to Int32, this is going to be painful moving forward because it means that we have to check each of our packages and need to know if each package has column function and do this special casting.
    Is this a known bug?

    Oracle Number is 6.
    Run the below script to your machine and the sample code below so you can see what I am talking about.
    --drop table aninalfarm;
    --drop table birdfarm;
    --drop public synonym animalfarm;
    --drop public synonym birdfarm;
    --drop public synonym birdfarm_Pkg;
    --drop public synonym animalfarm_Pkg;
    create table animalfarm
            (code                                 NUMBER(6),
            description                        varchar2(10));
    create table birdfarm
           (code                               number(6),
           description                         varchar2(10));
    create public synonym  animalfarm for db.animalfarm;
    create public synonym  birdfarm for db.birdfarm;
    grant select, delete, insert, update on  animalfarm to public;
    grant select, delete, insert, update on  birdfarm to public;
    delete from animalfarm;
    delete from birdfarm;
    commit;
    insert into animalfarm (code, description) values(111122, 'Horse');
    insert into animalfarm (code, description) values(111133, 'Chicken');
    insert into animalfarm (code, description) values(111144, 'Cow');
    insert into animalfarm (code, description) values(111155, 'Pig');
    insert into animalfarm (code, description) values(111166, 'Sheep');
    insert into birdfarm (code, description) values(222, 'Pigeon');
    insert into birdfarm (code, description) values(333, 'Sparrow');
    insert into birdfarm (code, description) values(444, 'Chickadee');
    insert into birdfarm (code, description) values(555, 'Blue Jay');
    insert into birdfarm (code, description) values(666, 'Loon');
    commit;
    create or replace package birdfarm_Pkg is
    function get_key_from_desc(bird_name_in in birdfarm.description%type) return number;
    end birdfarm_Pkg;
    create or replace package body birdfarm_Pkg is
    function get_key_from_desc(bird_name_in in birdfarm.description%type) return number is
    RETURN_VALUE birdfarm.code%TYPE;
    BEGIN
           select code into RETURN_VALUE from birdfarm where description = bird_name_in;
           return RETURN_VALUE;
    end get_key_from_desc;
    END birdfarm_Pkg;
    create or replace package animalfarm_Pkg is
    --region Define Record Type for Strong Type REF CURSOR
    TYPE AnimalFarmRecord is
      RECORD(
                      code animalfarm.code%type,
          description animalfarm.description%type,
                      birdfarm_code birdfarm.code%type
    --endregion
    TYPE animalfarmCur is REF CURSOR RETURN AnimalFarmRecord;
    procedure get_code_two_ways(cur_OUT OUT animalfarmCur);
    end animalfarm_Pkg;
    create or replace package body animalfarm_Pkg is
    procedure get_code_two_ways(cur_OUT OUT animalfarmCur) is
    BEGIN
      open cur_OUT for
           select animalfarm.code,
                  animalfarm.description,
                  birdfarm_pkg.get_key_from_desc('Pigeon') birdfarm_code
           from animalfarm
           order by code;
    end get_code_two_ways;
    END animalfarm_Pkg;
    create public synonym birdfarm_Pkg for db.birdfarm_Pkg;
    grant execute on birdfarm_Pkg to public;
    create public synonym animalfarm_Pkg for db.animalfarm_Pkg;
    grant execute on animalfarm_Pkg to public;
    See the sample code below:
                 var conn = new OracleConnection(OraDB);
                conn.Open();
                conn.ClientId = "Sample";
                var command = new OracleCommand
                                      Connection = conn,
                                      CommandText = "DB.animalfarm_Pkg.get_code_two_ways",
                                      CommandType = CommandType.StoredProcedure
                command.Parameters.Add(new OracleParameter
                                       ParameterName = "cur_OUT",
                                       OracleDbType = OracleDbType.RefCursor,
                                       Direction = ParameterDirection.Output
                OracleDataReader dr = command.ExecuteReader(); // C#
                dr.Read();
                var code =dr.GetInt32(dr.GetOrdinal("Code")); //This is ok
                var description = dr.GetString(dr.GetOrdinal("Description"));
                var codeError = dr.GetInt32(dr.GetOrdinal("birdfarm_code"));//Throw invalid cast exception
                                                                            //because it is column function
                conn.Close();
                conn.Dispose();

  • Error: Encountered premature EOF while reading Version (Grid Control)

    Hi all,
    i´am trying to configure a server in my Grid Control, but when i click "Target", select my host, and click in "Configure", the Grid show me that error:
    Error: "Encountered premature EOF while reading Version"
    Please, someone can help me?
    Regards,
    Francisco Conejeros

    whats the oms,agent version and platform
    does installation was sucessfull ?

  • Problems with document return type

    Hi, i've deployed a web service in weblogic 6.1 that returns a xml document. When
    i try to execute the client, i receive this error message:
    ------------- RECEIVING XML -------------
    <?xml version="1.0"?>
    <definitions
    targetNamespace="java:examples.webservices.rpcXML.pruebaXML"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:tns="java:examples.webservices.rpcXML.pruebaXML"
    xmlns:dom="http://www.w3c.org/1999/DOM"
    xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
    xmlns:xsd="http://www.w3.org/1999/XMLSchema"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    >
    <types>
    <schema targetNamespace='java:examples.webservices.rpcXML.pruebaXML'
    xmlns='http://www.w3.org/1999/XMLSchema'>
    </schema>
    </types>
    <message name="getXMLRequest">
    </message>
    <message name="getXMLResponse">
    <part name="return" type="dom:org.w3c.dom.Document" />
    </message>
    <portType name="PruebaXMLPortType">
    <operation name="getXML">
    <input message="tns:getXMLRequest"/>
    <output message="tns:getXMLResponse"/>
    </operation>
    </portType>
    <binding name="PruebaXMLBinding" type="tns:PruebaXMLPortType"><soap:binding style="rpc"
    transport="http://schemas.xmlsoap.org/soap/http/"/>
    <operation name="getXML">
    <soap:operation soapAction="urn:getXML"/>
    <input><soap:body use="encoded" namespace='urn:PruebaXML' encodingStyle="http://xml.apache.org/xml-soap/literalxml
    http://schemas.xmlsoap.org/soap/encoding/"/></input>
    <output><soap:body use="encoded" namespace='urn:PruebaXML' encodingStyle="http://xml.apache.org/xml-soap/literalxml
    http://schemas.xmlsoap.org/soap/encoding/"/></output>
    </operation>
    </binding>
    <service name="PruebaXML"><documentation>todo</documentation><port name="PruebaXMLPort"
    binding="tns:PruebaXMLBinding"><soap:address location="http://localhost:7001/pruebaXML/pruebaXMLuri"/></port></service></definitions>
    ===================================================================================
    ERROR =================================================================
    javax.naming.NamingException: i/o failed java.io.IOException: http://xml.apache.org/xml-soap/literalxml
    http://schemas.xmlsoap.org/soap/encoding/:http://www.w3c.org/1999/DOM:org.w3c.dom.Document:No
    codec for decoding http://xml.apache.org/xml-soap/literalxml: [ CodecFactory:
    http://schemas.xmlsoap.org/soap/encoding/=null, =null]. Root exception is java.io.IOException:
    http://xml.apache.org/xml-soap/literalxml http://schemas.xmlsoap.org/soap/encoding/:http://www.w3c.org/1999/DOM:org.w3c.dom.Document:No
    codec for decoding http://xml.apache.org/xml-soap/literalxml: [ CodecFactory:
    http://schemas.xmlsoap.org/soap/encoding/=null, =null]
         at weblogic.soap.wsdl.binding.Part.typeToClass(Part.java:74)
         at weblogic.soap.wsdl.binding.Part.toSoapType(Part.java:51)
         at weblogic.soap.wsdl.binding.Message.getReturnType(Message.java:58)
         at weblogic.soap.wsdl.binding.BindingOperation.populate(BindingOperation.java:52)
         at weblogic.soap.wsdl.binding.Binding.populate(Binding.java:48)
         at weblogic.soap.wsdl.binding.Definition.populate(Definition.java:116)
         at weblogic.soap.WebServiceProxy.getServiceAt(WebServiceProxy.java:176)
         at weblogic.soap.http.SoapContext.lookup(SoapContext.java:76)
         at javax.naming.InitialContext.lookup(InitialContext.java:350)
         at examples.webservices.rpcXML.javaClient.Client.main(Client.java:40)
    Exception in thread "main"
    This is the wsdl file that weblogic generates:
    <?xml version="1.0" ?>
    - <definitions targetNamespace="java:examples.webservices.rpcXML.pruebaXML" xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:tns="java:examples.webservices.rpcXML.pruebaXML" xmlns:dom="http://www.w3c.org/1999/DOM"
    xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance" xmlns:xsd="http://www.w3.org/1999/XMLSchema"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
    - <types>
    <schema targetNamespace="java:examples.webservices.rpcXML.pruebaXML" xmlns="http://www.w3.org/1999/XMLSchema"
    />
    </types>
    <message name="getXMLRequest" />
    - <message name="getXMLResponse">
    <part name="return" type="dom:org.w3c.dom.Document" />
    </message>
    - <portType name="PruebaXMLPortType">
    - <operation name="getXML">
    <input message="tns:getXMLRequest" />
    <output message="tns:getXMLResponse" />
    </operation>
    </portType>
    - <binding name="PruebaXMLBinding" type="tns:PruebaXMLPortType">
    <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http/"
    />
    - <operation name="getXML">
    <soap:operation soapAction="urn:getXML" />
    - <input>
    <soap:body use="encoded" namespace="urn:PruebaXML" encodingStyle="http://xml.apache.org/xml-soap/literalxml
    http://schemas.xmlsoap.org/soap/encoding/" />
    </input>
    - <output>
    <soap:body use="encoded" namespace="urn:PruebaXML" encodingStyle="http://xml.apache.org/xml-soap/literalxml
    http://schemas.xmlsoap.org/soap/encoding/" />
    </output>
    </operation>
    </binding>
    - <service name="PruebaXML">
    <documentation>todo</documentation>
    - <port name="PruebaXMLPort" binding="tns:PruebaXMLBinding">
    <soap:address location="http://carlos-3-116:7001/pruebaXML/pruebaXMLuri" />
    </port>
    </service>
    </definitions>
    Could anyone help me, thanks

    Here is a the actual php class:
    class question{
    function getQuestionDetails()
    $r = array("r"=>"s","t"=>11230,"wr"=>500);
    return $r;
    This class has a defined return VO(questionDetails) in flex. It is recognized in the IDE, but when I run the app, I always get a "null object reference" error. I can't seem to convert the result to questionDetails, and I can't access the fields as properties or part of an array of the return object as an instance of "Object".
    Any ideas?
    Thanks!

  • Problem with document splitting

    Hi,
    I am encountering a problem with document splitting, where in while doing clearing of down payment against miro invoice profit center of first line item is over ridding profit center of second line item (line items are two different materials in purchase order).

    Hi Milind,
    Thanks for the reply.
    I've done the below configuration and assigned cost/profit center update. It now works for profit center split. It still does not split accordingly per cost center though.
    SAP Customizing Implementation Guide > Financial Accounting (New) > Financial Accounting Global Settings (New) > Ledgers >Ledger > Assign Scenarios and Customer Fields to Ledgers
    In the below configuration, cost center is not an available option. Unlike the profit center which is available here.
    SAP Customizing Implementation Guide > Financial Accounting (New) > General Ledger Accounting (New) > Business Transactions > Document Splitting > Define Document Splitting Characteristics for General Ledger Accounting
    The profit center split looks fine now, however the cost center split still is only reflected in the expense items and not on the AP item.
    Any ideas on how to actually split the AP line items according to the cost center assignments ?
    Edited by: Patrick on May 9, 2011 7:46 AM

  • Two methods with same name but different return type?

    Can I have two methods with same name but different return type in Java? I used to do this in C++ (method overloading or function overloading)
    Here is my code:
    import java.io.*;
    public class Test{
    public static void main(String ar[]){
    try{          
    //I give an invalid file name to throw IO error.
    File file = new File("c:/invalid file name becasue of spaces");
    FileWriter writer = new FileWriter(file ,true);
    writer.write("Test");
    writer.close();     
    } catch (IOException IOe){
         System.out.println("Failure");
    //call first method - displays stack trace on screen
         showerr(NPe);
    //call second method - returns stack trace as string
            String msg = showerr(NPe);
            System.out.println(msg);
    } // end of main
    public static void showerr(Exception e){
         StringWriter sw = new StringWriter();
         PrintWriter pw = new PrintWriter(sw);
         e.printStackTrace(pw);
         try{
         pw.close();
         sw.close();
         catch (IOException IOe){
         IOe.printStackTrace();     
         String stackTrace = sw.toString();
         System.out.println("Null Ptr\n" +  stackTrace );
    }//end of first showerr
    public static String showerr(Exception e){
         StringWriter sw = new StringWriter();
         PrintWriter pw = new PrintWriter(sw);
         e.printStackTrace(pw);
         try{
         pw.close();
         sw.close();
         catch (IOException IOe){
         IOe.printStackTrace();     
         return sw.toString();
    }//end of second showerr
    } // end of class
    [\code]

    Overloading is when you have multiple methods that have the same name and the same return type but take different parameters. See example
    public class Overloader {
         public String buildError(Exception e){
              java.util.Date now = new java.util.Date() ;
              java.text.DateFormat format = java.text.DateFormat.getInstance() ;
              StringBuffer buffer = new StringBuffer() ;
              buffer.append(format.format(now))
                   .append( " : " )
                   .append( e.getClass().getName() )
                   .append( " : " )
                   .append( e.getMessage() ) ;
              return buffer.toString() ;
         public String buildError(String msg){
              java.util.Date now = new java.util.Date() ;
              java.text.DateFormat format = java.text.DateFormat.getInstance() ;
              StringBuffer buffer = new StringBuffer() ;
              buffer.append(format.format(now))
                   .append( " : " )
                   .append( msg ) ;
              return buffer.toString() ;
         public String buildErrors(int errCount){
              java.util.Date now = new java.util.Date() ;
              java.text.DateFormat format = java.text.DateFormat.getInstance() ;
              StringBuffer buffer = new StringBuffer() ;
              buffer.append(format.format(now))
                   .append( " : " )
                   .append( "There have been " )
                   .append( errCount )
                   .append( " errors encountered.")  ;
              return buffer.toString() ;
    }Make sense ???
    Regards,

  • JAX RPC extension: Problem with document/literal and MyType[]

    Hi,
    I have installed the JAX RPC extension and want to generate a stub from my WSDL file. The WSDL describes a document/literal binding.
    Problem:
    A webservice server method like:
    public wineshop.model.common.SimpleProducer[] getSimpleProducerList() throws RemoteException;
    is translated into a stub method like:
    public UnknownType getSimpleProducerList() throws Exception {..}
    Is an array of own types with the binding style "document/literal" not supported in JAX RPC 1.4 or is it just a bug?
    The WSDL file is generated by JAX RPC 1.4.
    I have installed JWSDP-1.5 and generated a stub with wscompile from the WSDL file. The generated stub has the correct method return type:
    public wineshop.ws.client.SimpleProducer[] getSimpleProducerList()
    throws java.rmi.RemoteException
    It there a workaround like replacing some JDev JARs with JWSDP-1.5 to solve the problem?
    Any hints are welcome.
    Thanks Markus

    repost.....

Maybe you are looking for