title: SIP Mobicents - How to create new Request in a existing dialog? (Same Call-ID)
body: <p>I'm currently developing a communication-system with sip, using mobicents (sip-servlet implementation on tomcat) as basis. I tryed to implement a Notification-Service, where UAs can subscribe to get Status-Info via Notify from time to time. As I read in RFC3265-"Specific Event Notification" the NOTIFY-Messages of the Subscription must have the same Call-ID because they belong to the Subscribe-Dialog.</p>
  
  <p>Problem: Now I have problems with creating NOTIFYs with the same Call-ID, because I have no idea how to tell the servlet-container that the new request belongs to a current dialog.
  This is what I tryed for testing:</p>
  
  <pre><code>public void doSubscribe(SipServletRequest request){
      try{
          //Get Session
          SipApplicationSession session = request.getApplicationSession();
  
          //Send response
          SipServletResponse response = request.createResponse(SipServletResponse.SC_OK);
          response.setExpires(600);
          response.setHeader("Event", "buddylist");
          response.send();
  
          //Send notify (same call-id!!!)
          Address serverAddress = this.sipFactory.createAddress("sip:server@test.com");
          SipServletRequest newRequest  = sipFactory.createRequest(session, "NOTIFY", serverAddress, request.getFrom());
          newRequest.setHeader("Subscription-State", "active;expires=600");
          newRequest.setHeader("Event", "buddylist");
          newRequest.send();
      } catch(Exception e){
          e.printStackTrace();
      }       
  }
  </code></pre>
  
  <p>I thought adding the same session would do the job, but it doesn't. Does anyone know how to do this right?</p>