Stile
Apr 30th, 2007, 04:05 AM
I have an app that reads an incoming data stream from a UDP port. The datastream is in the form of a single string, with line separators. I simply need to read the last line of the string, in order to get the latest data.
However, as the string continues to build, it takes longer to get to the last line, since the size of the stream is increasing continously. What I want to be able to do is stop the incoming stream, and then restart it, every 5 minutes or so. What this would do is, it would restart the stream fresh after each restart.
What are my options for this? What command can i use to stop/restart an incoming UDP stream? Obviously i want the interruption to be as small as possible, since i dont want to miss data. Any ideas?
However, as the string continues to build, it takes longer to get to the last line, since the size of the stream is increasing continously. What I want to be able to do is stop the incoming stream, and then restart it, every 5 minutes or so. What this would do is, it would restart the stream fresh after each restart.
What are my options for this? What command can i use to stop/restart an incoming UDP stream? Obviously i want the interruption to be as small as possible, since i dont want to miss data. Any ideas?