String contextPath = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+
request.getServerPort()+contextPath+"/";
System.out.println(basePath);// http://localhost:8081/sgcc/
String contextPath = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+
request.getServerPort()+contextPath+"/";
System.out.println(basePath);// http://localhost:8081/sgcc/