Automic Workload Automation

  • 1.  Error getting last modified time stamp of remote file using MDTM FTP command (RA FTP v3.1.5)

    Posted Sep 27, 2017 01:01 PM
    I'm trying to get the last modified time stamp of a file on the remote FTPS server by running MDTM command in a RA FTP job, like this:

    6qjsv7kprues.pnghttps://us.v-cdn.net/5019921/uploads/editor/0i/6qjsv7kprues.png" width="1102">

    RA FTP solution seems to be able to retrieve Last Mod Time and to display it in Host A browser window (circled in red above), but I cannot get MDTM command to work in the Free Form Command. The job report shows the following error:

    2017-09-27 12:31:25            Setting Remote Server Verification Off.
    2017-09-27 12:31:25            connecting on port : 990
    2017-09-27 12:31:26            Executing command: mdtm ./****REPLICATION.zip on CONN.FTP.ITX
    java.lang.Integer cannot be cast to java.lang.String
    com.uc4.ftpjob.DataTransferException: Error skipping file bytes.
        at com.uc4.ftpjob.commands.FtpFacadeCommandImpl.throwDataException(FtpFacadeCommandImpl.java:57)
        at com.uc4.ftpjob.commands.FtpFacadeCommandImpl.sendCommand(FtpFacadeCommandImpl.java:95)
        at com.uc4.ftpjob.commands.impl.FreeFormFTPCommand.execute1(FreeFormFTPCommand.java:246)
        at com.uc4.ftpjob.commands.impl.FreeFormFTPCommand.execute(FreeFormFTPCommand.java:39)
        at com.uc4.ftpjob.commands.CommandProcessor.execCommand(CommandProcessor.java:257)
        at com.uc4.ftpjob.commands.CommandProcessor.processCommands(CommandProcessor.java:162)
        at com.uc4.ftpjob.commands.CommandProcessor$processCommands.call(Unknown Source)
        at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:40)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120)
        at FtpJob.runJob(FtpAgent.groovy:304)
        at com.uc4.extensibility.types.CITAgent.dispatchJob(CITAgent.java:258)
        at com.uc4.ex.cit.CITJob.execute(CITJob.java:185)
        at com.uc4.ex.Job.run(Job.java:469)
        at com.uc4.ex.ThreadPool$RunnableDecorator.run(ThreadPool.java:53)
        at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
        at java.util.concurrent.FutureTask.run(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
        at java.lang.Thread.run(Unknown Source)
    Caused by: java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String
        at com.uc4.ftpjob.commands.FtpsCommandImpl.sendCommand(FtpsCommandImpl.java:253)
        at com.uc4.ftpjob.commands.FtpFacadeCommandImpl.sendCommand(FtpFacadeCommandImpl.java:93)
        ... 18 more

    I ran MDTM command in WinSCP and it executes just fine:

    yo32ax35o4q3.pnghttps://us.v-cdn.net/5019921/uploads/editor/3g/yo32ax35o4q3.png" width="599">

    Has anyone experienced anything like this? How can I get the last modified time stamp of a remote file?
    We are using RA FTP v3.1.5 with AWA 10.0.3


  • 2.  Error getting last modified time stamp of remote file using MDTM FTP command (RA FTP v3.1.5)

    Posted Sep 28, 2017 11:13 PM
    Hi LeonardOlteanu ,

    The free form command within our FTP agent does not support all "native" FTP commands. I'm quite sure that MDTM might be one of them. I can try this out and let you know afterwards. If this is not included that'll be a nice enhancement for a future release of the FTp agent.

    Cheers,
    Alexander


  • 3.  Error getting last modified time stamp of remote file using MDTM FTP command (RA FTP v3.1.5)

    Posted Sep 29, 2017 09:46 AM
    Thank you Alexander_Trenker_120! It's surprising that this feature is not available. I will surely like to see it in a future version of RA FTP!
    Until then, it looks like I will have to convert a Windows agent into an FTP agent using scripting and 3rd party tools like WinSCP  :/


  • 4.  Error getting last modified time stamp of remote file using MDTM FTP command (RA FTP v3.1.5)

    Posted Sep 29, 2017 01:37 PM
    I just executed the mdtm command with our FTP agent FtpAgent 4.0.2+build.44 and it works.

    dur97mnrk0tm.pnghttps://us.v-cdn.net/5019921/uploads/editor/b7/dur97mnrk0tm.png" width="538">

    zumrydhb8ja7.pnghttps://us.v-cdn.net/5019921/uploads/editor/56/zumrydhb8ja7.png" width="757">



  • 5.  Error getting last modified time stamp of remote file using MDTM FTP command (RA FTP v3.1.5)

    Posted Sep 29, 2017 02:08 PM
    That's great! One more reason we should upgrade our system to the latest version  :)
    Thank you!


  • 6.  Error getting last modified time stamp of remote file using MDTM FTP command (RA FTP v3.1.5)

    Posted Oct 29, 2017 02:23 PM
    What version of java are you running?


  • 7.  Error getting last modified time stamp of remote file using MDTM FTP command (RA FTP v3.1.5)

    Posted Oct 29, 2017 02:34 PM
    It's not the latest version of Java 8:

    20171029/100006.029 - U02000090 Java Runtime Environment version: '1.8.0_101'
    20171029/100006.029 - U02000091 Java Runtime Environment vendor: 'Oracle Corporation'