11 Replies Latest reply: May 19, 2012 12:01 PM by Arik RSS

    Unable to transfer files using FTP adapter

    931735
      Hi,

      When i am trying to transfer files with size greater than 2MB from one ftp location to another ftp location the following errors are showing :


      <exception class="java.lang.ClassCastException">
      java.lang.String cannot be cast to org.w3c.dom.Element
      <stack>
      <f>com.collaxa.cube.xml.xpath.BPELXPathUtil.evalQuery#613</f>
      <f>com.collaxa.cube.xml.xpath.BPELXPathUtil.evalQuery#588</f>
      <f>com.collaxa.cube.engine.ext.bpel.common.BPELWMPHelper.evalFromValue#330</f>
      <f>com.collaxa.cube.engine.ext.bpel.v1.wmp.BPEL1AssignWMP.__executeStatements#138</f>
      <f>com.collaxa.cube.engine.ext.bpel.common.wmp.BaseBPELActivityWMP.perform#166</f>
      <f>com.collaxa.cube.engine.CubeEngine.performActivity#2687</f>
      <f>com.collaxa.cube.engine.CubeEngine._handleWorkItem#1190</f>
      <f>com.collaxa.cube.engine.CubeEngine.handleWorkItem#1093</f>
      <f>com.collaxa.cube.engine.dispatch.message.instance.PerformMessageHandler.handleLocal#76</f>
      <f>com.collaxa.cube.engine.dispatch.DispatchHelper.handleLocalMessage#218</f>
      <f>com.collaxa.cube.engine.dispatch.DispatchHelper.sendMemory#297</f>
      <f>com.collaxa.cube.engine.CubeEngine.endRequest#4609</f>
      <f>com.collaxa.cube.engine.CubeEngine.endRequest#4540</f>
      <f>com.collaxa.cube.engine.CubeEngine._createAndInvoke#713</f>
      <f>com.collaxa.cube.engine.CubeEngine.createAndInvoke#560</f>
      <f>com.collaxa.cube.engine.ejb.impl.CubeEngineBean.createAndInvoke#103</f>
      <f>...</f>
      </stack>
      </exception>

      I am transferring files in opaque format


      I am not getting this error when i am transferring files less than 2Mb.
      Can anyone help me to solve this issue
        • 1. Re: Unable to transfer files using FTP adapter
          Arik
          Hi,

          In your composite setting(EM) :

          1. change the Audit level to Production
          2. Disable Payload Validation

          See if this solve your ptoblem.

          Arik
          • 2. Re: Unable to transfer files using FTP adapter
            931735
            Hi,

            Thanks for the reply. Tried with these options but result is same. Getting same errors
            • 3. Re: Unable to transfer files using FTP adapter
              931735
              Is there any property setting where we can increase the memory (in jvm or jca file?)
              • 4. Re: Unable to transfer files using FTP adapter
                Arik
                Look, I'm using FTP(get - opaque) with files, larger then 2M, from different locations and don't have this error.
                Can you post more details about the process and error: When do you get the error - during read/after read/within the receive activity?
                Did you change any of the FTP adapter properties?Added aditional jars to your classpah?
                If you haven't used the file age property, try.
                • 5. Re: Unable to transfer files using FTP adapter
                  NarsingPumandla
                  when you are just moving the file from one location to another location using FTP without processing the data inside the BPEL...

                  and those files are large files, it is recommended to read the file using attachment option....

                  please go through the below documentation.,

                  http://docs.oracle.com/cd/E21764_01/integration.1111/e10231/adptr_file.htm#BABDIABG

                  go to 4.5.6 Oracle File Adapter Read File As Attachments

                  Hope this helps
                  N
                  • 6. Re: Unable to transfer files using FTP adapter
                    931735
                    Hi Arik

                    I am able read the files (greater than 2 mb also) from source FTP location and while assigning the file iam getting the above mentioned error.

                    i added the the property for reading the files in ascending order in jca file( <property name="ListSorter" value="oracle.tip.adapter.file.inbound.listing.TimestampSorterAscending"/>
                    )


                    Thanks,
                    vivek
                    • 7. Re: Unable to transfer files using FTP adapter
                      Arik
                      Ok...so, what is the target variable in the assign? Did you create the target variable from a write file/ftp operation with the opaque option?
                      Can you please check that both variable has the same element definition?

                      Arik
                      • 8. Re: Unable to transfer files using FTP adapter
                        931735
                        yes I created target variable for write FTP with opaque option but dont know only files above 2mb size are not transferring.

                        Yes i checked both Read file variable and write file variable are in opaque format.
                        • 9. Re: Unable to transfer files using FTP adapter
                          Arik
                          Did you put any property in the receive/invoke activities?
                          • 10. Re: Unable to transfer files using FTP adapter
                            931735
                            Hi Arik,

                            I could transfer files upto 10mb but when i am trying to transfer files with size like 85mb i am getting following error code in the flowtrace:

                            <messages>
                            <input>
                            <Invoke_WS_Get_PutService_process_InputVariable>
                            <part name="payload">
                            <process>
                            <input>File_3.pdf</input>
                            </process>
                            </part>
                            </Invoke_WS_Get_PutService_process_InputVariable>
                            </input>
                            <fault>
                            <bpelFault>
                            <faultType>0</faultType>
                            <remoteFault>
                            <part name="summary">
                            <summary>Java heap space</summary>
                            </part>
                            <part name="detail">
                            <detail>java.lang.OutOfMemoryError: Java heap space at oracle.soa.common.util.NonSyncStringBuffer.ensureFreeSpace(NonSyncStringBuffer.java:210) at oracle.soa.common.util.NonSyncStringBuffer.append(NonSyncStringBuffer.java:513) at oracle.soa.common.util.NonSyncStringWriter.write(NonSyncStringWriter.java:120) at com.collaxa.common.util.XMLWriter.writeNode(XMLWriter.java:260) at com.collaxa.common.util.XMLWriter.writeRawNodeNoCData(XMLWriter.java:172) at com.collaxa.cube.engine.ext.bpel.common.BaseDetailsFormatter.write(BaseDetailsFormatter.java:152) at com.collaxa.cube.engine.ext.common.InvokeHandler$InOutDetailsFormatter.write(InvokeHandler.java:1313) at com.collaxa.cube.engine.ext.bpel.common.BaseDetailsFormatter.formatVariable(BaseDetailsFormatter.java:78) at com.collaxa.cube.engine.ext.bpel.common.BaseDetailsFormatter.format(BaseDetailsFormatter.java:66) at com.collaxa.cube.engine.audit.AuditHelper.doLogEvent(AuditHelper.java:187) at com.collaxa.cube.engine.audit.AuditHelper.logEvent(AuditHelper.java:141) at com.collaxa.cube.engine.ext.bpel.common.BPELWMPLogHelper.logAudit(BPELWMPLogHelper.java:87) at com.collaxa.cube.engine.ext.common.InvokeHandler.__callback(InvokeHandler.java:899) at com.collaxa.cube.engine.ext.common.InvokeHandler.handleNormalInvoke(InvokeHandler.java:600) at com.collaxa.cube.engine.ext.common.InvokeHandler.handle(InvokeHandler.java:132) at com.collaxa.cube.engine.ext.bpel.common.wmp.BPELInvokeWMP.__executeStatements(BPELInvokeWMP.java:74) at com.collaxa.cube.engine.ext.bpel.common.wmp.BaseBPELActivityWMP.perform(BaseBPELActivityWMP.java:166) at com.collaxa.cube.engine.CubeEngine.performActivity(CubeEngine.java:2687) at com.collaxa.cube.engine.CubeEngine._handleWorkItem(CubeEngine.java:1190) at com.collaxa.cube.engine.CubeEngine.handleWorkItem(CubeEngine.java:1093) at com.collaxa.cube.engine.dispatch.message.instance.PerformMessageHandler.handleLocal(PerformMessageHandler.java:76) at com.collaxa.cube.engine.dispatch.DispatchHelper.handleLocalMessage(DispatchHelper.java:218) at com.collaxa.cube.engine.dispatch.DispatchHelper.sendMemory(DispatchHelper.java:297) at com.collaxa.cube.engine.CubeEngine.endRequest(CubeEngine.java:4609) at com.collaxa.cube.engine.CubeEngine.endRequest(CubeEngine.java:4540) at com.collaxa.cube.engine.CubeEngine._createAndInvoke(CubeEngine.java:713) at com.collaxa.cube.engine.CubeEngine.createAndInvoke(CubeEngine.java:560) at com.collaxa.cube.engine.ejb.impl.CubeEngineBean.createAndInvoke(CubeEngineBean.java:103) at com.collaxa.cube.engine.ejb.impl.CubeEngineBean.syncCreateAndInvokeParticipate(CubeEngineBean.java:181) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) </detail>
                            </part>
                            <part name="code">
                            <code>java.lang.OutOfMemoryError</code>
                            </part>
                            </remoteFault>
                            </bpelFault>
                            </fault>
                            <faultType>
                            <message>0</message>
                            </faultType>
                            </messages>


                            I made following changes in Admin Console :
                            AdminConsole-->Environments---.Servers--->ManagedServer--->Configuration (TAB)--->ServerStart (SubTab)---> Arguments:(TextArea) -Xms1024m -Xmx1024m -XX:MaxPermSize=256m

                            I am still getting the above mentioned error even after setting the permSize=256m.

                            Edited by: 928732 on May 18, 2012 12:59 AM
                            • 11. Re: Unable to transfer files using FTP adapter
                              Arik
                              Can you please verify you've checked the Read File As Attachment check box?