• Post Reply Bookmark Topic Watch Topic
  • New Topic

MessageContext is giving null in AXIS

 
Tauri Valor
Ranch Hand
Posts: 181
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am trying to get the remote ip address of the client who is accessing my WebService, i used this below code
MessageContext curContext = MessageContext.getCurrentContext();
String remoteIp = "Unknown";
if(curContext != null) {
Object ipProperty = curContext.getProperty(Constants.MC_REMOTE_ADDR); remoteIp = ipProperty.toString();
}
Bu everytime, i am getting MessageContext as null. So, i couldn't able to get the remote ip. Please advise me on this.
[ September 11, 2008: Message edited by: Tauri Valor ]
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!