Is there a way i can hide the port from url and use cname (alias) instead of :.
For e.g. If my url is http://myserver.com:40089/webapps/index.jsp Is its possible for
With DNS CNAME you can only point from one hostname to another. Port numbers are a totally different piece of cake.
There are several problems with the described situation:
http://mycname:40080/webapps/index.jspYou haven't mentioned but I assume that you cannot modify your webserver settings, because in this case you could modify the port number as well.
But there is a solution for this problem with small sacrifices.
You can install an HTTP reverse proxy server to forward the requests to the webserver (for e.g. HAProxy, nginx, etc.) but with this you'll loose the original clients' IP address (of course you can forward it in an HTTP header but you have to modify the code on your previous domain to handle this).