Sender File Adapter picking the same file twice

We are facing a weird issue with File Sender Adapter
We are using PI File Adapter ( NFS ) to read files for a NFS folder and
processing those in PI.Normally it works fine. But for a scenario we
are noticing it sometimes process the same file twice before archiving,
thus duplicating the financial postings.
What we have is :
File Sender Adapter - NFS, Polling interval 60 secs, and Processign
mdoe Archive. File name includes Wildcards - JE_Upload*.txt
what we are noticing is that :
when it picks up a file, it immediately polls again to check for
another file, and sometimes the file is not yet archived so it picks up
and reprocess the same file.
If you see the message below, both belong to the same file, and it
picked up the same file again in 12 secs after processing it the first
time
   Successful 02.11.2009 15:01:00 02.11.2009 15:01:01   APMANUAL     urn:bl:i2g:003:100
SI_SKF_FIDOC_OB XI Message
   Successful 02.11.2009 15:00:49 02.11.2009 15:00:50   APMANUAL     urn:bl:i2g:003:100
SI_SKF_FIDOC_OB XI Message
Anyone seen this behavior before?

Hi,
Please check the script which creates file in source NFS Folders. There is possibility that script is making change in file when PI is picking up the file.
When PI picks the file first time it creates one message ID in system. After that if script is making any change in file without file name change (This need not necessary data change), for PI it becomes new file and new message gets generated in PI for same file.
This error normally comes when File adapter is not able to archive file succesfully. For eg. file with same name alredy exists in Archive folder.
File adapter generates the new message id whenfile get modified(eg.change in its length or data change) even though
the file name is same and when file get change ,XI file adapter thinks that its new file and hence generate the new message id for same file.
If file has same name and notmodified then XI adapter will not generate new message id and will keep on throw the error till you remove that file with same name from the
archieve directory.
-Warm Regards,
Gouri

