File addapter cmd before processing message

hello
I have a file adapter sender scenario. I would like to run a simple command that run before processing the message,
and need to do a rename to the file that I would like to load.
for example, I have aaa.txt, I have a script that changes the name of the file, and then I would like to load the new file and do all the process of the channel on him.
it seems like the PI is catching aaa.txt file and doesnt let me to change its name and to work on the new file.
in the script I am using a simple move command.
any ideas?
Kfir

Hi,
Please check the below mentioned links :
https://www.sdn.sap.com/irj/sdn/wiki?path=/display/xi/sapXIFileAdapterOSCommandLine+Feature
/people/santhosh.kumarv/blog/2008/07/27/glimpse-at-os-command-yet-another-scenario

Similar Messages

  • FTP sender adapter wait sometime before processing a message

    Hi,
    I want my FTP sender adapter to wait sometime before processing a message. This is needed in my case since the receiver of the message cannot consume message in, say two seconds, so I would like to configure a "time to wait before processing message" in PI since PI processes all of the files in folder without waiting another poll interval time if more than one exist.
    Is this possible in PI 7.0 sp16? 
    Regards,

    HI Tarik
    BPM is the solution for this problem. If you are not willing to use BPM other solutions are  Adapter module and Scripts
    You can write adapter module and use the threads mechanism. Thread.sleep can help you achieve this but you need to set this properly.
    Another method is Unix script. Let your actual directory be Dir1 and poll PI to Dir2. Use the script to write files from Dir1 to Dir2 one by one and with time gap. This will work for you.
    If you have PI system on Windows i prefer to go with Adapter module.
    Thanks
    Gaurav

  • File Adapter: Run OS command unix after processing message

    Hi,
    in file adapter configuaration, after processing message, I've configured the channel that it has to call an unix script.
    The sintax in configuration is:
    sh /XS0/usr/sap/XS0/DVEBMGS01/work/TEST_FILE_XI/OUT/rename_lib_contabili.sh <variable>.
    I tried also without the entire path and without the sh command at start of it.
    We have a XI 3.0 sp20.
    I don't understand, What other I have to do.
    Regards,
    Antonello

    Hi Carme,
    I found a warning that "describes" the error...
    2009-09-29 13:36:15     Success     Write to file "/XS0/usr/sap/XS0/DVEBMGS01/work/TEST_FILE_XI/OUT/LIBROGIORNALE_test_mov.zip" as binary, size 7248 bytes
    2009-09-29 13:36:15     Success     Execute OS command "/home/xs0adm/scripts/rename_lib_contabili.sh LIBROGIORNALE_test_mov.zip"
    2009-09-29 13:36:15     Warning     Error when executing OS command "/home/xs0adm/scripts/rename_lib_contabili.sh LIBROGIORNALE_test_mov.zip"
    2009-09-29 13:36:15     Success     File processing complete
    2009-09-29 13:36:15     Success     MP: Leaving module processor
    2009-09-29 13:36:15     Success     The message was successfully delivered to the application using connection
    File_http://sap.com/xi/XI/System.
    2009-09-29 13:36:15     Success     The message status set to DLVD.
    if I try to execute this script from Unix schell or ABAP OS shell this working fine.
    You have any idea?!
    Thanks,
    Antonello

  • "Exception Processing Message" error when clicking the Accessing Server Data link on the start page

    When I first started the application, I click the Accessing Server Data link on the start page.  I immediately got the error "Exception Processing Message c0000013 Parameters 75b6bf7c 4 75b6bf7c 75b6bf7c in a dialog box titled "Windows - No Disk".  I had to used Task Manager to remove the box after closing Flash Builder 4.  I then tried the video tutorial on "PHP Services in Flash Builder 4".  I keep receiving an error during service introspection trying to connect to the PHP class.  It was the same error as the other individual "Cannot Connect to PHP Service".  So I tried another tutorial and generated a sample PHP class.  I moved a datagrid on to the stage, droped in the getAllItems function, and configured the return type.  However, when I ran the app, I received the same error "Exception Processing Message" again.  I have attached the screenshot of the error in addition to my phpinfo and log files.

    "The exception process message" is definitely a issue. Is it happening consistently, if so can you file a bug at bugs.adobe.com/flex and give out your machine config details, and the error log.
    With regards to generating a new php file and the introspection error that you are getting, looking at the logs it probably is two fold.
    First off the name of the file and the class name should be the same, are you having employeeServices as the name of the class in employeeServices.php file.
    Second, It seems prior to generating this new file, you had a syntax error at line 5.
    It would be easier to figure out what the error is, if you can also attach the php file, by removing any sensitive information in that.
    Hope this helps.
    Thanks
    -Sunil

  • Sender jms adapter-archiving before processing the message

    Hi,
    Do we have any option in Sender JMS adapter to archive the message before processing the message?
    I have searched in sender JMS adapter (XI7.0) settings, but couldn't find any option.
    My assumption is whether any option provided in configuration setting of adapter engine or any other alternatives.
    Thanks,
    Srini.

    Hi Srini.
    Here is the code. But you may prefer the EAR module, just for deploy. I need your email to send it to you.
    If you want to create it yourself follow the steps in this guide and paste the code:
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/f013e82c-e56e-2910-c3ae-c602a67b918e
    When you configure the module in the JMS sender communication channel you have to spedify 2 parameter for the log file location:
    "file.path" (XI server file system path) and "file.name"
    CODE:
    package com.bfa.af.modules;
    import java.io.FileWriter;
    import java.io.IOException;
    import java.io.PrintWriter;
    import java.util.Date;
    import javax.ejb.CreateException;
    import javax.ejb.SessionBean;
    import javax.ejb.SessionContext;
    import com.sap.aii.af.mp.module.Module;
    import com.sap.aii.af.mp.module.ModuleContext;
    import com.sap.aii.af.mp.module.ModuleData;
    import com.sap.aii.af.mp.module.ModuleException;
    import com.sap.aii.af.ra.ms.api.Message;
    @author ibermatica
    public class BFATraceModule implements SessionBean, Module {
         private SessionContext myContext;
         public void ejbRemove() {
         public void ejbActivate() {
         public void ejbPassivate() {
         public void setSessionContext(SessionContext context) {
              myContext = context;
         public void ejbCreate() throws CreateException {
         public ModuleData process(ModuleContext moduleContext, ModuleData inputModuleData) throws ModuleException
              FileWriter outFile;
              try
                   Date date = new Date();
                   String filePath = moduleContext.getContextData("file.path");
                   String fileName = moduleContext.getContextData("file.name");
                   outFile = new FileWriter(filePath + System.getProperty("file.separator") + fileName, true);
              catch (IOException e)
                   e.printStackTrace();
                   throw new ModuleException(e);
              PrintWriter out = new PrintWriter(outFile, true);
              try
                   out.println("--- Start of message ---");
                   //Get message content.
                   Message data = (Message)inputModuleData.getPrincipalData();
                   if(data.getDocument() != null)
                        out.println(data.getDocument().getText());
                   else
                        out.println("Empty message.");
                   out.println("--- End of message ---");
                   out.println("Total characters: " + data.getDocument().getText().length());
              catch(Exception exc)
                   out.println(exc.toString());
              finally
                   if(out != null)
                        out.close();     
                   if(outFile != null)
                        try {
                             outFile.close();
                        } catch (IOException e1) {
                             throw new ModuleException(e1);
              return inputModuleData;

  • Need to backup the file before processing in XI

    Hi all
       I need to backup the incoming the file and then processing it in XI.(i.e)sender adapter picks the file and then backup that file and then send it onto IE.
       I am aware that there is a option in sender file  CC "Run operating system Command Before Msg Proceessing".We have to set one batch file in it.
    Could you please explain whats the exact commands for this case?

    Hi Rajesh,
    >>>>backup
    For you information you can archive the file details of the modes are below
    Processing Mode as 
    A) Archive
    Files that have been successfully processed are moved to an archive directory.
    1) To add a time stamp to a file name, select the Add Time Stamp indicator.
    The time stamp has the format yyyMMdd-hhMMss-SSS_. The time stamp ensures that the archived files are not overwritten and it enables you to sort them according to the time that they were received.
    2)Under Archive Directory, enter the name of the archive directory.
       If you want to archive the files on the FTP server, set the Archive Files on FTP Server indicator. If you do not set the indicator, the files are archived in the Adapter Engine file system.
    B)  Delete
    Successfully processed files are deleted.
    C)   Test
    Files are not processed.
    Only use this mode to test the configurations of the file/FTP adapter or the Integration Engine/PCK. It is not suitable for productive operation.
    D)Set to Read-Only
    Successfully processed files are given this attribute. Only writable files are processed. This selection is only available for the File System (NFS) transport protocol.
    >>>>>Run Operating System Command Before/After Message Processing
      Command Line
    An operating system command specified here is executed before or after the message processing of a file that was found in a run. The default value is an empty character string (no command).
    When the operating system command is called, the file name currently being processed can be specified with the following placeholders:
    1)       %f (file name)
    2)     %F(absolute file name including path)
    3)      Timeout (secs)
    This specifies the maximum runtime of the executing program in seconds. When this time interval is exceeded, the adapter continues processing. The executing program continues to run in the background.
    4)    Terminate Program After Timeout
    Set this indicator if the adapter is to terminate the executing program when the timeout is exceeded.
    The adapter writes the output (STDOUT and STDERR) for the operating system command in the system trace.
    Message processing is independent of any errors that occur during the execution of a configured operating system command.
    for more information
    http://help.sap.com/saphelp_nw04/helpdata/en/e1/a63d40c6d98437e10000000a155106/frameset.htm
    ****PS:reward points if useful**
    Regards,
    Sumit Gupta

  • The new updated version of iMovie 10 won't let me open my previous files I created before the update today. I have a wedding that I'm trying to finish and deliver and now I can't because that file version won't open. I keep getting an error message

    Hello,
    Please help me figure this out. I'm very unhappy at the moment. I'm fustrated and don't have any idea how to revert to the original version before the update was done on iMovie 10. I NEVER hated APPLE until NOW!! I love APPLE products and apps so please help me stay in that mindset. So I worked on some movie projects when I got my macbook pro 6 months ago. I update reguarly. I saw the update prompt and honestly, I did not think I would have ANY issuess with opening my previous files that I created only a few months ago with this updated version.The new updated version of iMovie 10 won't let me open my previous files I created before the update today. I have a wedding that I'm trying to finish and deliver and now I can't because that file version won't open. I keep getting an error message and the iMovie app closes. Last night I saw the file and tried to open it but no luck. Error message came up again. I reboot and turned off my laptop for the evening and tried again just now but nothing!! I need that video. My job depends on it! I worked so hard on this wedding video and now it's lost and won't open. I work another job and don't have much time. I really don't want to start all over again. Please help me. Thanks so much for your assistance.
    Fustrated APPLE customer
    Jolly A. Rupp

    I also have Jolly's problem. I found the iMovie 9.0.9 folder and tried to launch the older version of iMove. It would not launch. I removed all of the iMovie preferences from the Preferences folder, removed iMove 10 from the applications folder, and restarted my Mac. iMove 9.0.9 still won't launch and I can't access my videos created with the older version of iMovie. Is there a way to uninstall iMovie 10 and reinstall iMovie 9.0.9?
    I am running Yosemitie on a  iMac.
    Paul

  • How to Run Operating System Command Before/After Message Processing SAP PI

    Hi,
    We are trying to execute multiple commands via "Operating System Command Before/After Message Processing".
    When we use single command say for example cp or mv (copy or move) the commands get executed fine.
    eg: cp %F /var/opt/data/outbound/Test/Dummy.txt 
    /this works fine/
    when we club commands together or try to redirect the outputs of commands, none of the commands get executed.
    eg:
    cp %F /var/opt/data/outbound/Test/Dummy.txt ; rm %F
    or
    wc -l %F > /var/opt/data/outbound/Test/Dummy.txt
    Is it possible to execute multiple commands or redirect the output  of commands without using a shell script? The PI server we are working on iis hosted on UNIX environment.

    Hi Harleen,
    try like this
    cp %F /var/opt/data/outbound/Test/Dummy.txt ; rm %F
    instead of semicolon try this
    (1) &
    command1 & command2
    Execute Command1 and then execute Command2
    (2) &&
    command1 && command2
    Runs the command2 only when command1 doesn't Complete successfully
    (3) ||
    command1 || command2
    Runs the second command if the first command had an error
    (4) ()
    (command1 || command2) || (command3 & command4)
    Defines the order in which commands are to be executed
    Regards
    Suraj

  • File to RFC - error while processing message to remote system:com.sap.aii.

    Hi
    i m working on File to RFC scenario. the records are getting displayed in sender CC and receiver CC. But in receiver CC i m also getting the following error:
    Message processing failed. Cause: com.sap.engine.interfaces.messaging.api.exception.MessagingException: com.sap.aii.adapter.rfc.afcommunication.RfcAFWException: error while processing message to remote system:com.sap.aii.adapter.rfc.core.client.RfcClientException: JCO.Exception while calling ZRFC in remote system (RfcClient[CC_RIS_STC_PIMASTER_RECEIVER]):com.sap.mw.jco.JCO$Exception: (104) RFC_ERROR_SYSTEM_FAILURE:      Screen output without connection to user.    
    Error in processing caused by: com.sap.aii.adapter.rfc.afcommunication.RfcAFWException: error while processing message to remote system:com.sap.aii.adapter.rfc.core.client.RfcClientException: JCO.Exception while calling ZRFC in remote system (RfcClient[CC_RIS_STC_PIMASTER_RECEIVER]):com.sap.mw.jco.JCO$Exception: (104) RFC_ERROR_SYSTEM_FAILURE:      Screen output without connection to user.   
    It was working fine few hours earlier but showing this error now. i was giving a SUBMIT program , but stopped that now.
    But still facing the same problem. and in SXMB_MONI its showing recorded for Outbound processing.
    could anyone help.

    Hi
    I am Facing  Following Error When I am trying to call SAP Screen through JCO.jar
    com.sap.mw.jco.JCO$Exception: (104) RFC_ERROR_SYSTEM_FAILURE: Screen output without connection to user
    Please Guide Whethere it is possible to call SAP screen Through JCO.jar  ot NOT
    Please HELP if it is possible to Call SAP screen through JCO.jar with step and Code
    Thanks
    Vivek

  • I am batch processing in PS 2014 (watermark and saving as jpeg from ps file). I get the message for some but not all 'this file needs to be saved as a copy with this option'. And then I have to save it manually. Does anyone know why this happens? (It is j

    I am batch processing in PS 2014 (watermark and saving as jpeg from ps file). I get the message for some but not all 'this file needs to be saved as a copy with this option'. And then I have to save it manually. Does anyone know why this happens? (It is just a plain photoshop file, a watermark is added, then save as jpeg - the jpeg is saved to a different folder than the original photoshop file.)  It happens for about 10 of 30/40  files approximately . Thank you, Kathryn

    I believe I have figured it out - I need to flatten the image, even though there are no layers except for layer 0, first.

  • Want to Archive(or)Delete the file after finish the processing tht message

    Hi,
       My scenario is File to File  scenario that is working fine. due to some performance reasons i want to Archive the file (in sender communication channel level) after finish the process . that means after genarting the file in the target directory  then only i want to delete the file in the source directory.
    Any solution for this.....
    Please suggest me .
    Regards
    Jain

    Thanks for your suggestions..
      But that (Delete, Archive) option is there in the sender comunication channel level.. i knew that and that is working fine  in my scenario... but  my requirement is i want to delete the file after finished the process.. because some times message was failed in the Mapping level. but i want for some enahanced functionality point of view i want to delete or Archiveing the file after finish the process that means after genarting the file into target directory....
    Any help will be appriciated.
    Regards
    Jain

  • How to execute SQOOP.cmd file from SSIS execute process task?

    How to execute SQOOP.cmd file from SSIS execute process task?
    What is argument need to be prefixed in the arguments property
    Executable: C:\Hadoop\sqoop-1.4.2\bin\sqoop.cmd
    Arguments: /C "sqoop import -connect "jdbc:sqlserver://mysystem:1433;database=test;username=myuser;password=mypwd;" -table emp  -target-dir /user/emptable -m 1"
    Thanks
    Durga

    Hi Durga,
    SQOOP.cmd must be no different than any other .cmd/.bat I assume, your question is more about setting the parameters up I guessed.
    So unless the arguments change dynamically you can call SQOOP.cmd from yet another .cmd that has its parameters passed to it and the former you simply set to run without the arguments in Execute Process Task.
    Otherwise, in general to set a bat/cmd file to run in SSIS one needs to do this:
    PS: It is a good idea to populate the working directory with the path to the .cmd
    Arthur My Blog

  • HELP - Receiving error message "The file has not been processed. An error has occurred which stopped the processing of the PDF"

    Have been using Adobe CreatePDF for many months successfully.
    Only recently over the past few days I have been experiencing errors for periods between 3-5 hours on every attempt to convert/combine files. The error reads: "The file has not been processed. An error has occurred which stopped the processing of the PDF"
    It will stay like this and no amount of refreshing the cache, logging in and out will help. I'm running Firefox 34.0.5, windows 7 64bit. Only solution I've found is to wait until the next day and it seems to be working again. Only explanation i can think of is some unexplained maintenance adobe is running behind the scenes because I'm often working late between 12am - 4am.
    When this problem happens, no file types will convert/combine I've tested JPEG, PDF and word docs to PDF.
    I log in and out of my account, I've cleared my cache, I'm using Firefox 34.0.5 which has always worked in the past I just don't understand how this error is happening for such long periods. Starting to reconsider this product when there are free alternatives to simply combine my PDF docs! please help.
    Tom.

    I am still experiencing this problem. Customer service from Adobe has been abysmal!
    I called Adobe tech support at 2am Australian time ( >1 weeks ago) and got onto a help centre in India. I was walked through all the troubleshooting steps and they remotely accessed my PC and confirmed that It was not my PC that was at fault. They reset my password and dialed into my adobe account from their end to attempt a simple conversion and export to PDF which failed. I was told that this problem is not something they can fix, and is a result of something on the back end of their software.
    They advised me that the problem would be passed to a fixed within 12 hours and they would call and email me to confirm everything was OK. I gave my phone number with (area and country code) my email but have not had any communication back.
    I am extremely dissatisfied, and just want this software to function. Is that too much to ask?
    Note: This problem is happening always now, regardless of time being used.
    Tom

  • Illustr 10 - ERROR MESSAGE "Exception Processing Message"

    XP SP3, 8GB RAM, lots of storage
    Went back to open previous projects and got this message:
    "Windows - No Disk
    Exception Processing Message
    c0000013 Parameters 75b6bf9c 4 75b6bf9c 75b6bf9c"
    Message keeps popping back up. Only happens on certain files. ???
    Never had this problem before, I'm pulling my hair out.
    I did full system fatal restore this morning, ran virus check, reinstalled all Adobe, the whole bit. Opened up the same files ... after all that, same problem.

    Yes, I was on that thread the other day ... it seems like there isn't one definitive answer to this (Google provides many different answers). As I have multiple hard drives and the file was originally designed on an external hard drive "book", you might be pointing me the right direction. Thanks for the suggestion.

  • How to keep waiting time between processed messages !!

    Hi Folks,
    I have got one scenario required waiting time between processed messages. The problem as follows !!
    File --> Proxy scenario. I receive 15 messages from sender side (same messages structure) so working with one interfaces. File picking and transforming this message and split into 2 messages. messages are receiving to receiver. I am using BPM with 7,8 steps like receiving step, block , message transformation step , internal block 1 for sender 1, internal block 2 for sender 2.
    All things are working fine, messages are going to receiver properly. But customer requirement is , wait step required between processed messages before sender1. I have put wait step still, PI picks all messages in one shot processing and waiting for 2 minutes, after 2 minutes sending all messages at the same time, this process is not working.
    I have tried with wait step in mapping (Sarvesh) given excellent idea, still PI works the same way.
    Can someone please explain a bit why the messages or not waiting message by message. I am using EOIO with Queue name and file process mode "BY NAME" and I have tried "BY TIME" as well. I have given priority to this Queue. On BPM Queue assignment : One Queue.
    Please I am expecting positive answer !!
    Many Thanks in Advance
    San

    Hi Rudolf Yaskorski ,
    Not sure about your PI release and BPM model, do you create separate process instance for each file, or do you process files collecting them in one single instance? Are you using parallelization within your ccBPM ?
    I am using serialization, I don't think bpm can do Parallization until PI 7.0, but PI 7.11 has got has queue assignment. But I am using one queue. This must be serialization.
    To me it looks like your issue is not in ccBPM but rather more in polling files (as per your post file CC polls all 15 files in one shot). So if you wish to poll the files not at the same time some workaround is required. Possible options you could check out:
    A. Either implement "wait" in your mapping based on file name or other criteria (e.g. directory name). Check out if respective BPM instances are really created at different times.
    I have used wait step in mapping. These 15 messages has to go through one interface. So I am using one interface. But I have checked mapping process time in all messages on receiver system. Shows same timing, even though I put 40000 ms waiting time in mapping.
    B. Try polling different files (or use different directories) with different channels and coordinate starting / stopping of your channels by scheduling availability for each CC in RWB. E.g. you poll file 1 with CC 1. You start 2 minutes later CC 2 and poll file 2. And so on.
    I am not clear about this . On BPM waiting step is working and it keeps wait all messages, which are coming through one interface. Then it releases all messages at the same time.
    I don't know how to resolve this. I have tried with Transport acknowledgment, but all messages are going to reciver system waiting at receiver system in priority queue and processing in EOIO, but taking so long. Rather all messages go and sits in queue, I want to stop messages by message with 2 minutes time gap. How please?
    Kind Regards
    San

Maybe you are looking for

  • Different field groups in the different account groups

    Dear IT Experts, I´m working on restructuring authorization in roles concerning the IC and TP customers. The goal of this changes is be able to have different field groups in the different account groups (TP and IC), for give you some more detail a g

  • Good MM Functional Book in PDF File.

    HI friend , pls give some web side name from where i can get the mm functional book list in pdf file, Soumen (m)09831168902

  • Create .dll

    i don't know how to create dll file, which i want use to link with another file(.lib), any one can help? thanks in advance!

  • Dialog not visible from sidekick when using dialog participant step

    I am using the Out of the box dialog participant step in my workflow. I have created a dialog and using in the dialog participant step. When i start the workflow, the dialog is only available/visible when I complete the task from inbox and not visibl

  • How to limit the selection of Ship To Party

    I have a Biz Case: "A" user have 2 Ship to party "B" and "C" in the customer master data, when I create a OR order, I found I can use "D" user as the ship to party(of course, A is sold to party). So I want to impl this function: if sold to party is A