FTP file to SOAP asyn

I created a simple scenario which using FTP file adapter to send out a xml message, then I want to use SOAP adapter to receive the message and send it to a web service to display the message. No response back.
My data type is as follows:
DATA_FILESENDER
empid string
empname string
empage integer
flag
I created two messages which use same data type above for inbound and outbound interface.
Then I created a web service. its wsdl file has input message structure the same as above, no output message structure. The target name space is different from XI's.
When the scenario run, message monitoring shows FTP successfuly send out the message, but SOAP adapter was waiting, then after a while it says system error. I guess it is timeouted.
Could anybody tell me where is wrong with my SOAP adapter or my web service? Thanks a lot!
Marea

Hi,
Sekhar and Bhavesh,
I thought I posted the reponse and I was really wondering why no update comes to my email account during past days. It aprently I did not post successfuly.
Anyway, Thanks for the input! I have checked URL and action and check the links provided. But it still does not working. And Has the same error. I am wondering if that is the problem: Soap adapter send out the XML message, but the web service only accept data input seperately. Because I tested my webservice by sending data like "4","c","6","Y" using java program, not sending XML message, the webservice works. I still don't know how to make webservice to work for XI. Please advice. Thank you very much!
Marea

Similar Messages

  • File to SOAP,error in sender file adapter

    Hi,
    I am doing a scenario FILE to SOAP where In file adapter I am using Quality od service as Exactly once in order.I am getting the below error.It works fine when I use QOS=Exactly once.Not sure why,can you guys please help me.Can we really use QOS-EOIO for sender file adapter,where exacly do we use it.
    Thanks
      <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Call Adapter  -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:Category>XIAdapterFramework</SAP:Category>
      <SAP:Code area="MESSAGE">GENERAL</SAP:Code>
      <SAP:P1 />
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText>com.sap.aii.af.ra.ms.api.DeliveryException: invalid content type for SOAP: TEXT/HTML</SAP:AdditionalText>
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack />
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    Edited by: guest xi on Apr 16, 2008 11:55 AM

    Hi,
    Thanks for your replies guys.I diid give the queue name ,I dont know what is causing the error.Now even QOS=EO which was working fine before is throwing an error.I am using the same file name for both
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Call Adapter   -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:Category>XIAdapterFramework</SAP:Category>
      <SAP:Code area="MESSAGE">GENERAL</SAP:Code>
      <SAP:P1 />
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText>com.sap.aii.af.ra.ms.api.DeliveryException: invalid content type for SOAP: TEXT/HTML</SAP:AdditionalText>
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack />
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>

  • How to show FTP Files in JTable, i gave codeeeee

    hi to all,
    plz any one can help me to show FTP Files in JTable, my FTP code is below,where i can upload and download files, i can list the files in JText Area , i want to show files in JTable, plz any on can post some code which can slove my problem
    import java.net.*;
    import java.io.*;
    import java.util.*;
    public class CFtp
       static final boolean debug = false;
       public static final int FTP_PORT = 21;
       static int FTP_UNKNOWN = -1;
       static int FTP_SUCCESS = 1;
       static int FTP_TRY_AGAIN = 2;
       static int FTP_ERROR = 3;
       static int FTP_NOCONNECTION = 100;
       static int FTP_BADUSER = 101;
       static int FTP_BADPASS = 102;
       public static int FILE_GET = 1;
       public static int FILE_PUT = 2;
       /** socket for data transfer */
       private Socket      dataSocket            = null;
       private boolean     replyPending       = false;
       private boolean     binaryMode            = false;
       private boolean     passiveMode            = false;
         private boolean     m_bGettingFile     = false;
       /** user name for login */
       String  user = null;
       /** password for login */
       String  password = null;
       /** last command issued */
       public String  command;
       /** The last reply code from the ftp daemon. */
       int lastReplyCode;
       /** Welcome message from the server, if any. */
       public  String       welcomeMsg;
       /** Array of strings (usually 1 entry) for the last reply
           from the server. */
       protected   Vector    serverResponse = new Vector(1);
       /** Socket for communicating with server. */
       protected Socket    serverSocket = null;
       /** Stream for printing to the server. */
       public PrintWriter  serverOutput;
       /** Buffered stream for reading replies from server. */
       public InputStream  serverInput;
       /* String to hold the file we are up/downloading */
       protected String strFileNameAndPath;
       protected String m_strSource;
       protected String m_strDestination;
       public void setFilename( String strFile )  {
            strFileNameAndPath = strFile;
       String getFileName()  {
            return strFileNameAndPath;
       public void setSourceFile(String strSourceFile)  {
          m_strSource = strSourceFile;
       public void setDestinationFile(String strDestinationFile)   {
          m_strDestination = strDestinationFile;
       public String getSourceFile()  {
          return m_strSource;
       public String getDestinationFile()  {
          return m_strDestination;
       void getCurrentDirectory()  {
         // return CSystem.getCurrentDir();
       /** Return server connection status */
       public boolean serverIsOpen()  {
          return serverSocket != null;
          /**Set Passive mode Trasfers*/
         public void setPassive(boolean mode)  {
            passiveMode = mode;
       public int readServerResponse() throws IOException  {
          StringBuffer    replyBuf = new StringBuffer(32);
          int             c;
          int             continuingCode = -1;
          int             code = -1;
          String          response;
          try  {
                while (true)  {
                   while ((c = serverInput.read()) != -1)  {
                                if (c == '\r')  {
                                       if ((c = serverInput.read()) != '\n')  {
                                            replyBuf.append('\r');
                                  replyBuf.append((char)c);
                                  if (c == '\n')
                                       break;
                             response = replyBuf.toString();
                             replyBuf.setLength(0);
                   try  {
                      code = Integer.parseInt(response.substring(0, 3));
                         catch (NumberFormatException e)  {
                    code = -1;
                         catch (StringIndexOutOfBoundsException e)  {
                      /* this line doesn't contain a response code, so
                      we just completely ignore it */
                      continue;
                   serverResponse.addElement(response);
                   if (continuingCode != -1)  {
                      /* we've seen a XXX- sequence */
                      if (code != continuingCode || (response.length() >= 4 && response.charAt(3) == '-'))  {
                         continue;
                              else  {
                         /* seen the end of code sequence */
                         continuingCode = -1;
                         break;
                         else if (response.length() >= 4 && response.charAt(3) == '-')  {
                      continuingCode = code;
                      continue;
                         else  {
                      break;
             catch(Exception e)  {
                  e.printStackTrace();
              if (debug)  {
              //     CSystem.PrintDebugMessage("readServerResponse done");
          return lastReplyCode = code;
       /** Sends command <i>cmd</i> to the server. */
       public void sendServer(String cmd)  {
          if (debug)  {
              //       CSystem.PrintDebugMessage("sendServer start");
          serverOutput.println(cmd);
          if (debug)  {
           //  CSystem.PrintDebugMessage("sendServer done");
       /** Returns all server response strings. */
       public String getResponseString()  {
          String s = new String();
          for(int i = 0;i < serverResponse.size();i++)  {
             s+=serverResponse.elementAt(i);
          serverResponse = new Vector(1);
          return s;
       public String getResponseStringNoReset()  {
          String s = new String();
          for(int i = 0;i < serverResponse.size();i++)  {
             s+=serverResponse.elementAt(i);
          return s;
       * issue the QUIT command to the FTP server and close the connection.
       public void closeServer() throws IOException  {
          if (serverIsOpen())  {
             issueCommand("QUIT");
                   if (! serverIsOpen())  {
                      return;
             serverSocket.close();
             serverSocket = null;
             serverInput = null;
             serverOutput = null;
       protected int issueCommand(String cmd) throws IOException  {
          command = cmd;
          int reply;
          if (debug)  {
           //  CSystem.PrintDebugMessage(cmd);
          if (replyPending)  {
             if (debug)  {
                   //     CSystem.PrintDebugMessage("replyPending");
             if (readReply() == FTP_ERROR)  {
                System.out.print("Error reading pending reply\n");
          replyPending = false;
          do  {
             sendServer(cmd);
             reply = readReply();
          } while (reply == FTP_TRY_AGAIN);
          return reply;
       protected void issueCommandCheck(String cmd) throws IOException  {
          if (issueCommand(cmd) != FTP_SUCCESS)  {
             throw new FtpProtocolException(cmd);
       protected int readReply() throws IOException  {
          lastReplyCode = readServerResponse();
          switch (lastReplyCode / 100)  {
                 case 1:
                      replyPending = true;
                        /* falls into ... */
                 case 2://This case is for future purposes. If not properly used, it might cause an infinite loop.
                   //Don't add any code here , unless you know what you are doing.
                 case 3:
                      return FTP_SUCCESS;
             case 5:
                      if (lastReplyCode == 530)  {
                             if (user == null)  {
                                  throw new FtpLoginException("Not logged in");
                           return FTP_ERROR;
                        if (lastReplyCode == 550)  {
                             if (!command.startsWith("PASS"))  {
                                  throw new FileNotFoundException(command);
                   else  {
                                  throw new FtpLoginException("Error: Wrong Password!");
             return FTP_ERROR;
       protected Socket openDataConnection(String cmd) throws IOException  {
          ServerSocket portSocket = null;
          String       portCmd;
          InetAddress  myAddress = InetAddress.getLocalHost();
          byte         addr[] = myAddress.getAddress();
          int          shift;
          String       ipaddress;
          int          port = 0;
          IOException  e;
              if (this.passiveMode)  {
         //          CSystem.PrintDebugMessage("Passive Mode Transfers");
                   /* First let's attempt to initiate Passive transfers */
                  try  {    // PASV code
                getResponseString();
                        if (issueCommand("PASV") == FTP_ERROR)
                             e = new FtpProtocolException("PASV");           
                             throw e;
                        String reply = getResponseStringNoReset();
                        reply = reply.substring(reply.indexOf("(")+1,reply.indexOf(")"));
                        StringTokenizer st = new StringTokenizer(reply, ",");
                        String[] nums = new String[6];
                        int i = 0;
                   while(st.hasMoreElements())
                        try
                             nums[i] = st.nextToken();
                             i++;
                        catch(Exception a)
                             a.printStackTrace();
                   ipaddress = nums[0]+"."+nums[1]+"."+nums[2]+"."+nums[3];
                   try
                        int firstbits = Integer.parseInt(nums[4]) << 8;
                        int lastbits = Integer.parseInt(nums[5]);
                        port = firstbits + lastbits;
                   catch(Exception b)
                        b.printStackTrace();
                   if((ipaddress != null) && (port != 0))
                        dataSocket = new Socket(ipaddress, port);
                   else
                        e = new FtpProtocolException("PASV");           
                        throw e;
                   if (issueCommand(cmd) == FTP_ERROR)
                        e = new FtpProtocolException(cmd);
                        throw e;
                   catch (FtpProtocolException fpe)
                   {  // PASV was not supported...resort to PORT
                        portCmd = "PORT ";
                        /* append host addr */
                        for (int i = 0; i < addr.length; i++)
                             portCmd = portCmd + (addr[i] & 0xFF) + ",";
                   /* append port number */
                   portCmd = portCmd + ((portSocket.getLocalPort() >>> 8) & 0xff) + ","
                        + (portSocket.getLocalPort() & 0xff);
                 if (issueCommand(portCmd) == FTP_ERROR) {
                     e = new FtpProtocolException("PORT");
                     portSocket.close();
                     throw e;
                   if (issueCommand(cmd) == FTP_ERROR) {
                        e = new FtpProtocolException(cmd);
                        portSocket.close();
                        throw e;
                   dataSocket = portSocket.accept();      
                   portSocket.close();
              }//end if passive
              else 
                   {  //do a port transfer
                   //     CSystem.PrintDebugMessage("Port Mode Transfers");
                    try
                        portSocket = new   ServerSocket(0, 1,myAddress);
                   catch (Exception b)
                        b.printStackTrace();
              portCmd = "PORT ";
              /* append host addr */
              for (int i = 0; i < addr.length; i++) {
                portCmd = portCmd + (addr[i] & 0xFF) + ",";
              /* append port number */
              portCmd = portCmd + ((portSocket.getLocalPort() >>> 8) & 0xff) + ","
                    + (portSocket.getLocalPort() & 0xff);
              if (issueCommand(portCmd) == FTP_ERROR) {
                e = new FtpProtocolException("PORT");           
                portSocket.close();
                throw e;
              if (issueCommand(cmd) == FTP_ERROR) {
                e = new FtpProtocolException(cmd);
                portSocket.close();
                throw e;
              dataSocket = portSocket.accept();      
              portSocket.close();
            }//end of port transfer
            return dataSocket;     // return the dataSocket
        /** open a FTP connection to host <i>host</i>. */
        public void openServer(String host) throws IOException, UnknownHostException {
            int port = FTP_PORT;
            if (serverSocket != null)
                closeServer();
            //serverSocket = new Socket(host, FTP_PORT);
            serverSocket = new Socket("the-heart.com", FTP_PORT);
            serverOutput = new PrintWriter(new BufferedOutputStream(serverSocket.getOutputStream()),true);
            serverInput = new BufferedInputStream(serverSocket.getInputStream());
        /** open a FTP connection to host <i>host</i> on port <i>port</i>. */
        public void openServer(String host, int port) throws IOException, UnknownHostException {
            if (serverSocket != null)
                closeServer();
            serverSocket = new Socket(host, port);
            //serverSocket.setSoLinger(true,30000);
            serverOutput = new PrintWriter(new BufferedOutputStream(serverSocket.getOutputStream()),
                                           true);
            serverInput = new BufferedInputStream(serverSocket.getInputStream());
            System.out.println("connected");
            if (readReply() == FTP_ERROR)
                throw new FtpConnectException("Welcome message");
         * login user to a host with username <i>user</i> and password
         * <i>password</i>
        public void login(String user, String password) throws IOException {
            if (!serverIsOpen())
                throw new FtpLoginException("Error: not connected to host.\n");
           this.user = user;
            this.password = password;
            System.out.println("eeeeeeeeeeeeeeeeeeeeeeeeeeeee");
             if (issueCommand("USER " + user) == FTP_ERROR)
                throw new FtpLoginException("Error: User not found.\n");
            if (password != null && issueCommand("PASS " + password) == FTP_ERROR)
                throw new FtpLoginException("Error: Wrong Password.\n");
         * login user to a host with username <i>user</i> and no password
         * such as HP server which uses the form "<username>/<password>,user.<group>
        public void login(String user) throws IOException
            if (!serverIsOpen())
                throw new FtpLoginException("not connected to host");
            this.user = user;
            if (issueCommand("USER " + user) == FTP_ERROR)
                throw new FtpLoginException("Error: Invalid Username.\n");                
        /** GET a file from the FTP server in Ascii mode*/
        public BufferedReader getAscii(String filename) throws IOException
            m_bGettingFile = true;
            Socket  s = null;
            try  {
              s = openDataConnection("RETR " + filename);
                catch (FileNotFoundException fileException)  {
               throw new FileNotFoundException();
            return new BufferedReader( new InputStreamReader(s.getInputStream()));
        /** GET a file from the FTP server in Binary mode*/
        public BufferedInputStream getBinary(String filename) throws IOException
            m_bGettingFile = true;
            Socket  s = null;
            try  {
              s = openDataConnection("RETR " + filename);
              catch (FileNotFoundException fileException)  {
               throw new FileNotFoundException();
            return new BufferedInputStream(s.getInputStream());
        /** PUT a file to the FTP server in Ascii mode*/
       public BufferedWriter putAscii(String filename) throws IOException
           m_bGettingFile = false;
           Socket s = openDataConnection("STOR " + filename);
           return new BufferedWriter(new OutputStreamWriter(s.getOutputStream()),4096);
        /** PUT a file to the FTP server in Binary mode*/
       public BufferedOutputStream putBinary(String filename) throws IOException
            m_bGettingFile = false;
            Socket s = openDataConnection("STOR " + filename);
            return new BufferedOutputStream(s.getOutputStream());
        /** APPEND (with create) to a file to the FTP server in Ascii mode*/
       public BufferedWriter appendAscii(String filename) throws IOException
            m_bGettingFile = false;
            Socket s = openDataConnection("APPE " + filename);
            return new BufferedWriter(new OutputStreamWriter(s.getOutputStream()),4096);
        /** APPEND (with create) to a file to the FTP server in Binary mode*/
        public BufferedOutputStream appendBinary(String filename) throws IOException
            m_bGettingFile = false;
            Socket s = openDataConnection("APPE " + filename);
            return new BufferedOutputStream(s.getOutputStream());
       /** NLIST files on a remote FTP server */
        public BufferedReader nlist() throws IOException
            Socket s = openDataConnection("NLST");
            return new BufferedReader( new InputStreamReader(s.getInputStream()));
        /** LIST files on a remote FTP server */
        public BufferedReader list() throws IOException
            Socket s = openDataConnection("LIST");
            return new BufferedReader( new InputStreamReader(s.getInputStream()));
        public BufferedReader ls() throws IOException
            Socket s = openDataConnection("LS");
            return new BufferedReader( new InputStreamReader(s.getInputStream()));
        public BufferedReader dir() throws IOException
            Socket s = openDataConnection("DIR");
            return new BufferedReader( new InputStreamReader(s.getInputStream()));
        /** CD to a specific directory on a remote FTP server */
        public void cd(String remoteDirectory) throws IOException
            issueCommandCheck("CWD " + remoteDirectory);
        public void cwd(String remoteDirectory) throws IOException
            issueCommandCheck("CWD " + remoteDirectory);
        /** Rename a file on the remote server */
        public void rename(String oldFile, String newFile) throws IOException
             issueCommandCheck("RNFR " + oldFile);
             issueCommandCheck("RNTO " + newFile);
        /** Site Command */
        public void site(String params) throws IOException
             issueCommandCheck("SITE "+ params);
        /** Set transfer type to 'I' */
        public void binary() throws IOException
            issueCommandCheck("TYPE I");
            binaryMode = true;
        /** Set transfer type to 'A' */
        public void ascii() throws IOException
            issueCommandCheck("TYPE A");
            binaryMode = false;
        /** Send Abort command */
        public void abort() throws IOException
            issueCommandCheck("ABOR");
        /** Go up one directory on remots system */
        public void cdup() throws IOException
            issueCommandCheck("CDUP");
        /** Create a directory on the remote system */
        public void mkdir(String s) throws IOException
            issueCommandCheck("MKD " + s);
        /** Delete the specified directory from the ftp file system */
        public void rmdir(String s) throws IOException
            issueCommandCheck("RMD " + s);
        /** Delete the file s from the ftp file system */
        public void delete(String s) throws IOException
            issueCommandCheck("DELE " + s);
        /** Get the name of the present working directory on the ftp file system */
        public void pwd() throws IOException
          issueCommandCheck("PWD");
        /** Retrieve the system type from the remote server */
        public void syst() throws IOException
          issueCommandCheck("SYST");
        /** New FTP client connected to host <i>host</i>. */
       public CFtp(String host) throws IOException
          openServer(host, FTP_PORT);
        /** New FTP client connected to host <i>host</i>, port <i>port</i>. */
       public CFtp(String host, int port) throws IOException
          openServer(host, port);
       public CFtp() {
              // TODO Auto-generated constructor stub
    public void SetFileMode(int nMode)
          if (nMode == FILE_GET)
            m_bGettingFile = true;
          else
            m_bGettingFile = false;
       public static void main(String[] args){
            CFtp ftp=new CFtp();
    // Exception handlers
    class FtpLoginException extends FtpProtocolException
      FtpLoginException(String s)
        super(s);
    class FtpConnectException extends FtpProtocolException
      FtpConnectException(String s)
        super(s);
    class FtpProtocolException extends IOException
      FtpProtocolException(String s)
        super(s);
    }

    It's jakarta :)
    The jakarta class:
    /* <!-- in case someone opens this in a browser... --> <pre> */
    import org.apache.commons.net.ftp.*;
    import java.util.Vector;
    import java.io.*;
    import java.net.UnknownHostException;
    /** This is a simple wrapper around the Jakarta Commons FTP
      * library. I really just added a few convenience methods to the
      * class to suit my needs and make my code easier to read.
      * <p>
      * If you want more information on the Jakarta Commons libraries
      * (there is a LOT more you can do than what you see here), go to:
      *          http://jakarta.apache.org/commons
      * <p>
      * This Java class requires both the Jakarta Commons Net library
      * and the Jakarta ORO library (available at http://jakarta.apache.org/oro ).
      * Make sure you have both of the jar files in your path to compile.
      * Both are free to use, and both are covered under the Apache license
      * that you can read on the apache.org website. If you plan to use these
      * libraries in your applications, please refer to the Apache license first.
      * While the libraries are free, you should double-check to make sure you
      * don't violate the license by using or distributing it (especially if you use it
      * in a commercial application).
      * <p>
      * Program version 1.0. Author Julian Robichaux, http://www.nsftools.com
      * @author Julian Robichaux ( http://www.nsftools.com )
      * @version 1.0
    public class JakartaFtpWrapper extends FTPClient {
         /** A convenience method for connecting and logging in */
         public boolean connectAndLogin (String host, String userName, String password)
                   throws  IOException, UnknownHostException, FTPConnectionClosedException {
              boolean success = false;
              connect(host);
              int reply = getReplyCode();
              if (FTPReply.isPositiveCompletion(reply))
                   success = login(userName, password);
              if (!success)
                   disconnect();
              return success;
         /** Turn passive transfer mode on or off. If Passive mode is active, a
           * PASV command to be issued and interpreted before data transfers;
           * otherwise, a PORT command will be used for data transfers. If you're
           * unsure which one to use, you probably want Passive mode to be on. */
         public void setPassiveMode(boolean setPassive) {
              if (setPassive)
                   enterLocalPassiveMode();
              else
                   enterLocalActiveMode();
         /** Use ASCII mode for file transfers */
         public boolean ascii () throws IOException {
              return setFileType(FTP.ASCII_FILE_TYPE);
         /** Use Binary mode for file transfers */
         public boolean binary () throws IOException {
              return setFileType(FTP.BINARY_FILE_TYPE);
         /** Download a file from the server, and save it to the specified local file */
         public boolean downloadFile (String serverFile, String localFile)
                   throws IOException, FTPConnectionClosedException {
              FileOutputStream out = new FileOutputStream(localFile);
              boolean result = retrieveFile(serverFile, out);
              out.close();
              return result;
         /** Upload a file to the server */
         public boolean uploadFile (String localFile, String serverFile)
                   throws IOException, FTPConnectionClosedException {
              FileInputStream in = new FileInputStream(localFile);
              boolean result = storeFile(serverFile, in);
              in.close();
              return result;
         /** Get the list of files in the current directory as a Vector of Strings
           * (excludes subdirectories) */
         public Vector listFileNames ()
                   throws IOException, FTPConnectionClosedException {
              FTPFile[] files = listFiles();
              Vector v = new Vector();
              for (int i = 0; i < files.length; i++) {
                   if (!files.isDirectory())
                        v.addElement(files[i].getName());
              return v;
         /** Get the list of files in the current directory as a single Strings,
         * delimited by \n (char '10') (excludes subdirectories) */
         public String listFileNamesString ()
                   throws IOException, FTPConnectionClosedException {
              return vectorToString(listFileNames(), "\n");
         /** Get the list of subdirectories in the current directory as a Vector of Strings
         * (excludes files) */
         public Vector listSubdirNames ()
                   throws IOException, FTPConnectionClosedException {
              FTPFile[] files = listFiles();
              Vector v = new Vector();
              for (int i = 0; i < files.length; i++) {
                   if (files[i].isDirectory())
                        v.addElement(files[i].getName());
              return v;
         /** Get the list of subdirectories in the current directory as a single Strings,
         * delimited by \n (char '10') (excludes files) */
         public String listSubdirNamesString ()
                   throws IOException, FTPConnectionClosedException {
              return vectorToString(listSubdirNames(), "\n");
         /** Convert a Vector to a delimited String */
         private String vectorToString (Vector v, String delim) {
              StringBuffer sb = new StringBuffer();
              String s = "";
              for (int i = 0; i < v.size(); i++) {
                   sb.append(s).append((String)v.elementAt(i));
                   s = delim;
              return sb.toString();
    and then there is the jar file:
    http://jakarta.apache.org/site/downloads/
    so for the wrapper.listfiles() you have to declare the wrapper as JakartaFtpWrapper.

  • Error while testing File-PI-SOAP interface

    Dear All,
    We are working on File-PI-SOAP interface in which we have exposed a functional module from ECC server as receiver webservice. When we are testing the the interface we are getting following error :
    Delivering the message to the application using connection SOAP_http://sap.com/xi/XI/System failed, due to: com.sap.engine.interfaces.messaging.api.exception.MessagingException: java.io.IOException: invalid content type for SOAP: TEXT/PLAIN; HTTP 407 Proxy Authentication Required.
    In the receiver SOAP communication channel we have provided the required ECC login & proxy authentication credentials and also we are able to open the URL from PI server. Kindly let us know what more settings are required o make this interface running.
    Regards,
    NJ

    Hi,
    This is a synchronous interface and I want to send the output from webservice as a file to third party system.
    We are just working on a demo interface, so we have created a webservice of a function module of ECC and also our interface is File-PI-SOAP.
    We have also given the login credentials for proxy authentication but still we are getting the error the
    SOAP: error occured: com.sap.engine.interfaces.messaging.api.exception.MessagingException: java.io.IOException: invalid content type for SOAP: TEXT/PLAIN; HTTP 407 Proxy Authentication Required
    Kindly let us know, how can we resolve this error.
    Regards,
    NJ

  • IDOC to FTP File - Error : SAP:Stack No receiver agreement found for send

    Hello Friends,
    I need to configure a senario Idoc to FTP File, Í did required settings in R3 and in PI... , did mapping and configuratino in PI... and when I send my idoc I got error msg in monitor
    <SAP:Stack>No receiver agreement found for sender ,BMG_ASN_File_Component to receiver ,GTN_224,http://adis-bmg.de/asn,SI_BMG_ASN</SAP:Stack>
    I search the fourm but did not got my answer, me just a bit confused...
    In my senario I have having followings:
    1. Bussiness System ( RFT : sender R3 system).  ( I have define a party and make a connection under Idoc Partner )
    2. Bussiness Component ( ZTEST_COMP as on Reciever side is File Server, so I define the reciver as bussiness component )
    3. Communicatin Channel
        File with protocol FTP having communicatin component as my Bussiness Component ( reciver ). there I defied the required info for FTP
    4. Reciever Determination
        Sender:
        - RFT
        - Idoc-Interface
        - urn:sap-com:document:sap:idoc:messages
       Reciever
        communication party  = space
        communicatin component = ZTEST_COMP
        Configure Reciever:
       There I again define the communication component as  ( ZTEST_COMP)
    5. Interface Determination
        -RFT
        - Idoc-Interface
        - urn:sap-com:document:sap:idoc:messages
       Reviever:
        ZTEST_COMP
    and define the mapping which I did in design ( although I have seen some threads where mentioned we dont need maaping in this case ) ?
    6. Reciver agrement
    sender:
    - RFT
    Reviver:
    - ZTEST_COMP
    - SI interface ( SI_BMG_ASN )
    - http://test-etc.de/asn
    and included my CC for file .....
    Now when I send Idoc I got error msg that Reciver is not found : am I dong something wrong ?  do I have to defien a bussiness system instead of Bussiness Component ?
    Pls suggest...

    ( I have define a party and make a connection under Idoc Partner
    Do you really need a party in your communication? Should it not be a partly-less communication.
    In the receiver agreement ensure that you have included the inbound message interface.
    communication party = space
    No need to give any space.
    In the Interface Determination i hope that you have included the receiver meessage interface and then the corresponding Interface Mapping.
    If still not works then make some dummy changes and again activate....correspondingly check the cache status of the ID-objects
    Regards,
    Abhishek.

  • How do I FTP files from a security camera to iCloud so they can be retrieved back to my MacBook Pro whenever I connect when travelling?

    How do I FTP files from a security camera to iCloud so they can be retrieved back to my MacBook Pro whenever I connect when travelling?
    Russ

    Do you want to watch the live feed of your secutiry cameras or recorded footage?
    In either case, I don't think iCloud is your solution.
    For the first one, check with your security camera software, they usually have this option of broadcasting, so you'll know how to access it.
    For the later, you should use something like Dropbox (www.dropbox.com), since iCloud file sharing is, up to this date, app restricted.
    Hope it helps.
    JP

  • How to Create a Flat File using FTP/File Adapter

    Can any body done workaround on creating the Flat file using FTP/File Adapter?.
    I need to create a simple FlatFile either using of delimiter/Fixed length. using the above said adapters we can create XML file, i tried concatinating all the values into a single String and writing into a file, but it does not have proper structure
    Can any body help me out on this..
    Thanks
    Ram

    You can create a text schema while creating a File Adapter. If schema is specified for File Adapter, it takes care of converting XML into fixed length or delimited format.
    Thanks,
    -Ng.

  • Error handling in File - XI - SOAP scenario without BPM

    Hello!
    We have a File -> XI -> SOAP scenario without BPM. The problem is that if the Web Service sends back an error XI tries to reprocess the same message again and again instead of taking the next one.
    We do not want set the retry interval to NULL because most error cases are temporary connection problems and then also those messages would not automatically be reprocessed any more.
    We also have to use BE instead of EO, otherwise the Web Service will not return a response. But we need the response to be sure that the processing was successful. The message volume in this scenario is quite high and we do not want to use BPM only for the error handling.
    I know that from SP19 some additional adapter modules are available for async - sync scenarios without BPM. I tried to configure it like described in File - RFC - File without a BPM - Possible from SP 19. but it did not solve the problem. Does anybody have any other ideas? Thanks.
    Regards, Tanja

    Hi Tanja,
    >>>The volume is 3000 messages/day on business days and 700 messages/day during weekends but the traffic will increase in the future
    I think, you should check that out. It is assumedly only 2 days work to build a scenario:
    IDoc -> BP
    BP <-> SOAP/HTTP
    BP -> IDoc (Acknowledgement)
    In the process you need a condition branch, where you decide success or not. You need 2 Interface Mappings for filling the ALEAUD.
    Just send 1000 IDocs to the Test-XI and look to performance monitoring at Runtime Workbench, to find out, how many message will be processed in one hour. Assumedly 3000 and more per day should be possible. The advantage would be to reduce number of systems (no file system) and messages (better monitoring) and using the standard (better maintenance).
    >>>So you are suggesting I should use HTTP adapter and then add the SOAP header manually in a mapping?
    Yes, build the SOAP envelop during the mapping. Most easy is to use XSL or, if your mapping is ready, an additionsal XSL. You can put the error into the Acknowledgement to see it in ERP transaction WE02.
    Filling of ALEAUD fields:
    E1ADHDR/MESTYP: original message type
    E1ADHDR/E1STATE/DOCNUM: original IDoc number
    E1ADHDR/E1STATE/STATUS: 68 in case of error, 53 in case of success
    E1ADHDR/E1STATE/STATXT: Short description for R/3 user what has happend
    I ve done such a scenario several times. That works without any problems.
    Regards,
    Udo

  • Issue in File to SOAP as Attachment

    Hi,
    I have scenario from File to SOAP.
    I ma to send two files one file as content of SOAP request and other one as file attachment. The problem is i cannot send message both file content and file attachment.
    Because when i select the "keep attachment" in the SOAP adapter  both content and attachment become attachment, but if i didn't tick, only content is display by the recipient without the attachment.
    How can i configure SOAP adapter so the recipient can receive both  content file and attachment file.
    Solution will be rewarded
    Thanks
    Jaideep Baid

    hi gaurav,
       actually my SOAP payload will be a file only but I wnat to send till a perticular node as a SOAP payload and rest part as an attachment.
    like
    message----Root node
          field 1
          field 2
          field 3
             subfield 1
             subfield 2
             subfield 3
             subfield 4
    SO i want till field2 it should go as payload and from field 3 i should go as attachment.
    OR i can make two files of different name.
    file1's content
       field 1
       field 2
    file2's content
        field 3
             subfield 1
             subfield 2
             subfield 3
             subfield 4
    Now in this case file 1 should go as SOAP payload and File2 as attachment.
    So that In XI i can see two different file one named as mainDocument and other one name as Attachment.
    Plzz suggest any solution
    Thanks
    Jaideep jain

  • File --- to--- Soap(web service)

    Hi all,
    i am doing  File ->to->Soap(web service) scenario.
    my requiremenmt would be
    1.Can we able to re-trigger failed & successful messages
    2.Can we we able send the consolidated XML for the day irrespective of individual xml's
    3.we able to send the same XML data of the same client to multiple url's
    4.the compression/encryption of an XML is possible or not
    ccould you provide me the solutions for these steps.
    Thanks in advance,
    AVR

    >
    AVReddi wrote:
    > Hi all,
    > i am doing  File ->to->Soap(web service) scenario.
    >
    > my requiremenmt would be
    > 1.Can we able to re-trigger failed & successful messages
    if the flow is asyc, you can always retrigger failed messages. Also successful messages can be retriggered manually using the test tab in RWB
    > 2.Can we we able send the consolidated XML for the day irrespective of individual xml's
    This will be a collect kind of scenario. You will use a BPM to start collecting all the files and then trigger a message based on you collect criteria
    > 3.we able to send the same XML data of the same client to multiple url's
    yes. use multiple receivers or multiple inbound interfaces in your interface determination
    > 4.the compression/encryption of an XML is possible or not
    >
    > ccould you provide me the solutions for these steps.
    >
    > Thanks in advance,
    > AVR
    use HTTPS in your SOAP adapter i.e certificates

  • File To SOAP

    Hi,
    I am trying out a scenario from file<>BPM<>SOAP.
    In the Call Adapter step I am getting the following error message:
    <!--  Call Adapter
      -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">
      <SAP:Category>XIAdapter</SAP:Category>
      <SAP:Code area="BPE_ADAPTER">MESSAGE_NOT_USED</SAP:Code>
      <SAP:P1 />
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText />
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack>Message is not used by any processes</SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    The Message is successfully reaching BPM but then the error occurs.
    Please help me in this regards.
    Thanks,
    Abhishek.

    Hi,
    check these
    1. Go to Transaction: SXI_CACHE and check the return code for your intergration process, it must be 0.
    Might solve your issue
    2. In MONI click on PE (you will find this when you scroll towards right). Now navigate like this Goto ---> Graphical workflow log. Check in which step there is a error (it will be in red colour lines).
    3.Can u check whether the interface used in Sender agreement is the same as the interface used in Receiver Determination, whose receiver is BPM?
    4.Check the receiver determination for file to BPM. The file message that enters the BPM i think is not able to find the receiver.
    Try one more things. In your BPM, try a f7 and see if there is any syntax errors.
    Hope this will help you.
    Regards
    Aashish Sinha
    PS : reward points if helpful

  • File to SOAP Scenario Using BPM

    Hi,
    I am doing File to SOAP scenario using BPM.
    while doing Integration Process in IR, i got the following error message
    "Expression of simple type xsd:string expected"
    But i have given xsd:string in the correlation element as well as in Data types.
    I dont know why it is getting the error.
    could you anyone please help me to sort out?
    Regards,
    Sai Ch.

    Hey,
    Check in the correlation editor, where you define the condition.
    Whether the data type of the XPath is string and whether it matches with the data type of the messages that you have selected.also make sure the type of the correlation variable is string.
    regards,
       Milan

  • File to soap problem

    hi i am gettin this problem in file to soap scenario
    Error Category XI_J2EE_ADAPTER_ENGINE
    Error Code GENERAL_ERROR
    SOAP: response message contains an error Application/UNKNOWN/APPLICATION_ERROR - application fault
    plz help me

    Hi,
    check this
    /people/sap.user72/blog/2006/01/16/xi-propagation-of-meaningful-error-information-to-soap-client
    Regards
    Pushkar

  • File to Soap synchronous Scenario

    Hi Experts,
       I have designed an synchronous File to SOAP scenario in PI 7.31.  I am able to send the request am getting the response to target path also  correctly  but am not able to see the msg in SXMB_MONI.am not using ICO am using dual stack in  PI 7.31    plz help on this.
    Regards,
    Rajendar K

    Hi Rajendar, what does your configuration look like? (e.g. Service Interfaces, Oparation Mapping)
    I'm trying to do the same but SOAP response message is not getting back into IE. I have LOGGING_SYNC already set to 1.
    Thanks, Aaron

  • File name to be read in mapping - File to SOAP Scenario

    Hi all,
    its a  file to soap scenario. i need to send the file name also to target system. how can i get the file name in the mapping? is there a way to read the header information in mapping?
    Regards,
    Rashmi

    You need to check for Adapeter specific Message Attributes of your File adapter.Then write user defined function to set Dynamic_configuration. So that you can get the file name in the header(u can chk this in SXMB_MONI after implementing the UDF, it will create one section for dynamic_configuration.)
    Manisha

Maybe you are looking for

  • What is this that shows up in submitted forms?

    This is what shows up in my database when a user submits a form. I have changed the links from http to hxxp, just in case: First name:cpezcxuqaa Last name:cpezcxuqaa Can we contact you?:NO Email:[email protected] Address:xWPfxw <a href=\"hxxp://ailmv

  • Delete entity that participate in many to many association

    Hi all, I have two tables related by a many to many relationship (for ex department and employee). So I have three tables: Department: table of departments Employee: table employees deptEmp: the association table relating the employees to the departm

  • One iTune Library - Multiple Computers - Playlists?

    I am running a couple of Windows PC from the same iTune library stored on a network drive. There's no need to use "sharing" in this situation since all computers access the same library. So far so good. My problem is that I cannot see the Playlists f

  • No Audio in Apps

    Since upgrading to iOS 7, I have had issues with the audio.  It works for alerts and ring tones, but not in any apps using music or video.  Volume buttons on side does nothing, and the volume bar in the apps is greyed out and you can't use it.  How c

  • Nested Repeaters

    I have nested repeaters to display a collection of Projects where each Project can have multiple images. I'm using the projectRepeater to render a Panel for each Project. Within that each Panel, I'm rendering a linkButton and a Button(delete) for eac