File Adapter Write: Howto read partnerLinkBinding "logical path"-property?

A process writes a file to a fileserver, and further down the process I'd like to publish the path+filename of the written file to an external partnerLink.
I'm looking for something similar to ora:getPreference(), but instead reading a spesific partnerLinkBinding property not just the preferences-section property of bpel.xml.
alternative 1) From within the BPEL-process I configure a logical path, but I can't see any api for reading that value (my property "OutBoundFiles").
The value is read and used by the jca:operation within the FileWriter, and I supply a static value for it in the bpel.xml, like in:
<partnerLinkBinding name="OutboundFileWriter">
<property name="wsdlLocation">FileWriter.wsdl</property>
<property name="OutBoundFiles">\\fileserver\OutboundDir</property>
</partnerLinkBinding>
alternative 2) The FileWriter wsdl OutboundHeader_msg has the one-and-only element "fileName", which also contains what I'm looking for.
But I can't see how to read this element either, probably because the BPEL-team don't expose the value, due to the fact that they don't support writing to the element (there is no support for writing files to a dynamic path in version 10.1.2).
Current workaround:
Currently I use a preference property in which I copy the "OutBoundFiles"-value, and read it runtime using ora:getPreference(). Not a beauty.

alternative 3)
One could use a simple copy rule, by reading the bpel.xml-file:
<copy>
<from expression="ora:doc( 'bpel.xml', '/BPELSuitcase/BPELProcess/partnerLinkBindings/partnerLinkBinding[ @name = &quot;OutboundFileWriter&quot; ]/property[ @name = &quot;OutBoundFbFiles&quot; ]') "/>
<to variable="emailpayloadUNCPath"/>
</copy>

