Hi,  

I have a need to modify SIPp to support multiple remote destinations in UAC 
mode.  The idea being to supply additional hosts to SIPp, which are stored in 
an array of remote_hosts[], and then each successive call does a round robin to 
the next host in the array.  A new variable in the call class stores the index 
to the socket array that is used by that call's destination.  The goal is to 
test a N-wide server setup, where launching N instances of SIPp becomes 
unwieldy for the operator.

I've done some of this work, but have a few areas of code in sipp.c that I'm 
not familiar with, and I'm hoping someone can shed some light:

Issue #1:  recv_message in sipp.c makes a call to send_message, which supplies 
a socket.  The send is in a conditional block like thus:
  if((pollfiles[(*poll_idx)].revents & POLLOUT) != 0 ) {
    ...
    if (pending_msg[(*poll_idx)] != NULL)
      {
        char * VP_tmp = strdup(pending_msg[(*poll_idx)]);
        free(pending_msg[(*poll_idx)]);
        pending_msg[(*poll_idx)] = NULL;
        send_message(pollfiles[(*poll_idx)].fd, NULL, VP_tmp, 0);
        free(VP_tmp);
      }

Can someone enlighten me on what pollfiles is?  This looks like a way to send 
messages that have already been queued up by the call somewhere.  If using a 
call based socket - how would I go about identifying the call instance involved 
in the pending message?


Issue #2:  This code accepts an incoming TCP connection request.  
        if(s == main_socket) {
          /* New incoming connection */
          sipp_socklen_t len = SOCK_ADDR_SIZE(&remote_sockaddr);
          int new_sock = accept(s,(sockaddr *)(void *)&remote_sockaddr,&len);

My assumption is that this will only be executed during UAS mode, since UAC 
mode initiates all his socket connections?


Issue #3: decompress_if_needed which is called by recv_message uses a sock.  At 
this point in recv_message, I've no idea what's being done.  Can someone speak 
intelligently about what the code surrounding decompress_if_needed does?

I'd appreciate any pointers.

Thanks

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Sipp-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sipp-users

Reply via email to