Results 1 to 2 of 2
  1. #1
    verWire3619 is offline Member
    Join Date
    May 2011
    Posts
    3
    Rep Power
    0

    Default Sftp thread for multiple site

    I'm new to multithreading. I want to develop code that will read login information from a file (have that part) and use it to Sftp files using the information. The Sftp part is working. In some case I have 60+ sites to sftp files from. It takes 57 secs when this is done in C++. I didn't write the code, so I don't understand it. I want to do them same in Java, but don't know how. My thought is I will develop an SftpThread that will do the work. My main will read the login info into a Map then loop through the map creating a thread for each login entry. Does this sound reasonable? Not sure if I should use "extends Thread" or "implements Runnable". And how many threads are too many? Any advice and/or guidance will be much appreciated. Currently, this is done sequentially and taking over 30 mins to complete. Of course this is unacceptable.

  2. #2
    Hibernate's Avatar
    Hibernate is offline Senior Member
    Join Date
    Dec 2010
    Location
    Stockholm, Sweden
    Posts
    222
    Blog Entries
    9
    Rep Power
    5

    Default

    Quote Originally Posted by verWire3619 View Post
    Any advice and/or guidance will be much appreciated.
    My advice is to write your post on more then one line so we do not get eye-ache while reading it.
    After that I would like a minor [actually almost major] clarification, do you mean FTPS (Explicity secure FTP)
    or SFTP (SSH [like in the Unix-like-world] file transfer protocol)?
    Ex animo! Hibernate
    Java, Arch Linux, C, GPL v3, Bash, Eclipse, Linux VT, GNOME 2 and many buttons on windows.

Similar Threads

  1. Java Download from SFTP
    By hardcorebadger in forum New To Java
    Replies: 3
    Last Post: 01-21-2011, 04:49 PM
  2. while running multiple thread repaint isnt being called....
    By raptor in forum Threads and Synchronization
    Replies: 4
    Last Post: 08-26-2010, 12:47 AM
  3. sftp Authentication
    By suprimcy in forum New To Java
    Replies: 2
    Last Post: 06-01-2010, 01:49 AM
  4. SFTP applet (SSH FTP)
    By jfileupload in forum Java Software
    Replies: 1
    Last Post: 02-26-2009, 11:31 PM
  5. Rad SFTP Applet 2.01
    By levent in forum Java Software
    Replies: 0
    Last Post: 05-22-2007, 07:59 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •