Results 1 to 2 of 2
  1. #1
    Join Date
    Apr 2010
    Rep Power

    Default concurrent programming

    Questions for the experts out here...
    I am very new to java... I treat it as C till now..but now i have to do multithreading for what i want to achieve...
    Any suggestions on how to perform multithreading in java...

    I got four programs , each of them gets a packet of data and check the first four bytes and compares them to last 4 bytes and if the difference is greater than 2 then they overwrite the file else they write it in to file.I have now synchronization issues since i have four independant programs..i want to merge them together.

    Ideally i would like to start 4 threads , each thread receiving packets independantly ,cacultes the difference and the difference value has to be passed to the main function where i would check the values of all threads, would decide if i want to overwrite all the files of each thread or write data into it.
    Any idea how to pass data between threads ?
    Would really appreciate the help.

  2. #2
    Zack's Avatar
    Zack is offline Senior Member
    Join Date
    Jun 2010
    Destiny Islands
    Rep Power

Similar Threads

  1. concurrent access to a Socket()
    By flok in forum Networking
    Replies: 1
    Last Post: 10-19-2009, 04:56 PM
  2. Concurrent trail example
    By bert682 in forum Threads and Synchronization
    Replies: 4
    Last Post: 10-11-2009, 04:47 PM
  3. Concurrent users to the web site
    By Chinnu in forum Java Servlet
    Replies: 3
    Last Post: 08-11-2009, 05:41 AM
  4. Concurrent Applications
    By m@tqi in forum Advanced Java
    Replies: 1
    Last Post: 12-01-2007, 12:09 AM
  5. Concurrent Versions System (CVS)
    By JavaForums in forum Eclipse
    Replies: 0
    Last Post: 05-02-2007, 03:03 PM

Posting Permissions

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