Similar Messages

  • Problem in picking the same file

    Hi guys,
    i am picking the file a.txt from FTP server and sending it to the reciever.
    now howdo i make sure that the same file is not picked again if by chnace the file exist again by mistake.
    please reply guys,
    thanks
    Sahil

    > Hi Sarvesh u r right.
    >
    > i mean  in first attampt "a.txt"; file will be picked up by FTP adapter and will be deleted/archived from source location AND again by mistake if "a.txt"; file comes in source directory then i want to avoide to process the same file again.
    >
    > is it not possible in xi?
    I will not say that it is impossible, because I have a feeling that it can be achieved by using an OS command.
    If you see the option under Processing tab in your CC, there you will see "Run OS Command Before Message Processing". So may be you can write a script which will check if the same file is already present in target directory then don't pick the same file from source directory.
    At the other hand OS Command theory will fail if the same file was processed but it was deleted from the target directory because in that case script will have no clue to check existance of same file and in that case it will allow the CC to pick the same file again.
    Try it and let us know.. (I don't have any experance in writing scripts or using OS command).  If you feed difficulties in using OS command then search sdn and for writing an script you can create another thread and ask your question.

  • Email attachment name in sender mail adapter to the receiver file adapter

    HI ,
    Ths is regarding email to file scenario. I am trying to create file (in rceiver file adapter) with the same name as the email attachment that i read from mail sender adapter. I want ro use adapter module for this. I could find from blogs that there is module - GetAttachmentName - available that i can use for this in sender mail adapter.
    Can you please let me know what whetehr i neeed to mention any module key and parameters for this.
    I assume , i need to do following steps :Please confirm.
    1. i can use this module - after payload swap module and before standard mail adapter module in sender mail adapter
    2. select ASMA option in advanced tab in sender mail adapter
    3. In receiver file adapter select ASMA option in advanced tab in sender mail adapter
    4. Also select file name option in ASMA in sender mail adapter
    Thanks,
    Vamsi

    Hi Vamsi,
    your scenario is also described here: Re: sender mail adapter - attachment name
    If you use the Module getAttachmentName, which is described here,
    http://wiki.sdn.sap.com/wiki/display/XI/AdapterModulePI7.0GetAttachmentName
    your scenario should work as you described it.
    You just need to make sure that the Attachment Name that you read in the first place, is mapped to the Filename Attribute of the
    Fileadapter (http://sap.com/xi/XI/System/File/FileName).
    regards,
    Daniel

  • File adapter picking up partial files

    Hi All,
    We are facing a wierd problem with the File Adapter.
    The problem is that, we are getting the xml files from the source system, and PI is supposed to pick them up and process them. Sometimes, the file adapter is picking up the empty files / partial files, i.e., before the file is completely written on to the FTP folder.
    We tried increasing the polling interval. But this did not help. Since we are taking the files from the FTP, the option "MSecs" in Additional Parameters also will not work. As we are on PI 7.0 SP13, we tried to search for the "Empty File Handling" option wherein we can make the file adapter skip the 0kb files. But we are not able to find that option anywhere.
    Please help us find a solution to this problem.
    Thanks,
    Hari.

    Hari,
    In sender communication channel click on  Advanced. Then you see the paramter Msecs to Wait Before Modification Check. Add a value 3000. Then you should be good.
    Regards,
    ---Satish

  • I worked with files in LR that were originally on my C drive, then were moved to an external HD for storage. I now want to do some more work on those files (which have the same file name as on the C drive). I plugged the drive into my computer and it show

    I worked with files in LR that were originally on my C drive, then were moved to an external HD for storage. I now want to do some more work on those files (which have the same file name as on the C drive). I plugged the drive into my computer and it shows in LR under folders as the F drive and the little green light is on, but LR is showing only the first 6 files and not the remaining 200 or so. How do I expand the F folder to expose all files?

    I worked with files in LR that were originally on my C drive, then were moved to an external HD for storage. I now want to do some more work on those files (which have the same file name as on the C drive). I plugged the drive into my computer and it shows in LR under folders as the F drive and the little green light is on, but LR is showing only the first 6 files and not the remaining 200 or so. How do I expand the F folder to expose all files?

  • JCA DB Adapter process the same file twice in a clustered envrionment causing duplicate records

    We have 2 Nodes in a OSB Cluster and for one of the webservices we use DB Adapter to process the records and send it to external system.
    When ever we catch up with below exception and when the same records are reprocessed/retried the message is processed/sent by both the nodes which is causing a duplicate of records. 
    'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <1e3df38069b38bbe:3fdbec90:14c7cca0f5f:-8000-0000000000000006> <1428935826370> <BEA-000000> <<oracle.tip.adapter.db.InboundWork handleException> BINDING.JCA-11624
    DBActivationSpec Polling Exception.
    Query name: [XYZDBAdapterSelect], Descriptor name: [XYZDBAdapter.ABCEnrollment]. Polling the database for events failed on this iteration.
    Caused by JTS transaction was marked rollback only.
    Please advice!
    Thanks!

    You have to use MOVE operation, if there is any remote exception occured, then move the file to someother folder and again move back to the same folder where the file pickup will start.
    In that way you will be use the same file picked up next time when the polling happens.
    It is considered good etiquette to reward answerers with points (as "helpful" - 5 pts - or "correct" - 10pts).
    Thanks,
    Vijay

  • File Adapter Overwriting the output files

    Hi All,
    I´m using a File Receiver Adapter to write flat files on to an FTP. Same Communication Channel is used for all types of output files (As per the business requirement the file name(
    MzOutput.txt) shud b same for Deliverz orders, Purchase orders etc...). The receiver legacz szstem reads one file at atime and deletes it. So if i´m writing a Deliverz Order File, i have to wait until the file MzOutput.txt gets deleted and then i have to write the next file using the same name. in order to acheive this, i had used a module processor which waits until that MzOutput.txt gets deleted. Mz problem is
    As there are ´n´ no of orders waiting in the queue, if at 12:14:00 the MzOutput.txt gets deleted, then two threads which check for the existance of the MzOutput.txt file finds nothing and tries to write at same time. as a result, first file got overwritten by the second file.
    I dint check the indicator OverwriteExisting File in the CC configuration.If i use two different CC channels to write the same file, it is giving FTP Exception which is true.
    I´m loosing few deliveries as a result of the above case. Can anzone please help me out in this regard?
    Thnx in Advance
    Anil

    Hi Anil,
    Why dont you write the files with 'Add time stamp' option on for the file name and then the third party/legacy system to read the files in the order which they were created.?
    Another option will be to write these files into a folder with these Add time stamp option/counter option and make a shell script check the folder for the MzOutput.txt file exists in the folder from where the third party/legacy system reads the file and once it has deleted the existing file, then ur files shud be moved in the order in which they were written n the temporary folder.
    This will avoid the queue of messages in the adapter engine.
    Cheers
    JK

  • How to pick the sender files dynamically using the same File CC

    hi,
    My requirements is like , Same Sender File communication Channel has to pick up the different file which are having differnt file conventions and which are placed in different directories .. then it has to send to diffentn directories in the receiver side..
    how to do this?
    Regards,
    Balaji

    Hi Stefen,
    They have tried the Generic Sender File adapter concept to handle filenames with different names and from different directories instead creating many file channels. In my project many channels are configured as generic File sender channel.. And Eventhough the Generic file sender channels processing the filenames from different directories, all processed files are archieved in one common directories.. now they wanna generic solution to archieve the processed files in a particular folder based upon the directories they got processed from....
    and There are no such message mapping or Operation mapping since they used AAE concept. So do you  have any idea to make Generic File sender channels to archieve the files as per requirements i said before??
    Two doubts can we use like Module programming or can we do any OS level command acchieve this ? if yes please explain in detail .... Please help me out here
    please refer the following link .. exact way we used in our project
    http://wiki.sdn.sap.com/wiki/display/XI/SingleSenderFileCCForMultipleDirectories
    Regards,
    Balaji
    Edited by: Balaji Pichaimuthu on Feb 5, 2010 5:55 AM

  • Reg: Sender File Adapter - Picking the files serially

    Hi Folks
    I have a requirement where I require help from you with you valuable suggestions/solutions. Requirement is :
    1.  Two different folders(folder1 & Folder2) at sender system, PI has to pick the files from Folder 1 and needs to process to target.
    2. Exactly after 30min duration PI has to pick the files from the second folder i.e., from Folder 2.
    Conditions are :
    i)  Only after processing the files from Folder 1 PI should process the files from Folder2(after 30min).
    ii) We might have many files(approx 10 - 15files) in each folder, PI must poll all the file in the folder in a single poll(i.e., without any delay).
    Please suggest me what could be the best solution for this, either to create two communication channels or can we handle it using a single communication channel.
    Kindly suggest.

    Hi Suman,
    The easieiet way is to use single communication channel to pick up all the files from the first folder.  Then run a unix script in after processing column where it will check for any files to be picked by xi in folder1 and then proceed with transferring files from folder2 to target.
    By this, you are making the scenario simple and realistic.
    There are other alternatives like using two communication channels and the only hurdle will be the timing to check whether the folder1 files have been completely picked up or not.
    Regards
    Krish.

  • HA File Adapter still processing same file twice

    We are using the eis/HAFileAdapterMSSQL to watch for ZIP files that get dropped into a directory. We are running SOA Suite 11.1.1.6 on WebLogic 10.3 with a 2-server cluster. We set our PollingFrequency to 120 seconds.
    When our ZIP files are small enough to where our BPEL process (which does some unzipping and merging of files therein) completes within those 120 seconds, everything is fine. One, and only one, node in our cluster processes the file.
    But when the ZIP files are large, and our BPEL process takes 30 minutes to complete (i.e. longer than the 120 second polling frequency), we see a new instance of the BPEL process on soa_server1 start as expected, then second process instance start on our soa_server2 instance 120 seconds later.
    It's almost as if, if the entire BPEL process - which is kicked off by the HAFileAdapterMSSQL - does not complete within our polling frequency, then the file is not being blocked from other servers in our cluster picking it up and start processing it. Is there a way to "lock" the file with the first instance of the HAFileAdapterMSSQL that picks it up until it's completely finished with it?
    Has anyone encountered this?
    Thanks,
    Michael

    You need to define the below property in composite.xml file of your bpel. This will allow only one adapter active and another passive to pick up the file.
    <activationAgents>
    <activationAgent className="oracle.tip.adapter.fw.agent.jca.JCAActivationAgent" partnerLink="PickupFile/FTPConsumer">
    *<property name="clusterGroupId">BPELProcessNameCluster</property>*
    <property name="portType">FTP/FileConsumer_Message_ptt</property>
    </activationAgent>
    </activationAgents>
    Thanks,
    Vijay

  • Is is possible to read a file while writing the same file at time in java?

    Hi ,
    I am reading a MSAccess file (mdb) from one location to another location .but the source file is an online database which will chage regularly .so while reading that file i am getting error like
    FileNotFoundException.
    java.io.FileNotFoundException: c:\Msaccess\db2.mdb (The process cannot access the file because it is being used by another
    s)
    at java.io.FileInputStream.open(Native Method)
    at java.io.FileInputStream.<init>(FileInputStream.java:106)
    at read.main(read.java:16)

    alphabet soup,
    Yes, windows helpfully prevents two processes from accessing a file simultaneously. Operating Systems on the other hand uniformly support it.
    Which probably doesn't help you very much, as I imagine that you can't just up and change the source machine over to *nix, but there you have it.
    You'll just have to close the program which has the database open, copy the database, and restart the program which uses the database.
    keith.
    Message was edited by: corlettk

  • Xml file datamodel always the same file

    Hello,
    i have this kind of issue, i configured my ODI in the topology to load an external Xml file that will arrive every day. My load works good but i'm seeing now that ODI doesn't know that the file that i point to with configuration is different from one launch to another. It doesn't realize that the data inside are changed. I'm doing some test so every time that i receive a new xml file i rename the old one and i put there the new one. In my production system will be like this and scheduled but i'm scared about the fact that my ODI is not knowing the difference between my old file and the new one. Only if i close it and start it again he realize that the file is new and load the new data.
    Have i forgot some configuration in some place? If yes where is and how i've to manage?
    Thank you in Advance.
    Corrado

    Hello C.
    Actually it's an ODI Procedure.
    Try this:
    PACKAGE_XML (your XML process package)
    A) ODI PROCEDURE 01 (insert this step)
    B) XML INTERFACES
    C) ODI PROCEDURE 02 (insert this step)
    Configure ODI PROCEDURES like this:
    ODI PROCEDURE 01
    Technology: XML
    Comand on Target: SYNCHRONIZE FROM FILE
    Schema: Your Source XML Schema.
    Commit: Commit.
    ODI PROCEDURE 02
    Technology: XML
    Comand on Target: SYNCHRONIZE FROM DATABASE
    Schema: Your Target XML Schema.
    Commit: Commit.
    That is also explained on ODI Docs.
    Let me know if that helps.
    []'s

  • I am having a silly problem with Keynote and Pages. When ever i open a file, it opens the same file twice ?

    When ever i open a file using key note or pages. The files opens up two times. I the ave to close one version of the file and only then can begin work.
    Could you please help me how to get rid of this ?

    try routine software maintenance:
    1 - shut down the Mac
    start up the Mac again with the shift key pressed, release when Mac logo appears, let the Mac boot up it will take longer as it will be repairing the software
    2 - Applications > utilities > disc utility > select the system drive > disc first aid > repair permissions
    reboot normally and see if that helped

  • How to print .sql file name in the same file using sqlplus

    Oracle 10g on Linux platform.
    I am trying to print the name of .sql script file in that file but could not. Following is the file:
    test.sql
    select '&0' from dual;But instead of printing, it is asking for input:
    SQL> @test.sql
    Enter value for 0: Can any body give me a hint as how can i print the file name.

    Use this
    SELECT FNAME_KRBMSFT AS name FROM X$KRBMSFT
    and see
    SQL> create or replace procedure get_dir_list
    2 (p_directory varchar2)
    3 is
    4 l_null varchar2(100);
    5 l_directory varchar2(100);
    6 BEGIN
    7 l_directory := p_directory;
    8 sys.dbms_backup_restore.searchfiles(l_directory, l_null);
    9 FOR x IN (select fname_krbmsft fname from x$krbmsft) LOOP
    10 dbms_output.put_line(x.fname);
    11 END LOOP;
    12
    13 END;
    14 /
    Edited by: HuaMin Chen on Jun 26, 2012 12:26 PM

  • Anyone knows the maximum amount of simultaneous file connection (for the same file) for:

     a) READ
    and
    b) READ / WRITE for both SERVER2008R2 A N D SERVER 2012 ?
    Thanks
    [email protected]

    I belive you should look for any limitations in current tcp connections, and not specificly for the file service it self.
    I think you will reach the capacity of what the storage can provide, which most likely will result in read/write timeouts,  before you reach the maximum number of current tcp connections.
    Best Regards,
    Jesper Vindum, Denmark
    Systems Administrator
    Help the forum: Monitor(alert) your threads and vote helpful replies or mark them as answer, if it helps solving your problem.

Maybe you are looking for