[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

Internet communication problem (UDP)

Posted on 2001-06-03
4
Medium Priority
?
447 Views
Last Modified: 2010-04-06
Hello.

I'm currently developing a program that is suppose to
receive UDP packets.

I've successfully managed to send and receive single
UDP packets, however I need to receive a "stream" type
of udp packets. Example:

A server sends X UDP packets to me, how do I know when
the server is done sending? (I don't know how many packets the server will send and there is NO data within
the packet that will tell me that!)

The protocol that the server is using simply says:
.... but for now you just need to test for the end of the stream when you are reading in the constent string.

So my question is, how do i "test" for the end of a UDP stream? My socket is non-blocking (async)

To accept an answer I need source code, if component then there must be source to that too!

0
Comment
Question by:blasse
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 13

Accepted Solution

by:
Epsylon earned 800 total points
ID: 6150246
UDP is 'connectionless', so there's no way to know, unless you number the packets yourself.
Another problem is that if one packet gets lost, the client will never know, unless you take care of error correction yourself.
0
 
LVL 3

Expert Comment

by:smurff
ID: 6151848
To be honest, thats why theres TCP or UDP. If you use TCP then it will have error checking and once a peice of data is sent, a "ACK" will be sent back to say "yes Ive got that data thanks"
Is there a reason why it has to be UDP?
0
 
LVL 11

Expert Comment

by:robert_marquardt
ID: 8891050
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

Please accept Epsylon's comment as answer.

Please leave any comments here within the next seven days.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
Robert Marquardt
EE Cleanup Volunteer
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
Suggested Courses

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question