Spring 如何使用相对内点地址?
使用Spring引导配置,我有一个例外Spring 如何使用相对内点地址?,spring,spring-boot,jax-ws,Spring,Spring Boot,Jax Ws,使用Spring引导配置,我有一个例外 Caused by: java.net.MalformedURLException: no protocol: /CustomerService 如何放置相对(部署的webapp)url 看起来您需要将有效的URL作为字符串传递才能发布,正如您在下面的函数中看到的那样。它是EndpointImpl.java的一个片段。希望这有帮助 public void More ...publish(String address) { 127 canPu
Caused by: java.net.MalformedURLException: no protocol: /CustomerService
如何放置相对(部署的webapp)url
看起来您需要将有效的URL作为字符串传递才能发布,正如您在下面的函数中看到的那样。它是EndpointImpl.java的一个片段。希望这有帮助
public void More ...publish(String address) {
127 canPublish();
128 URL url;
129 try {
130 url = new URL(address);
131 } catch (MalformedURLException ex) {
132 throw new IllegalArgumentException("Cannot create URL for this address " + address);
133 }
看起来它需要一个不同的url和一个不同的端口,所以它不能是相对的webapp地址它需要是一个完整的url和协议,域等。
public void More ...publish(String address) {
127 canPublish();
128 URL url;
129 try {
130 url = new URL(address);
131 } catch (MalformedURLException ex) {
132 throw new IllegalArgumentException("Cannot create URL for this address " + address);
133 }