"Dropping message: No listening point " + "registered!");
"Dropping message: No listening point registered!");
	public void processRequest(		SIPRequest sipRequest,		MessageChannel incomingMessageChannel)		throws SIPServerException {		// Generate the wrapper JAIN-SIP object.		if (LogWriter.needsLogging)			sipStackImpl.logMessage(				"PROCESSING INCOMING REQUEST " + sipRequest.getFirstLine());		if (listeningPoint == null) {			if (LogWriter.needsLogging)				sipStackImpl.logMessage(					"Dropping message: No listening point " + "registered!");			return;		}		this.rawMessageChannel = incomingMessageChannel;		SIPTransactionStack sipStack =			(SIPTransactionStack) transactionChannel.getSIPStack();		gov.nist.javax.sip.SipStackImpl sipStackImpl = (SipStackImpl) sipStack;		SipProviderImpl sipProvider = listeningPoint.getProvider();		if (sipProvider == null) {			if (LogWriter.needsLogging)				sipStackImpl.logMessage("No provider - dropping !!");			return;		}		SipListener sipListener = sipProvider.sipListener;		SIPTransaction transaction = transactionChannel;		// Look for the registered SIPListener for the message channel.//ifndef SIMULATION//		synchronized (sipProvider) {//endif//			if (sipRequest.getMethod().equalsIgnoreCase(Request.ACK)) {				// Could not find transaction. Generate an event				// with a null transaction identifier.				String dialogId = sipRequest.getDialogId(true);				DialogImpl dialog = sipStackImpl.getDialog(dialogId);				if (LogWriter.needsLogging)					sipStackImpl.logMessage(						"Processing ACK for dialog " + dialog);				if (dialog == null) {					if (LogWriter.needsLogging) {						sipStackImpl.logMessage(							"Dialog does not exist "								+ sipRequest.getFirstLine()								+ " isServerTransaction = "								+ true);					}					// Bug reported by Antonis Karydas					transaction =						sipStackImpl.findTransaction(sipRequest, true);				} else if (dialog.getLastAck()!= null &&					   dialog.getLastAck().equals(sipRequest) ){					if (sipStackImpl.isRetransmissionFilterActive() ) {							dialog.ackReceived(sipRequest);							transaction.setDialog(dialog);						if (LogWriter.needsLogging) {							sipStackImpl.logMessage							("Retransmission Filter enabled - dropping Ack"+							 " retransmission");						}						return;					}					if (LogWriter.needsLogging)						sipStackImpl.logMessage(							"ACK retransmission for 2XX response "							+ "Sending ACK to the TU");				} else {					// This could be a re-invite processing.					// check to see if the ack matches with the last					// transaction.					SIPTransaction tr = dialog.getLastTransaction();					SIPResponse sipResponse = tr.getLastResponse();					// Idiot check for sending ACK from the wrong side!					if (tr instanceof SIPServerTransaction 						&& sipResponse != null						&& sipResponse.getStatusCode() / 100 == 2						&& sipResponse.getCSeq().getSequenceNumber()							== sipRequest.getCSeq().getSequenceNumber()) {						transaction.setDialog(dialog);						dialog.ackReceived(sipRequest);						if (sipStackImpl.isRetransmissionFilterActive() &&							tr.ackSeen()) {							if (LogWriter.needsLogging)								sipStackImpl.logMessage(								"ACK retransmission for 2XX response --- "									+ "Dropping ");							return;						} else {							// record that we already saw an ACK for							// this transaction.							tr.setAckSeen();							sipStackImpl.logMessage(								"ACK retransmission for 2XX response --- "									+ "sending to TU ");						}																			} else {						if (LogWriter.needsLogging)							sipStackImpl.logMessage(								"ACK retransmission for non 2XX response "									+ "Discarding ACK");						// Could not find a transaction.						if (tr == null) {							if (LogWriter.needsLogging)								sipStackImpl.logMessage(									"Could not find transaction ACK dropped");							return;						}						transaction = tr;						if (transaction instanceof SIPClientTransaction) {							if (LogWriter.needsLogging)								sipStackImpl.logMessage("Dropping late ACK");							return;						}					}				}			} else if (sipRequest.getMethod().equals(Request.BYE) ) {				transaction = this.transactionChannel;				// If the stack has not mapped this transaction because				// of sequence number problem then just drop the BYE				if (transaction != null &&				     ((SIPServerTransaction)transaction).isTransactionMapped()) {				    // Get the dialog identifier for the bye request.					String dialogId = sipRequest.getDialogId(true);					if (LogWriter.needsLogging)						sipStackImpl.logMessage("dialogId = " + dialogId);					DialogImpl dialog = sipStackImpl.getDialog(dialogId);					if (dialog != null) {						dialog.addTransaction(transaction);					} else {						dialogId = sipRequest.getDialogId(false);						if (LogWriter.needsLogging)							sipStackImpl.getLogWriter().logMessage(							"dialogId = " + dialogId);						dialog = sipStackImpl.getDialog(dialogId);						if (dialog != null) {							dialog.addTransaction(transaction);						} else {							transaction = null; // pass up to provider for							// stateless handling.						}					}							} else if (transaction != null)  {					// This is an out of sequence BYE					// transaction was allocated but					// not mapped to the stack so					// just discard it.					if (LogWriter.needsLogging)					    sipStackImpl.logMessage						("Dropping out of sequence BYE");					return;				}				// note that the transaction may be null (which 				// happens when no dialog for the bye was fund.			} else if (				sipRequest.getRequestLine().getMethod().equals(					Request.CANCEL)) {				// The ID refers to a previously sent				// INVITE therefore it refers to the				// server transaction table.				// Bug reported by Andreas Bystrm				// Find the transaction to cancel.				// Send a 487 for the cancel to inform the				// other side that we've seen it but do not send the				// request up to the application layer.				// Get rid of the CANCEL transaction -- we pass the				// transaciton we are trying to cancel up to the TU.				// Antonis Karydas: Suggestion				// 'transaction' here refers to the transaction to 				// be cancelled. Do not change				// it's state because of the CANCEL. 				// Wait, instead for the 487 from TU.				// transaction.setState(SIPTransaction.TERMINATED_STATE);				SIPServerTransaction serverTransaction =					(SIPServerTransaction) sipStack.findCancelTransaction(						sipRequest,						true);				// Generate an event				// with a null transaction identifier.				if (serverTransaction == null) {					// Could not find the invite transaction.					if (LogWriter.needsLogging) {						sipStackImpl.logMessage(							"transaction "								+ " does not exist "								+ sipRequest.getFirstLine()								+ "isServerTransaction = "								+ true);					}					transaction = null;				} else {					transaction = serverTransaction;				}			}			if (LogWriter.needsLogging) {				sipStackImpl.logMessage("-----------------");				sipStackImpl.logMessage(sipRequest.toString());			}			// If the transaction is found then it is already managed so			// dont call the listener.			if (sipStack.isDialogCreated(sipRequest.getMethod())) {				if ((SIPServerTransaction) sipStack					.findTransaction(sipRequest, true) 				!= null) {					return;				} // TODO check for whether dialog exists here.			}			String dialogId = sipRequest.getDialogId(true);			DialogImpl dialog = sipStackImpl.getDialog(dialogId);			// Sequence numbers are supposed to be incremented			// monotonically (actually sequentially),			if (dialog != null && 				transaction != null && 				! sipRequest.getMethod().equals(Request.BYE) &&				! sipRequest.getMethod().equals(Request.CANCEL) &&				! sipRequest.getMethod().equals(Request.ACK)) {				// already dealt with bye above.				// Note that route updates are only effective until				// Dialog is in the confirmed state.				if (  dialog.getRemoteSequenceNumber() >= 				      sipRequest.getCSeq().getSequenceNumber() ) {				      if (LogWriter.needsLogging) {					sipStackImpl.logMessage					("Dropping out of sequence message " +				          dialog.getRemoteSequenceNumber() + 					  " "  + sipRequest.getCSeq());				     }				      				      return;				}				dialog.addTransaction(transaction);				dialog.addRoute(sipRequest);			}			RequestEvent sipEvent;			if (dialog == null				&& sipRequest.getMethod().equals(Request.NOTIFY)) {				SIPClientTransaction ct =					sipStack.findSubscribeTransaction(sipRequest);				// From RFC 3265				// If the server transaction cannot be found or if it				// aleady has a dialog attached to it then just assign the				// notify to this dialog and pass it up. 				if (ct != null) {					transaction.setDialog((DialogImpl) ct.getDialog());					if (ct.getDialog().getState() == null) {						sipEvent =							new RequestEvent(								sipProvider,								null,								(Request) sipRequest);					} else {						sipEvent =							new RequestEvent(								(SipProvider) sipProvider,								(ServerTransaction) transaction,								(Request) sipRequest);					}				} else {					// Got a notify out of the blue - just pass it up 					// for stateless handling by the application.					sipEvent =						new RequestEvent(							sipProvider,							null,							(Request) sipRequest);				}			} else {				// For a dialog creating event - set the transaction to null.				// The listener can create the dialog if needed.				if (transaction != null					&& ((SIPServerTransaction) transaction).isTransactionMapped())					sipEvent =						new RequestEvent(							sipProvider,							(ServerTransaction) transaction,							(Request) sipRequest);				else					sipEvent =						new RequestEvent(							sipProvider,							null,							(Request) sipRequest);			}			sipProvider.handleEvent(sipEvent, transaction);//ifndef SIMULATION//		}//endif//	}