Similar Messages

  • File Adapter Writting and Reading strategy

    Hi All,
    When i am trying to write data to file, it was opened by another person and it gave error in the receiver communication channel saying like source is using by another application. Which is well and good
    But in case of Sender channel while writing the data to file even thought it is opened by another person, Sender file adapter is picked the file.
    I didn't get the reason why it is like this. Any one of u had the same issue???
    Regards

    Hi Neetesh,
    >>hmm ... that's weird ... you mean to say that the polling frequency is now (20 + 100) = 120 secs ? Unless and until the file is not being modified or the file is not "open", this parameter shouldn't work ...
    Examples
    Poll interval is 20 sec and MSecs to wait is 100000( 1 MIN 40 Sec)
    1) If file is there and did not opened / modifying
    waiting till 1 min 40sec to pick the file
    2) If the file is there and Modifying it
    Adapter is waiting 1 min 40sec if the files have been changed.
    3) If there is a file and just opened, not writing any files
    Waiting for 1 min 40 sec to pick the file
    >>Can you share the adapter log?
    Processing Details for Cluster Node Server 0 10_31463
         5/20/10 3:49:56 PM           Polling interval started. Length: 20.0 seconds
         5/20/10 3:49:56 PM           Processing finished successfully
         5/20/10 3:49:56 PM           Processing started
         5/20/10 3:49:56 PM            4f1e0c5b-9553-4397-30ef-d3bb55a13a48     Processing finished successfully
         5/20/10 3:49:55 PM            4f1e0c5b-9553-4397-30ef-d3bb55a13a48     Message with ID 4f1e0c5b-9553-4397-30ef-
                                                   d3bb55a13a48 processed
         5/20/10 3:48:15 PM           Processing started
         5/20/10 3:47:55 PM           Polling interval started. Length: 20.0 seconds
         5/20/10 3:47:55 PM           Processing finished successfully
         5/20/10 3:47:55 PM           Processing started
         5/20/10 3:47:35 PM           Polling interval started. Length: 20.0 seconds
    Regards
    Edited by: Vamsi Krishna on May 20, 2010 10:50 PM

  • File Adapter Write missing files

    Hello
    I have some trouble with a bpel process containing a file adapter that should write files to disk. Each bpel-process is started when a read file adapter reads a new matching file (*.xml).
    I have tested the process with a few files (5-20) and a new process is started for each file, and at the end of the process a new file is written to disk by the file adapter (Write). But when I am testing with a large number of files (40-50 files) something strange happens.
    A new process is started for each file, but it looks like the file adapter that should write files to disk is not capable to handle the pressure. 10-20% of the processes doesnt complete as expected. In the BPEL Console everything looks ok, it seems like the File Adaper has written a file to disk, no error is trown. But when I look in the directory the file is not there...
    Has this something to do with performance? Is there any parameters or settings I can tune to make the file adapters work better? Sometimes it also looks like the file adapter (read) doesnt manage to start a new process for each incomming file even if they are deleted and archived...

    I ran into a similar issue. As a workaround we ended up just using java to write the files out. When the File Adapter attempts to write out a file it first writes that file to a temp file and then copies that to the appropriate directory.
    I believe that when two or more threads were attempting to write at the same time the write was failing for one (but appearing to work in the console logs). I think a race condition may be created when two threads attempt to write using the File Adapter for access to the temp file. I contacted my oracle rep about it but they are always pretty worthless so I havent ever heard anything back concerning the issue.

  • File Adapter Write Compilation problem JDev 11.1.1.6 and BPEL 2.0

    Hi,
    Im creating a simple BPEL Project with a One-way Process template project.
    I have added just one Partnerlink with a File Adapter to do a write operation.
    I have assigned the main process input to the file Write Invoke operation.
    But I am getting a compilation error.
    Error(81): inputVariable "inputVariable" of type "client:BPELProcessWriteToFileRequestMessage" is not compatible with WSDL message "ns1:Write_msg".
    Can you pl help ?
    Here is the BPEL syntax :
    <?xml version = "1.0" encoding = "UTF-8" ?>
    <process name="BPELProcessWriteToFile"
    targetNamespace="http://xmlns.oracle.com/FirstApplication/FileWriter/BPELProcessWriteToFile"
    xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
    xmlns:client="http://xmlns.oracle.com/FirstApplication/FileWriter/BPELProcessWriteToFile"
    xmlns:ora="http://schemas.oracle.com/xpath/extension"
    xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
    xmlns:ns1="http://xmlns.oracle.com/pcbpel/adapter/file/FirstApplication/FileWriter/WriteTextToFile"
    xmlns:bpelx="http://schemas.oracle.com/bpel/extension"
    xmlns:bpws="http://schemas.xmlsoap.org/ws/2003/03/business-process/"
    xmlns:xp20="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20"
    xmlns:oraext="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc"
    xmlns:dvm="http://www.oracle.com/XSL/Transform/java/oracle.tip.dvm.LookupValue"
    xmlns:hwf="http://xmlns.oracle.com/bpel/workflow/xpath"
    xmlns:ids="http://xmlns.oracle.com/bpel/services/IdentityService/xpath"
    xmlns:bpm="http://xmlns.oracle.com/bpmn20/extensions"
    xmlns:xdk="http://schemas.oracle.com/bpel/extension/xpath/function/xdk"
    xmlns:xref="http://www.oracle.com/XSL/Transform/java/oracle.tip.xref.xpath.XRefXPathFunctions"
    xmlns:ldap="http://schemas.oracle.com/xpath/extension/ldap">
    <import namespace="http://xmlns.oracle.com/FirstApplication/FileWriter/BPELProcessWriteToFile" location="BPELProcessWriteToFile.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/>
    <partnerLinks>
    <partnerLink name="bpelprocesswritetofile_client" partnerLinkType="client:BPELProcessWriteToFile" myRole="BPELProcessWriteToFileProvider"/>
    <partnerLink name="WriteTextToFile" partnerLinkType="ns1:Write_plt"
    partnerRole="Write_role"/>
    </partnerLinks>
    <variables>
    <variable name="inputVariable" messageType="client:BPELProcessWriteToFileRequestMessage"/>
    </variables>
    <sequence name="main">
    <!-- Receive input from requestor. (Note: This maps to operation defined in BPELProcessWriteToFile.wsdl) -->
    <receive name="receiveInput" partnerLink="bpelprocesswritetofile_client" portType="client:BPELProcessWriteToFile" operation="process" variable="inputVariable" createInstance="yes"/>
    <assign name="Assign">
    <copy>
    <from>string('$inputVariable.payload/client:input')</from>
    <to>$inputVariable.payload/client:input</to>
    </copy>
    </assign>
    <invoke name="InvokeWriteTextToFile"
    partnerLink="WriteTextToFile" portType="ns1:Write_ptt"
    operation="Write"
    inputVariable="inputVariable" bpelx:invokeAsDetail="no"/>
    </sequence>
    </process>

    The error seen in your case typically occurs when the schemas of BPEL valriable and the schema of message in file adapter WSDL are different. You may use a transform activity in BPEL to map the fields of the two schemas.
    You may also like to have a look at various file adapter examples at
    http://java.net/projects/oraclesoasuite11g/pages/FileAdapters
    These samples provide working examples of how to handle various kinds of data when using file adapter.
    Regards.

  • File adapter didn't read the whole file

    Hi folks,
    we use the file adapter since 1 year and in the majority of cases it works fine. But sometimes the file adapter didn't read the whole file. In SAP we are missing some parts. Funnily enough in this cases he archive the whole file and not only the executed parts . Know anybody whats the reason of this effect and how we can solve it?
    Kind regards Johann M.

    Johann
    I think you miss understood me/I didn;t explain myself very well....
    If you take the file that doesn't work/process correctly, can you replicate the issue where the whole file is not copied across.
    If you can, you should be able to extend the FTP/File adapter trace file to find the cause if this issue.
    Log onto Visual Admin.
    &#61680;     Services
    &#61680;     Log Configurator
    &#61680;     Locations
    &#61680;     Choose the location (Java package) and the tracing level (severity)
    (for example, com.sap.aii.adapter.file)
    &#61680;     Root Location > com > sap > aii > File
    &#61680;     Set the severity and choose Copy Severity to Subtree
    Run interface and then check the trace file - remember to switch this back to Error...

  • File adapter unable to read file, can it call another BPEL process

    hi'
    I have a XML file to read and I am able to read it by using a File adapter, if the read is success the file is moved to success directory and if the file is invalid its going in the fail directory, now the question is If the file read is not valid at that moment can another BPEL process be invoked, becasue if the file read is invalid then the BPEL process dosent gets initiated due to which I am unable to do anything.
    please advice
    thanks
    Yatan

    Hi,
    You can use file rejection handler which can invoke a user defined BPEL process in case of invalid file. Check :
    http://www.oracle.com/technology/products/integration/adapters/pdf/Adapter_TN_004_Adapter_ErrorManagement.pdf
    HTH,
    Ketan

  • File adapter(write files with same extension as we read them)

    Hello
    I am trying to read file as an attachment using file adapter (it can be of any extension .pdf,.txt,.xml)
    I want to write this file using file adapter with the same extension i.e. whatever is read as it is....I am least bothered for reading the content inside the file so am reading it as an attachment..
    Please if anyone knows the answer..reply....

    I ran into a similar issue. As a workaround we ended up just using java to write the files out. When the File Adapter attempts to write out a file it first writes that file to a temp file and then copies that to the appropriate directory.
    I believe that when two or more threads were attempting to write at the same time the write was failing for one (but appearing to work in the console logs). I think a race condition may be created when two threads attempt to write using the File Adapter for access to the temp file. I contacted my oracle rep about it but they are always pretty worthless so I havent ever heard anything back concerning the issue.

  • Sender File Adapter is not reading anything

    Hi,
    I have a really strange problem here. I'm tyring to read a file using file adapter (FTP) and the adapter doesn't read anything and it does not throw any error in the communication channel monitoring.
    I'm using a receiver file adapter to write files to the same FTP folder, so it can't be a connectivity problem. And I tried to get the file using Filezilla and it works fine...
    In the sender file adapter I tried to simplify the maximum to solve the problem:
    - NO File Content Conversion
    - NO advanced attributes
    - I used the "*" in the file name to read any file
    - I've only configured the FTP connection, the folder and the file name. I don't understand why it isn't working...

    Yes I got this message:
    Polling interval started. Length: 5,0 seconds
    Now I tried something... In the FTP Connection parameters, I set as the server a random and unexisting name, and I get the same result...
    I'm starting to thing that some firewall is blocking the connection, but I have to wait until next monday to know this. But I don't understand why the receiver FTP channel is working...
    PD: The cache is correctly refreshed because I changed the polling interval time, and it has been updated on the monitoring

  • XI3.0 Receiver file adapter write to windows shared drive

    Hi,
    Our XI server SP09 currently runs on windows 2003 server,  I wish to use the receiver file adapter to create a file on another windows server.  I have created a folder on the other server and set permissions so that anyone can read and write to it. 
    The communication channel has been set-up with a target directory of //server/shared_folder/folder and a transport protocol of 'File system(NFS)'
    When I try and send an XML message to the file adapter I get the following error on the runtime workbench :-
    Last message processing started 09:47:10 2005-06-09, Error: Message processing failed with java.lang.Exception: Message processing failed - configuration error in file receiver adapter (Directory does not exist / cannot be created)
    My questions are as follows :-
    a) Do I have the target directory on the communication channel set-up correctly?  i.e. do I use / or \
    b) What username will need to be set-up on the other server so that the file adapter can write to the shared folder
    c) Is there another way of providing user and password information for connecting to the other server?
    Many thanks
    Ian

    Hi Ian
      as i understood from ur description is that u want ur file to b generated in some other machine then u have to mention that machine in ur SLD using correct specification..
    u go thru this link in order to get more Clearance..
    http://help.sap.com/saphelp_nw04/helpdata/en/31/f0ff69551e4f259fdad799a229363e/frameset.htm
    Hope this ll help u.
    Regards
    Shailesh

  • Need to get file name and directory back from file adapter - WRITE

    I am using the file adapter to write a file. I want to log the file name of the file we just created. Since we use a precise timestamp in the file name, I can't accurately guess.
    I have an invoke in my BPEL process to the file adapter. My first try was to assign the jca.file.FileName property to a variable, but it never comes back. I looked around and saw plenty of ways to SET the file name for a write and GET the file name for a read, but no GET file name for WRITE.
    Anyone have a solution?
    Thanks in advance!

    I think I got your point... You can tell FileAdapter the filename to write, but if you don't then FileAdapter can not tell you the filename that it wrote... I think it is pretty possible Oracle didn't implement the latter, as the write operation is probably asynchronous and the filename is calculated later on...
    If what you want is just log, you may achieve your requirement by increasing verbosity on Adapter logs... Have a look at the link bellow...
    http://docs.oracle.com/cd/E15586_01/integration.1111/e10226/ad_mon.htm#CJHHBBID
    Otherwise, the solution for you will be to calculate filename yourself, and that will be a little bit of reinventing the wheel... But at least you will know the filename...
    Cheers,
    Vlad

  • How to: Sender File Adapter to dinamically read all subfolders of a folder

    Here is the scenario:
    -Interface:  A file to file interface.
    -Objective: The idea is to move files from a file server to another file server.
    -Master Source Folder: ...\OUTPUT\
    -Master Destination Folder: .....\INPUT\
    Interface example
    -Source Folder: ...\OUTPUT\INTERFACE1
    -Destination Folder: .....\INPUT\INTERFACE1
    The idea is that the PI interface must read all the subfolders inside ..\OUTPUT\ and then move the files found to the corresponding folder in the target.
    What we want to achive is to be able to add a new source folder i.e ...\OUTPUT\INTERFACE2 without having to modify the sender File adapter.
    Actual status: Dynamic determination of the destination folder is already done, but source folders are statically defined in the sender file adapter.
    Can this be done? Perhaps using a Bean Module or something?
    Regards.
    Mariano Billinghurst.

    This is great! In the off chance anyone else is trying to do this, this is also useful if you have Papers and you want to switch to Mendeley. Papers keeps PDFs all organized by year and then author so the PDFs are all nested in subfolders. If you option-click the triangle next to the Papers folder, it will then show all the PDFs. Select All and then drag over the whole thing into Mendeley. I just imported my entire collection in under a minute. Glad I looked this up!

  • Need  file adapter polling with read operation to be triggered by a BPEL without using synchronous read

    The scenario is:-
    Web Service Client -->input-->BPEL-->if input valid-->trigger file adapter with read operation--> receive file
    i am not able to stop the polling until it is required to trigger the polling.
    As soon as i deploy the composite the file adapter starts polling without waiting for input.
    Since i am using two receive activities, the second one which is suppose to receive file from file adapter is always showing pending state. (asynchronous callback)

    Hi there,
    IMHO the traditional read is used only as inbound operation, that means
    that it starts polling the input folder as soon as the composite gets
    deployed - which is the same you are experiencing.
    In your case you need an outbound operation that needs to be invoked at
    a certain moment. I don't know what are the reasons not to use sync
    read, but this is the only outbound read operation supported by the
    adapter. If you can not use the sync read, then you would have to design
    some custom solution where you call a web service or EJB for instance
    that reads the desired files.
    Another option I can think of, though have not use personally is using
    the adapters programatically in Java - take a look at this blog post as
    it seems related to this topic -
    https://technology.amis.nl/2012/01/22/using-the-oracle-weblogic-technology-adapters-with-custom-java-message-driven-bean-mdb-triggered-by-file-adapter-part-of-the-story/.
    Hope this helps,
    A.

  • File adapter write to network drive fails

    Hi all,
    I have a problem using the FIle adapter. The situation is as follows:
    - SOA Suite 10.1.3.5.0. installed on Windows
    - SOA Suite runs under windows user soaadmin, a user with local admin rights.
    - A network share is mapped as a network drive on a remote (windows) server, assigned drive letter 'T'.
    - user soaadmin is added to a user group on the remote server that has local admin rights on the remote server.
    - In my BPEL process, the file adapter is configured to write files to 'T' drive.
    - At runtime, ORABPEL-11054 occurs: Directory cannot be created successfully. Directory: T:/ cannot be created successfully.
    - If I configure the file adapter to write to 'C' drive all functions well.
    - From the windows explorer, user soaadmin can create files on 'T' successfully soa apparently has the right privileges on 'T'.
    Any clue as to what may be wrong?
    Thanks in advance,
    Regards Rob

    please use FTP adapter instead of File Adapter.
    Thanks,
    Chandra_

  • File adapter - Write - Elapsed Time based batching not working.

    We are creating an asynchronous BPEL process that creates a file every 2 mins with the messages the BPEL process received in the last 2 minutes. We are using a file adapter with only "elapsed time" set to 2 minutes (Number of Messages and File size disabled) . If we deploy this into BPEL console and use bpel console's stress test feature, it doesnt create any file at all. If we use a file adapter based on Number of messages, it works fine. Can any one of you suggest what could be the problem ?

    Unfortunately, this is documented bahaviour (solution/workaround anyone?!):
    Elapsed Time Exceeds:
    Specify a time which, when exceeded, causes a new outgoing file to be created.
    Note:
    The Elapsed Time Exceeds batching criteria is evaluated and a new outgoing file is created, only when an invocation happens.
    For example, if you specify that elapsed time exceeds 15 seconds, then the first message that is received is not written out, even after 15 seconds, as batching conditions are not valid. If a second message is received, then batching conditions become valid for the first one, and an output file is created when the elapsed time exceeds 15 seconds.

  • File Adapter Write Operation inserts a new line at the end

    Hi,
    I am using the write operation in the File Adapter from BPEL Process. The data is written successfully to the file and file is also created in the location specified in the adapter wsdl. But in the file created, it creates a new line at the end of the file. This new line has to be avoided when writing data to a file.
    Has anyone faced this and solved this ?
    I am SOA 10.1.3.4.
    Cheers,
    - AR

    It is a bug in 10g and will be resolved in one of the versions of 11g.
    Cheers,
    -AR

Maybe you are looking for

  • How to make custom  validator in jsf

    hi i am using jsf for web designing in my projects.now we are using java script for JSF validation .but i am interested to do validation using validator tag of JSF.i have tried ,but it is not working.what can i do for this problem.can u give some sim

  • Log changed data in tables

    hi I want to hold change data information. For example I have table student and one row is inserted. Then somebody else changed the name of the student name and phone number. I want to hold the changed columns when an update query is executed. I look

  • Error importing RFC / idoc despite following note 769356

    We have been experiencing a number of problems where we cannot import RFC / idocs in the integration repository.  The BASIS team have followed note 769356 and originally this solved the problem but meant that we reverted back to old screens in the In

  • Can some columns be exculded from hide feature of panelCollection?

    Hi All, First of all KUDOS to OTN forum developers/users for the new AVATAR of forums. [clap...clap!!] I am using panelCollection for hiding and showing columns in my table. Now there exists a primary key column in my table. What I want to do is, use

  • How do I move all my stuff from my trial version of FCP X over to my purchased version?

    How do I move all my stuff from my trial version of FCP X over to my purchased version?