UDP based BulkSendApplication

146 views
Skip to first unread message

Majid

unread,
Aug 22, 2013, 5:54:37 PM8/22/13
to ns-3-...@googlegroups.com
Hi Everyone:
 
I am trying to setup a UDP bulk transfer application similar to the BulkSendApplication implemented in ns3.
 
While BulkSendHelper allows specifiying the type of socket to be used in the application, there is a piece of code in BulkSendApplication implementation that prevents UDP sockets from being used by the application:
 
// Fatal error if socket type is not NS3_SOCK_STREAM or NS3_SOCK_SEQPACKET
  121       if (m_socket->GetSocketType () != Socket::NS3_SOCK_STREAM &&
  122           m_socket->GetSocketType () != Socket::NS3_SOCK_SEQPACKET)
  123         {
  124           NS_FATAL_ERROR ("Using BulkSend with an incompatible socket type. "
  125                           "BulkSend requires SOCK_STREAM or SOCK_SEQPACKET. "
  126                           "In other words, use TCP instead of UDP.");

  127         }

 

My questions is: What is TCP specific in BulkSendApplication implementation that is not consistent with UDP sockets?

 

Thanks.

Sara Lakani

unread,
Aug 22, 2013, 6:49:20 PM8/22/13
to ns-3-...@googlegroups.com
Hi Majid

I'm not sure but just to tell my opinion; because in BulkSendApp the acknowledge packets are provisioned, it will not function with other protocols.

BR Sara

Majid

unread,
Aug 23, 2013, 3:19:40 PM8/23/13
to ns-3-...@googlegroups.com
Thanks!
 
In the absence of proper documentation about UDP sockets, I can only speculate that the following calls are probably specific to TCP sockets in ns3:
 
      m_socket->SetConnectCallback (
        MakeCallback (&BulkSendApplication::ConnectionSucceeded, this),
        MakeCallback (&BulkSendApplication::ConnectionFailed, this));

      m_socket->SetSendCallback (
        MakeCallback (&BulkSendApplication::DataSend, this));
 
The second call is problematic if UDP sockets have infinite buffer at the sending side.
 
Majid
Reply all
Reply to author
Forward
0 new messages