0

私のliferayポートレットjsonwsはリモートロケーションからアクセスできませんが、localhostを使用してアクセスできます

example [http://localhost:8050/MySite-portlet/api/secure/jsonws] is accesible on the lacal machine
but when i try to access it remotely using the external ip e.g
[http://120.23.223.24:8050/MySite-portlet/api/secure/jsonws] its returning me the Connection refused error

ただし[http://120.23.223.24:8050/api/jsonws][http://120.23.223.24:8050/web/MySite]動作しています

私の portal-ext.properties ファイルには次のエントリが含まれています

open.id.auth.enabled=
auth.login.site.url=
auth.login.community.url=
company.default.home.url=
default.logout.page.path=
default.landing.page.path=
redirect.url.ips.allowed=
jsonws.servlet.hosts.allowed=
json.servlet.hosts.allowed=
json.web.service.enabled=true
jsonws.web.service.public.methods=*
json.service.auth.token.enabled=true
jsonws.web.service.strict.http.method=false

liferay-tomcat 6.1.0 を使用しています

以下は私が得ているエラーです

type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.


    exception

    `java.net.ConnectException: Connection refused: connect
        java.net.PlainSocketImpl.socketConnect(Native Metho

d)
    java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
    java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
    java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
    java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
    java.net.Socket.connect(Socket.java:529)
    java.net.Socket.connect(Socket.java:478)
    sun.net.NetworkClient.doConnect(NetworkClient.java:163)
    sun.net.www.http.HttpClient.openServer(HttpClient.java:394)
    sun.net.www.http.HttpClient.openServer(HttpClient.java:529)
    sun.net.www.http.HttpClient.<init>(HttpClient.java:233)
    sun.net.www.http.HttpClient.New(HttpClient.java:306)
    sun.net.www.http.HttpClient.New(HttpClient.java:323)
    sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:860)
    sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:801)
    sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:726)
    sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1049)
    java.net.URL.openStream(URL.java:1010)
    com.liferay.portal.jsonwebservice.JSONWebServiceServlet.service(JSONWebServiceServlet.java:136)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
    com.liferay.portal.kernel.servlet.PortalClassLoaderServlet.service(PortalClassLoaderServlet.java:98)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
    com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
    sun.reflect.GeneratedMethodAccessor218.invoke(Unknown Source)
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    java.lang.reflect.Method.invoke(Method.java:597)
    com.liferay.portal.kernel.bean.ClassLoaderBeanHandler.invoke(ClassLoaderBeanHandler.java:54)
    $Proxy431.doFilter(Unknown Source)
    com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
    com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:121)
    com.liferay.portal.servlet.filters.secure.SecureFilter.processFilter(SecureFilter.java:201)
    com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:48)
    com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
    com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
    com.liferay.portal.kernel.servlet.PortalClassLoaderFilter.doFilter(PortalClassLoaderFilter.java:69)
    com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:203)
    com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:105)
    com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)`
4

2 に答える 2

0

portal-ext.propertiesで次のプロパティを設定します

json.servlet.hosts.allowed=

何か問題があれば教えてください!!

于 2013-07-04T06:37:50.760 に答える