I think, if the copying process is executed on same machine (Source and Destination machine are same), then in this case, no network involvement is required.
But in this case, STAF Framework is also taking more time as compared to DOS command. If no network involvement is required for completing the request, then it should not be used for completing the request. Please check, whether the STAF framework service execution can be optimized according to the above mentioned process. With Regards, Mohammad Shahid Jamal Sharon Lucas wrote: ------------------ > > Message: 1 > Date: Wed, 29 Jul 2009 17:17:03 -0500 > From: Sharon Lucas <luc...@us.ibm.com> > Subject: Re: [staf-users] fs copy directory performance > To: Daria Holden <dariahol...@gmail.com> > Cc: staf-users@lists.sourceforge.net > Message-ID: > <OF949898DC.CFEA4485-ON86257602.0076BE4D- > 86257602.007a7...@us.ibm.com> > Content-Type: text/plain; charset="us-ascii" > > Daria, > > Most operating system's copy commands (e.g. via Windows Explorer or a copy > or xcopy command) only let you copy a file/directory to the same machine, > not to a remote machine, unless you are using network drives, such as a > mapped drive on Windows. Then it can copy to or from the network drive > that you have access to on the machine. Also, note that these operating > system copy commands are tuned specifically for that one operating system. > > The main purpose of the STAF FS COPY requests is to provide a common way > to copy files/directories from one machine to another, no matter what > operating system (Windows or Unix) that you're copying files to or from. > The speed of the copy depends on your network's TCP/IP connections when > copying to a remote machine and so it will generally be slower than a > local copy performed by an operating system's copy command. > > You said you used Windows Explorer to copy a directory to a remote > machine? Do you mean you copied the directory to and from a mapped drive > named D:? e.g. Is D: a mapped drive or a local drive? > > What is the exact STAF FS COPY request that you submitted? > > Are you copying a directory from and to the same machine and are you > submitting the STAF FS COPY request from this same machine? > > Did you specify the TOMACHINE option in your STAF FS COPY request? Note > that the TOMACHINE specifies the machine to copy the directory and its > contents to. This defaults to the machine which originated the request. > Specifying "local" indicates to copy the directory to the same machine > that the directory is being copied from. Note that specifying "local" > instead of the from machine's host name can significantly improve > performance, especially if your TCP network performance is slow. This is > because "local" indicates to use the local IPC network interface whereas > specifying a TCP host name or IP address indicates to use the TCP network > interface. (This is documented in the STAF User's Guide.) > > I hope this helps explain some of the performance differences you are > seeing. > > Also note that you can use the STAF PROCESS START request to run a Windows > operating system's copy command like xcopy if you are copying a directory > from one location to another on the same machine (instead of a STAF FS > COPY request) if its performance is faster. For example: > > STAF machine PROCESS START COMMAND "xcopy" PARMS "c:\mydir1 c:\mydir2 > /s/e/i/c/v/y" RETURNSTDOUT STDERRTOSTDOUT SAMECONSOLE WAIT > > -------------------------------------------------------------- > Sharon Lucas > IBM Austin, luc...@us.ibm.com > (512) 286-7313 or Tieline 363-7313 > -----Original Message----- > From: staf-users-requ...@lists.sourceforge.net [mailto:staf-users- > requ...@lists.sourceforge.net] > Sent: Thursday, July 30, 2009 8:07 AM > To: staf-users@lists.sourceforge.net > Subject: staf-users Digest, Vol 38, Issue 57 > > Send staf-users mailing list submissions to > staf-users@lists.sourceforge.net > > To subscribe or unsubscribe via the World Wide Web, visit > https://lists.sourceforge.net/lists/listinfo/staf-users > or, via email, send a message with subject or body 'help' to > staf-users-requ...@lists.sourceforge.net > > You can reach the person managing the list at > staf-users-ow...@lists.sourceforge.net > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of staf-users digest..." > > > Today's Topics: > > 1. Re: fs copy directory performance (Sharon Lucas) > 2. Re: fs copy directory performance (Daria Holden) > 3. Re: The Urgent Issues for STAFProc core (Li Wiston) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Wed, 29 Jul 2009 17:17:03 -0500 > From: Sharon Lucas <luc...@us.ibm.com> > Subject: Re: [staf-users] fs copy directory performance > To: Daria Holden <dariahol...@gmail.com> > Cc: staf-users@lists.sourceforge.net > Message-ID: > <OF949898DC.CFEA4485-ON86257602.0076BE4D- > 86257602.007a7...@us.ibm.com> > Content-Type: text/plain; charset="us-ascii" > > Daria, > > Most operating system's copy commands (e.g. via Windows Explorer or a copy > or xcopy command) only let you copy a file/directory to the same machine, > not to a remote machine, unless you are using network drives, such as a > mapped drive on Windows. Then it can copy to or from the network drive > that you have access to on the machine. Also, note that these operating > system copy commands are tuned specifically for that one operating system. > > The main purpose of the STAF FS COPY requests is to provide a common way > to copy files/directories from one machine to another, no matter what > operating system (Windows or Unix) that you're copying files to or from. > The speed of the copy depends on your network's TCP/IP connections when > copying to a remote machine and so it will generally be slower than a > local copy performed by an operating system's copy command. > > You said you used Windows Explorer to copy a directory to a remote > machine? Do you mean you copied the directory to and from a mapped drive > named D:? e.g. Is D: a mapped drive or a local drive? > > What is the exact STAF FS COPY request that you submitted? > > Are you copying a directory from and to the same machine and are you > submitting the STAF FS COPY request from this same machine? > > Did you specify the TOMACHINE option in your STAF FS COPY request? Note > that the TOMACHINE specifies the machine to copy the directory and its > contents to. This defaults to the machine which originated the request. > Specifying "local" indicates to copy the directory to the same machine > that the directory is being copied from. Note that specifying "local" > instead of the from machine's host name can significantly improve > performance, especially if your TCP network performance is slow. This is > because "local" indicates to use the local IPC network interface whereas > specifying a TCP host name or IP address indicates to use the TCP network > interface. (This is documented in the STAF User's Guide.) > > I hope this helps explain some of the performance differences you are > seeing. > > Also note that you can use the STAF PROCESS START request to run a Windows > operating system's copy command like xcopy if you are copying a directory > from one location to another on the same machine (instead of a STAF FS > COPY request) if its performance is faster. For example: > > STAF machine PROCESS START COMMAND "xcopy" PARMS "c:\mydir1 c:\mydir2 > /s/e/i/c/v/y" RETURNSTDOUT STDERRTOSTDOUT SAMECONSOLE WAIT > > -------------------------------------------------------------- > Sharon Lucas > IBM Austin, luc...@us.ibm.com > (512) 286-7313 or Tieline 363-7313 > > > > > Daria Holden <dariahol...@gmail.com> > 07/29/2009 04:22 PM > > To > staf-users@lists.sourceforge.net > cc > > Subject > [staf-users] fs copy directory performance > > > > > > > Can you provide any insight as to why the following call in a STAX job > to copy a 13MB directory takes over 15 minutes when copying the same > directory between machines using Windows Explorer takes 15 seconds? > > FS <machine1> COPY DIRECTORY D:/QA/Test TODIRECTORY D:/QA/Test > TOMACHINE <machine2> RECURSE KEEPEMPTYDIRECTORIES IGNOREERRORS > > > Am I missing the "super speedy" option? :-) > > Thanks, > Daria > > -------------------------------------------------------------------------- > ---- > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 > 30-Day > trial. Simplify your report design, integration and deployment - and focus > on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > staf-users mailing list > staf-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/staf-users > > -------------- next part -------------- > An HTML attachment was scrubbed... > > ------------------------------ > > Message: 2 > Date: Wed, 29 Jul 2009 17:28:27 -0600 > From: Daria Holden <dariahol...@gmail.com> > Subject: Re: [staf-users] fs copy directory performance > To: Sharon Lucas <luc...@us.ibm.com> > Cc: staf-users@lists.sourceforge.net > Message-ID: > <40db0f060907291628q585752c4qa4ee52c936062...@mail.gmail.com> > Content-Type: text/plain; charset=ISO-8859-1 > > Hi Sharon, > To answer some of you questions: > 1) When I copy the folder in windows explorer, I am copying from a UNC > path to the local machine. For example, I'll find the file on the > share \\<staf-machine>\d\QA\Test, copy it, and paste it to local drive > D:\QA\Test. This operation takes 15 seconds. While > \\<staf-machine>\D\QA\Test is shared, I have not mapped it to a drive > letter on the local machine. There are no mapped drives in this > scenario > > 2) Here again is the request that I sent from the <staf-machine> > STAF local FS COPY DIRECTORY D:/QA/Test TODIRECTORY D:/QA/Test > TOMACHINE mymachine RECURSE KEEPEMPTYDIRECTORIES IGNOREERRORS > > this request takes over 16 minutes to complete. > > 3) I am making the request from and copying from the same machine. I > am copying to a different machine. > > 4) As you can see above, I did specify TOMACHINE, and I did make the > request from "local". > > 5) I tried your xcopy request as follows: > STAF local PROCESS START COMMAND "xcopy" PARMS "D:\QA\Test > \\mymachine\qa\Test /s/e/i/c/v/y" RETURNSTDOUT STDERRTOSTDOUT > SAMECONSOLE WAIT > > and it took under 20 seconds to complete. Note D: is a local drive on > "local". \\mymachine\qa is shared. > > In summary, xcopy is as fast as Explorer, and I can use it with UNC > paths to copy to shares on both our Windows and RedHat clusters. > This is EXACTLY the kind of solution I was looking for. YOU GUYS > ROCK! > > I still think it's weird that the FS COPY DIRECTORY takes so much > longer, but I have my workaround, so am happy.. > > Thank you... > Daria > > On Wed, Jul 29, 2009 at 4:17 PM, Sharon Lucas<luc...@us.ibm.com> wrote: > > > > Daria, > > > > Most operating system's copy commands (e.g. via Windows Explorer or a > copy > > or xcopy command) only let you copy a file/directory to the same > machine, > > not to a remote machine, unless you are using network drives, such as a > > mapped drive on Windows. Then it can copy to or from the network drive > that > > you have access to on the machine. ?Also, note that these operating > system > > copy commands are tuned specifically for that one operating system. > > > > The main purpose of the STAF FS COPY requests is to provide a common way > to > > copy files/directories from one machine to another, no matter what > operating > > system (Windows or Unix) that you're copying files to or from. ?The > speed of > > the copy depends on your network's TCP/IP connections when copying to a > > remote machine and so it will generally be slower than a local copy > > performed by an operating system's copy command. > > > > You said you used Windows Explorer to copy a directory to a remote > machine? > > ?Do you mean you copied the directory to and from a mapped drive named > D:? > > ?e.g. Is D: a mapped drive or a local drive? > > > > What is the exact STAF FS COPY request that you submitted? > > > > Are you copying a directory from and to the same machine and are you > > submitting the STAF FS COPY request from this same machine? > > > > Did you specify the TOMACHINE option in your STAF FS COPY request? ?Note > > that the TOMACHINE specifies the machine to copy the directory and its > > contents to. ?This defaults to the machine which originated the request. > > ?Specifying "local" indicates to copy the directory to the same machine > that > > the directory is being copied from. ?Note that specifying "local" > instead of > > the from machine's host name can significantly improve performance, > > especially if your TCP network performance is slow. ?This is because > "local" > > indicates to use the local IPC network interface whereas specifying a > TCP > > host name or IP address indicates to use the TCP network interface. > ?(This > > is documented in the STAF User's Guide.) > > > > I hope this helps explain some of the performance differences you are > > seeing. > > > > Also note that you can use the STAF PROCESS START request to run a > Windows > > operating system's copy command like xcopy if you are copying a > directory > > from one location to another on the same machine (instead of a STAF FS > COPY > > request) if its performance is faster. ?For example: > > > > ? STAF machine PROCESS START COMMAND "xcopy" PARMS "c:\mydir1 c:\mydir2 > > /s/e/i/c/v/y" RETURNSTDOUT STDERRTOSTDOUT SAMECONSOLE WAIT > > > > -------------------------------------------------------------- > > Sharon Lucas > > IBM Austin, ? luc...@us.ibm.com > > (512) 286-7313 or Tieline 363-7313 > > > > > > > > Daria Holden <dariahol...@gmail.com> > > > > 07/29/2009 04:22 PM > > > > To > > staf-users@lists.sourceforge.net > > cc > > Subject > > [staf-users] fs copy directory performance > > > > > > > > > > Can you provide any insight as to why the following call in a STAX job > > to copy a 13MB directory takes over 15 minutes when copying the same > > directory between machines using Windows Explorer takes 15 seconds? > > > > FS <machine1> COPY DIRECTORY D:/QA/Test TODIRECTORY D:/QA/Test > > TOMACHINE <machine2> RECURSE KEEPEMPTYDIRECTORIES IGNOREERRORS > > > > > > Am I missing the "super speedy" option? ?:-) > > > > Thanks, > > Daria > > > > ------------------------------------------------------------------------ > ------ > > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30- > Day > > trial. Simplify your report design, integration and deployment - and > focus > > on > > what you do best, core application coding. Discover what's new with > > Crystal Reports now. ?http://p.sf.net/sfu/bobj-july > > _______________________________________________ > > staf-users mailing list > > staf-users@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/staf-users > > > > > > > > ------------------------------ > > Message: 3 > Date: Thu, 30 Jul 2009 10:34:00 +0800 > From: Li Wiston <wiston.l...@gmail.com> > Subject: Re: [staf-users] The Urgent Issues for STAFProc core > To: David Bender <bda...@us.ibm.com> > Cc: staf-users@lists.sourceforge.net, sha...@acmet.com > Message-ID: > <44bad5460907291934n4d040630hb4e2f050c4d9e...@mail.gmail.com> > Content-Type: text/plain; charset="windows-1252" > > I have to consult with you all to get the methods of avoid or solve this > problem? > It taking the bad effect on the User experience. > > thanks in advance. > > > > 2009/7/30 Li Wiston <wiston.l...@gmail.com> > > > Thanks, I've developed it using the try catch statement. > > > > But, in this morning I have come accross the STAFProc core again, and > > somehow, it occured many times in the past days. > > > > one core: > > > > [r...@b2b_architec_1365 rails]# gdb -q /usr/local/staf/bin/STAFProc > > core.1010 > > Using host libthread_db library "/lib/tls/libthread_db.so.1". > > Core was generated by `/usr/local/staf/bin/STAFProc'. > > Program terminated with signal 6, Aborted. > > Reading symbols from /lib/tls/libpthread.so.0...done. > > Loaded symbols for /lib/tls/libpthread.so.0 > > Reading symbols from /lib/libcrypt.so.1...done. > > Loaded symbols for /lib/libcrypt.so.1 > > Reading symbols from /lib/libdl.so.2...done. > > Loaded symbols for /lib/libdl.so.2 > > Reading symbols from /usr/local/staf/lib/libSTAF.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAF.so > > Reading symbols from /usr/lib/libstdc++.so.6...done. > > Loaded symbols for /usr/lib/libstdc++.so.6 > > Reading symbols from /lib/tls/libm.so.6...done. > > Loaded symbols for /lib/tls/libm.so.6 > > Reading symbols from /lib/libgcc_s.so.1...done. > > Loaded symbols for /lib/libgcc_s.so.1 > > Reading symbols from /lib/tls/libc.so.6...done. > > Loaded symbols for /lib/tls/libc.so.6 > > Reading symbols from /lib/ld-linux.so.2...done. > > Loaded symbols for /lib/ld-linux.so.2 > > Reading symbols from /usr/local/staf/lib/libSTAFLIPC.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFLIPC.so > > Reading symbols from /usr/local/staf/lib/libSTAFTCP.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFTCP.so > > Reading symbols from /usr/local/staf/lib/libssl.so.0.9.8...done. > > Loaded symbols for /usr/local/staf/lib/libssl.so.0.9.8 > > Reading symbols from /usr/local/staf/lib/libcrypto.so.0.9.8...done. > > Loaded symbols for /usr/local/staf/lib/libcrypto.so.0.9.8 > > Reading symbols from /lib/libnss_files.so.2...done. > > Loaded symbols for /lib/libnss_files.so.2 > > Reading symbols from /usr/local/staf/lib/libSTAFDSLS.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFDSLS.so > > Reading symbols from /usr/local/staf/lib/libJSTAF.so...done. > > Loaded symbols for /usr/local/staf/lib/libJSTAF.so > > Reading symbols from /usr/local/staf/lib/libSTAFZip.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFZip.so > > Reading symbols from /usr/local/staf/lib/libSTAFZlib.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFZlib.so > > Reading symbols from /usr/local/staf/lib/libSTAFLog.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFLog.so > > Reading symbols from /lib/libnss_dns.so.2...done. > > Loaded symbols for /lib/libnss_dns.so.2 > > Reading symbols from /lib/libresolv.so.2...done. > > Loaded symbols for /lib/libresolv.so.2 > > #0 0x009df7a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2 > > (gdb) bt > > #0 0x009df7a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2 > > #1 0x001f3815 in raise () from /lib/tls/libc.so.6 > > #2 0x001f53d1 in abort () from /lib/tls/libc.so.6 > > #3 0x080919ab in generic_signal_handler () > > #4 <signal handler called> > > #5 0x74736f68 in ?? () > > > > > > > > > > another core: > > > > [r...@b2b_architec_1365 rails]# gdb -q /usr/local/staf/bin/STAFProc > > core.1244 > > Using host libthread_db library "/lib/tls/libthread_db.so.1". > > Core was generated by `/usr/local/staf/bin/STAFProc'. > > Program terminated with signal 6, Aborted. > > Reading symbols from /lib/tls/libpthread.so.0...done. > > Loaded symbols for /lib/tls/libpthread.so.0 > > Reading symbols from /lib/libcrypt.so.1...done. > > Loaded symbols for /lib/libcrypt.so.1 > > Reading symbols from /lib/libdl.so.2...done. > > Loaded symbols for /lib/libdl.so.2 > > Reading symbols from /usr/local/staf/lib/libSTAF.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAF.so > > Reading symbols from /usr/lib/libstdc++.so.6...done. > > Loaded symbols for /usr/lib/libstdc++.so.6 > > Reading symbols from /lib/tls/libm.so.6...done. > > Loaded symbols for /lib/tls/libm.so.6 > > Reading symbols from /lib/libgcc_s.so.1...done. > > Loaded symbols for /lib/libgcc_s.so.1 > > Reading symbols from /lib/tls/libc.so.6...done. > > Loaded symbols for /lib/tls/libc.so.6 > > Reading symbols from /lib/ld-linux.so.2...done. > > Loaded symbols for /lib/ld-linux.so.2 > > Reading symbols from /usr/local/staf/lib/libSTAFLIPC.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFLIPC.so > > Reading symbols from /usr/local/staf/lib/libSTAFTCP.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFTCP.so > > Reading symbols from /usr/local/staf/lib/libssl.so.0.9.8...done. > > Loaded symbols for /usr/local/staf/lib/libssl.so.0.9.8 > > Reading symbols from /usr/local/staf/lib/libcrypto.so.0.9.8...done. > > Loaded symbols for /usr/local/staf/lib/libcrypto.so.0.9.8 > > Reading symbols from /lib/libnss_files.so.2...done. > > Loaded symbols for /lib/libnss_files.so.2 > > Reading symbols from /usr/local/staf/lib/libSTAFDSLS.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFDSLS.so > > Reading symbols from /usr/local/staf/lib/libJSTAF.so...done. > > Loaded symbols for /usr/local/staf/lib/libJSTAF.so > > Reading symbols from /usr/local/staf/lib/libSTAFZip.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFZip.so > > Reading symbols from /usr/local/staf/lib/libSTAFZlib.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFZlib.so > > Reading symbols from /usr/local/staf/lib/libSTAFLog.so...done. > > Loaded symbols for /usr/local/staf/lib/libSTAFLog.so > > Reading symbols from /lib/libnss_dns.so.2...done. > > Loaded symbols for /lib/libnss_dns.so.2 > > Reading symbols from /lib/libresolv.so.2...done. > > Loaded symbols for /lib/libresolv.so.2 > > #0 0x009df7a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2 > > (gdb) bt > > #0 0x009df7a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2 > > #1 0x00a24815 in raise () from /lib/tls/libc.so.6 > > #2 0x00a263d1 in abort () from /lib/tls/libc.so.6 > > #3 0x080919ab in generic_signal_handler () > > #4 <signal handler called> > > #5 0x00846427 in OBJ_dup () from /usr/local/staf/lib/libcrypto.so.0.9.8 > > #6 0x00b26860 in main_arena () from /lib/tls/libc.so.6 > > #7 0x00000000 in ?? () > > > > > > > > 2009/7/29 David Bender <bda...@us.ibm.com> > > > >> > >> The <break> element is only valid within <iterate> and <loop> elements. > >> > >> When you have a <paralleliterate>, all of the iterations of the > contained > >> task element are started in parallel, so "exit current iterate and jump > top > >> to next iterate" does not apply, since all of the iterations have > already > >> been started. You can use <if> elements within the <paralleliterate> > task > >> to control the logic/execution flow within the current iteration, as > you are > >> already doing when checking "<if expr="RC !=0">". If you removed the > >> <break> element, then I believe your STAX job would behave in the > manner you > >> are expecting (i.e. nothing in the <else> element will be executed if > RC != > >> 0). > >> > >> The following Help forum thread discusses this topic: > >> http://sourceforge.net/forum/message.php?msg_id=3359199 > >> > >> Thanks, > >> David > >> > >> ------------------------------ > >> *David > Bender*<http://w3.ibm.com/bluepages/simpleSearch.wss?searchBy=Name&searchF > or=David+Bender> > >> STAF/STAX Development > >> IBM Software Group, WPLC > >> 11501 Burnet Rd. > >> Bldg. 903-5B002 > >> Austin, TX 78758-3400 > >> Phone (T/L): 1-512-286-5315 (363-5315) > >> ITN: 23635315 > >> Email: *bda...@us.ibm.com* <bda...@us.ibm.com> > >> > >> > >> ------------------------------ > >> > >> > >> > >> *Li Wiston <wiston.l...@gmail.com>* > >> > >> 07/29/2009 06:31 AM > >> To > >> David Bender/Austin/i...@ibmus > >> cc > >> staf-users@lists.sourceforge.net, sha...@acmet.com > >> Subject > >> [staf-users] Can't break the execution for single iterate when > >> place it in STAX paralleliterate tag? > >> > >> > >> > >> > >> Hi, all > >> > >> For the STAX execution engine, > >> Can't break the execution for single iterate when place it in STAX > >> paralleliterate tag? > >> > >> I feel sure the break tag and the continue tag statement work formally > in > >> iterate and loop statement. > >> it will be jump out or jump top the iterate and loop. > >> > >> I want to consult with you all to get the method to break or continue > the > >> current single literate even if using it in paralleliterate statement, > same > >> as using it in iterate statement. Because, it will work invalid if I > use the > >> break/continue in paralleliterate statement. That is not my expect. > >> > >> For STAX below, i want to exit current iterate and jump top to next > >> iterate. But it is fail to work. > >> > >> Thanks in advance. > >> > >> -Wiston > >> > >> > >> > >> > >> > >> <paralleliterate var = "machineName" in="params[1]" > > >> <sequence> > >> <!--write the distribute in_process status into DB--> > >> <script>error_type='1'</script> > >> <script>staf_update_db(params[0],error_type,machineName)</script> > >> <!--Ping Task--> > >> > >> <log level="'error'"> > >> '\n log:begin staf task run_id= %s on machine= %s \n' % (params[0], > >> machineName) > >> </log> > >> > >> > >> <stafcmd> > >> <location>'%s' % machineName</location> > >> <service>'PING'</service> > >> <request>'Ping'</request> > >> </stafcmd> > >> <if expr="RC !=0"> > >> <sequence> > >> <log message="1">'Ping failed '</log> > >> <script>error_type='-1'</script> > >> <script>staf_update_db(params[0],error_type,machineName)</script> > >> <break/> > >> </sequence> > >> <else> > >> <sequence> > >> <log message="1">'Ping Pass'</log> > >> </sequence> > >> </else> > >> </if> > >> </paralleliterate> > >> > >> > >> > >> > >> 2009/7/28 Li Wiston <*wiston.l...@gmail.com* <wiston.l...@gmail.com>> > >> Thank you very much > >> > >> this is very useful for us. I will try it tomorrow. > >> > >> > >> 2009/7/28 David Bender <*bda...@us.ibm.com* <bda...@us.ibm.com>> > >> > >> > >> Here is a sample Java program that submits a STAX LIST JOBS request, > >> iterates through the result, and submits a STAX TERMINATE JOB request > for > >> each running job. > >> > >> import com.ibm.staf.*; > >> import java.util.*; > >> > >> public class Terminate > >> { > >> public static void main(String[] args) > >> { > >> STAFHandle handle = null; > >> > >> try > >> { > >> handle = new STAFHandle("Test"); > >> } > >> catch(STAFException e) > >> { > >> e.printStackTrace(); > >> System.exit(1); > >> } > >> > >> STAFResult result = handle.submit2("local", "STAX", > >> "LIST JOBS "); > >> > >> STAFMarshallingContext mc = STAFMarshallingContext.unmarshall( > >> result.result); > >> > >> List jobList = (List)mc.getRootObject(); > >> > >> Iterator iter = jobList.iterator(); > >> > >> while (iter.hasNext()) > >> { > >> Map jobMap = (Map)iter.next(); > >> > >> String jobID = (String)jobMap.get("jobID"); > >> System.out.println("JobID: " + jobID); > >> > >> result = handle.submit2("local", "STAX", > >> "TERMINATE JOB " + jobID); > >> > >> System.out.println("STAX TERMINATE JOB " + jobID + " > RC=" > >> + > >> result.rc + ", Result=" + result.result); > >> } > >> } > >> } > >> > >> Here is an example of running this program when 2 STAX jobs are > executing: > >> > >> $ java Terminate > >> JobID: 3 > >> STAX TERMINATE JOB 3 RC=0, Result= > >> JobID: 4 > >> STAX TERMINATE JOB 4 RC=0, Result= > >> > >> Thanks, > >> David > >> > >> ------------------------------ > >> *David > Bender*<http://w3.ibm.com/bluepages/simpleSearch.wss?searchBy=Name&searchF > or=David+Bender> > >> STAF/STAX Development > >> IBM Software Group, WPLC > >> 11501 Burnet Rd. > >> Bldg. 903-5B002 > >> Austin, TX 78758-3400 > >> Phone (T/L): 1-512-286-5315 (363-5315) > >> ITN: 23635315 > >> Email: *bda...@us.ibm.com* <bda...@us.ibm.com> > >> > >> > >> > >> ------------------------------ > >> > >> > >> *Li Wiston <**wiston.l...@gmail.com* <wiston.l...@gmail.com>*>* > >> > >> 07/27/2009 08:35 PM > >> > >> To > >> David Bender/Austin/i...@ibmus cc > >> *staf-us...@lists.sourceforge.net* <staf-users@lists.sourceforge.net>, > * > >> sha...@acmet.com* <sha...@acmet.com> Subject > >> Re: [staf-users] How to get all job and terminate them? > >> > >> > >> > >> > >> > >> > >> Okay, > >> > >> Now the question is how to iterate through the results and get the > field > >> value of each job id by after execute the request? > >> any good methods provider for this? > >> > >> > >> > >> 2009/7/27 David Bender <*bda...@us.ibm.com* <bda...@us.ibm.com>> > >> > >> STAF provides APIs (for Java, Python, Perl, and Tcl) that allow you to > >> submit requests to STAF services. So, in your program you could submit > a > >> STAX LIST JOBS request, then iterate through the results for each Job > ID, > >> and then submit a STAX TERMINATE JOB xx request. > >> > >> Thanks, > >> David > >> > >> ------------------------------ > >> *David > Bender*<http://w3.ibm.com/bluepages/simpleSearch.wss?searchBy=Name&searchF > or=David+Bender> > >> STAF/STAX Development > >> IBM Software Group, WPLC > >> 11501 Burnet Rd. > >> Bldg. 903-5B002 > >> Austin, TX 78758-3400 > >> Phone (T/L): 1-512-286-5315 (363-5315) > >> ITN: 23635315 > >> Email: *bda...@us.ibm.com* <bda...@us.ibm.com> > >> > >> > >> > >> > >> ------------------------------ > >> > >> *Li Wiston <**wiston.l...@gmail.com* <wiston.l...@gmail.com>*>* > >> > >> 07/27/2009 08:26 AM > >> > >> To > >> *sha...@acmet.com* <sha...@acmet.com> cc > >> *staf-us...@lists.sourceforge.net* <staf-users@lists.sourceforge.net>, > >> David Bender/Austin/i...@ibmus Subject > >> Re: [staf-users] How to get all job and terminate them? > >> > >> > >> > >> > >> > >> > >> > >> > >> Yes, I known his. > >> > >> whether i can get the job IDs and assign them to variable or not ? so > that > >> terminate the job one by one in my program? > >> > >> or any other way can retrieve each of iDs? > >> > >> thanks. > >> -Wiston > >> > >> > >> > >> 2009/7/27 Shahid <*sha...@acmet.com* <sha...@acmet.com>> > >> >> But, I want to terminate all jobs by program. so, I have to get the > >> lists for pending job ids by program or need to terminate all jobs > >> > >> >> if STAF provides such a command? > >> > >> > >> > >> I think STAF does not provide any command for terminating all pending > >> jobs. But if you will re-start STAF framework, then all the pending > jobs > >> will be terminated automatically. > >> > >> > >> > >> Without re-starting STAF framework, you can terminate all pending jobs > >> with the help of program by using following alog: > >> > >> > >> 1. List all the pending jobs > >> 2. Extract pending job ID > >> 3. Terminate the job with the help of job ID [This should be > done > >> one by one] > >> > >> > >> > >> > >> > >> With Regards, > >> > >> Mohammad Shahid Jamal > >> > >> > >> > >> > >> > >> ------------------------------ > >> > >> *From:* Li Wiston > [mailto:*wiston.l...@gmail.com*<wiston.l...@gmail.com>] > >> * > >> Sent:* Sunday, July 26, 2009 6:44 AM > >> > >> * > >> To:* *sha...@acmet.com* <sha...@acmet.com>* > >> Cc:* David Bender; *staf-us...@lists.sourceforge.net*<staf- > us...@lists.sourceforge.net> > >> * > >> Subject:* Re: [staf-users] How to get all job and terminate them? > >> > >> > >> > >> Thanks Shahid > >> > >> > >> > >> But, I want to terminate all jobs by program. so, I have to get the > lists > >> for pending job ids by program or need to terminate all jobs > >> > >> if STAF provides such a command? > >> > >> > >> > >> > >> > >> 2009/7/24 Shahid <*sha...@acmet.com* <sha...@acmet.com>> > >> > >> You can get the pending jobs with the help of following command: > >> > >> > >> > >> STAF <MACHINE NAME> STAX LIST JOBS > >> > >> > >> > >> Above command will list all the pending job submitted to STAX execution > >> engine. > >> > >> > >> > >> You can terminate the pending STAX Job execution with the help of > >> following command: > >> > >> > >> > >> STAF <MACHINE NAME> STAX TERMINATE JOB <JOB ID> > >> > >> > >> > >> >> Which reason can result in the block jobs? > >> > >> > >> > >> Currently I don?t know the exact reason behind it. > >> > >> > >> > >> But before few months, we have also faced similar problem. The reason > of > >> the problem was, using the DOS command in STAX Job, at the time of > executing > >> the DOS command in STAX Job, Job gets hanged. Please check this might > be the > >> case. > >> > >> > >> > >> With Regards, > >> > >> Mohammad Shahid Jamal > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> ------------------------------ > >> > >> *From:* Li Wiston > [mailto:*wiston.l...@gmail.com*<wiston.l...@gmail.com>] > >> * > >> Sent:* Friday, July 24, 2009 11:50 AM* > >> To:* *sha...@acmet.com* <sha...@acmet.com>* > >> Cc:* David Bender; *staf-us...@lists.sourceforge.net*<staf- > us...@lists.sourceforge.net> > >> * > >> Subject:* Re: [staf-users] How to get all job and terminate them? > >> > >> > >> > >> Hi, all > >> > >> > >> > >> > >> > >> For unknown issues, there are some blocked jobs for the STAX execution, > my > >> question is How to get all job and terminate them? and which reason can > >> result in the block jobs? > >> > >> > >> > >> > >> > >> can anyone give us some clue? > >> > >> > >> > >> thanks in advance. > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> 2009/7/21 Shahid <*sha...@acmet.com* <sha...@acmet.com>> > >> > >> >> Can you clarify exactly what you mean by "profiling" STAX job > >> execution? > >> > >> > >> > >> Profiling of STAX Job means to gather following information about STAX > Job > >> execution: > >> > >> > >> 1. Memory / CPU usage by services / methods written in STAX Job > >> 2. Checking the memory leak during STAX Job execution > >> 3. Checking the dead lock condition during STAX Job execution > >> 4. Time taken by STAF services used in STAX Job and method > written > >> in STAX Job for completing the request > >> > >> > >> > >> > >> > >> Hope, now you got the purpose of profiling of STAX Job. > >> > >> > >> > >> >>The following Help forum thread has some more information: > >> >> > >> > >>*http://sourceforge.net/forum/message.php?msg_id=7421451*<http://sourcef > orge.net/forum/message.php?msg_id=7421451> > >> > >> > >> > >> Thanks for providing the link. I will check information present at: * > >> > http://sourceforge.net/forum/message.php?msg_id=7421451*<http://sourceforg > e.net/forum/message.php?msg_id=7421451>and let you know it status. > >> > >> > >> > >> > >> > >> Thanks and Regards, > >> > >> Mohammad Shahid Jamal > >> > >> > >> > >> > >> > >> ------------------------------ > >> > >> *From:* David Bender [mailto:*bda...@us.ibm.com* <bda...@us.ibm.com>] > * > >> Sent:* Monday, July 20, 2009 7:22 PM* > >> To:* *sha...@acmet.com* <sha...@acmet.com>* > >> Cc:* *staf-us...@lists.sourceforge.net*<staf- > us...@lists.sourceforge.net> > >> * > >> Subject:* Re: [staf-users] How to profile STAX Job Execution? > >> > >> > >> > >> > >> Can you clarify exactly what you mean by "profiling" STAX job > execution? > >> If you mean analyzing memory usage, performance, etc., there is no > software > >> provided with STAF/STAX to do that. However, STAX is written in Java, > so > >> you could use Java profiling tools to do the analysis. > >> > >> The following Help forum thread has some more information: * > >> > >> > **http://sourceforge.net/forum/message.php?msg_id=7421451*<http://sourcefo > rge.net/forum/message.php?msg_id=7421451> > >> > >> Thanks, > >> David > >> > >> ------------------------------ > >> *David > Bender*<http://w3.ibm.com/bluepages/simpleSearch.wss?searchBy=Name&searchF > or=David+Bender> > >> STAF/STAX Development > >> IBM Software Group, WPLC > >> 11501 Burnet Rd. > >> Bldg. 903-5B002 > >> Austin, TX 78758-3400 > >> Phone (T/L): 1-512-286-5315 (363-5315) > >> ITN: 23635315 > >> Email: *bda...@us.ibm.com* <bda...@us.ibm.com> > >> > >> > >> > >> > >> ------------------------------ > >> > >> > >> > >> *"Shahid" <**sha...@acmet.com* <sha...@acmet.com>*>* > >> > >> 07/20/2009 12:42 AM > >> > >> > >> Please respond to* > >> **sha...@acmet.com* <sha...@acmet.com> > >> > >> > >> To > >> <*staf-us...@lists.sourceforge.net* <staf-users@lists.sourceforge.net>> > >> cc > >> Subject > >> [staf-users] How to profile STAX Job Execution? > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> How we can profile the STAX Job execution? Is there any software > available > >> for profiling STAX Job execution? > >> > >> With Regards, > >> Mohammad Shahid Jamal > >> > >> > >> > >> ----------------------------------------------------------------------- > ------- > >> Enter the BlackBerry Developer Challenge > >> This is your chance to win up to $100,000 in prizes! For a limited > time, > >> vendors submitting new applications to BlackBerry App World(TM) will > have > >> the opportunity to enter the BlackBerry Developer Challenge. See full > >> prize > >> details at: > *http://p.sf.net/sfu/Challenge*<http://p.sf.net/sfu/Challenge> > >> _______________________________________________ > >> staf-users mailing list* > >> **staf-us...@lists.sourceforge.net* <staf-users@lists.sourceforge.net>* > >> **https://lists.sourceforge.net/lists/listinfo/staf- > users*<https://lists.sourceforge.net/lists/listinfo/staf-users> > >> > >> > >> > >> ----------------------------------------------------------------------- > ------- > >> Enter the BlackBerry Developer Challenge > >> This is your chance to win up to $100,000 in prizes! For a limited > time, > >> vendors submitting new applications to BlackBerry App World(TM) will > have > >> the opportunity to enter the BlackBerry Developer Challenge. See full > >> prize > >> details at: > *http://p.sf.net/sfu/Challenge*<http://p.sf.net/sfu/Challenge> > >> _______________________________________________ > >> staf-users mailing list* > >> **staf-us...@lists.sourceforge.net* <staf-users@lists.sourceforge.net>* > >> **https://lists.sourceforge.net/lists/listinfo/staf- > users*<https://lists.sourceforge.net/lists/listinfo/staf-users> > >> > >> > >> > >> > >> > >> ----------------------------------------------------------------------- > ------- > >> > >> > >> _______________________________________________ > >> staf-users mailing list* > >> **staf-us...@lists.sourceforge.net* <staf-users@lists.sourceforge.net>* > >> **https://lists.sourceforge.net/lists/listinfo/staf- > users*<https://lists.sourceforge.net/lists/listinfo/staf-users> > >> > >> > >> ----------------------------------------------------------------------- > ------- > >> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 > >> 30-Day > >> trial. Simplify your report design, integration and deployment - and > focus > >> on > >> what you do best, core application coding. Discover what's new with > >> Crystal Reports now. * > >> http://p.sf.net/sfu/bobj- > july_______________________________________________ > >> *<http://p.sf.net/sfu/bobj- > july_______________________________________________> > >> > >> > >> staf-users mailing list* > >> **staf-us...@lists.sourceforge.net* <staf-users@lists.sourceforge.net>* > >> **https://lists.sourceforge.net/lists/listinfo/staf- > users*<https://lists.sourceforge.net/lists/listinfo/staf-users> > >> > >> > >> > >> ----------------------------------------------------------------------- > ------- > >> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 > >> 30-Day > >> trial. Simplify your report design, integration and deployment - and > focus > >> on > >> what you do best, core application coding. Discover what's new with > >> Crystal Reports now. > >> http://p.sf.net/sfu/bobj- > july_______________________________________________ > >> staf-users mailing list > >> staf-users@lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/staf-users > >> > >> > > > -------------- next part -------------- > An HTML attachment was scrubbed... > > ------------------------------ > > -------------------------------------------------------------------------- > ---- > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30- > Day > trial. Simplify your report design, integration and deployment - and focus > on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > > ------------------------------ > > _______________________________________________ > staf-users mailing list > staf-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/staf-users > > > End of staf-users Digest, Vol 38, Issue 57 > ****************************************** ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ staf-users mailing list staf-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/staf-users