我已经设置了2个worklight自由服务器('worklight'和'customer') - 我已经在server.xml中将端口从9080更改为9081,用于客户服务器和在两种环境中安装的运行时。
每个服务器在创建时都具有唯一的模式以及唯一的上下文路径
我的问题是,我可以看到我的运行时工作在worklight服务器控制台中,但是当我访问客户控制台时,我得到'找不到运行时。'错误消息
还需要配置哪些才能实现此功能?
messages.log:
[11/25/14 15:49:46:087 GMT] 0000001d com.worklight.server.bundle.project.JeeProjectActivator I FWLST0002I: ========= Project /customerproject started. The project WAR file version is 6.2.0.00.20140613-0730,running on server version 6.2.0.00.20140613-0730. [project customerproject]
[11/25/14 15:49:46:087 GMT] 0000001d SystemOut O ================ End init of customerproject 18517
[11/25/14 15:49:46:181 GMT] 0000001d org.apache.wink.server.internal.servlet.RestServlet I The system is using the com.worklight.oauth.AuthorizationServerApplication JAX-RS application class that is named in the javax.ws.rs.Application init-param initialization parameter.
[11/25/14 15:49:46:321 GMT] 0000001a com.worklight.common.util.jmx.LibertyJMXRegister I FWLSE2008I: MBean registration succeeded for: com.worklight.common.server.jmx.api:type=ProjectManagement_customer,qualifier=advancedproject2 [project advancedproject2]
[11/25/14 15:49:46:337 GMT] 0000001a SystemOut O Cleanup dir is C:\IBMX64\WebSphere\Liberty\usr\servers\customer\workarea\org.eclipse.osgi\bundles\79\data\temp\default_node\SMF_WebContainer\advancedproject2\advancedproject\widget-resources
[11/25/14 15:49:46:352 GMT] 0000001d apache.wink.server.internal.application.ApplicationProcessor I The following JAX-RS application has been processed: com.worklight.oauth.AuthorizationServerApplication
[11/25/14 15:49:46:368 GMT] 0000001d org.apache.wink.server.internal.log.Resources I The server has registered the JAX-RS resource class com.worklight.oauth.TokenValidationEndpoint with @Path(/validation).
[11/25/14 15:49:46:368 GMT] 0000001d org.apache.wink.server.internal.log.Resources I The server has registered the JAX-RS resource class com.worklight.oauth.TokenEndpoint with @Path(/token).
[11/25/14 15:49:46:368 GMT] 0000001d org.apache.wink.server.internal.log.Providers I There are no custom JAX-RS providers defined in the application.
[11/25/14 15:49:46:383 GMT] 0000001a com.worklight.common.util.jmx.RuntimeMBeanHandler W Impossible to decode the password
[11/25/14 15:49:46:415 GMT] 0000001a com.worklight.server.bundle.project.JeeProjectActivator I FWLST0002I: ========= Project /advancedproject2 started. The project WAR file version is 6.2.0.00.20140613-0730,running on server version 6.2.0.00.20140613-0730. [project advancedproject2]
[11/25/14 15:49:46:415 GMT] 0000001a SystemOut O ================ End init of advancedproject2 16599
[11/25/14 15:49:46:555 GMT] 0000001a org.apache.wink.server.internal.servlet.RestServlet I The system is using the com.worklight.oauth.AuthorizationServerApplication JAX-RS application class that is named in the javax.ws.rs.Application init-param initialization parameter.
[11/25/14 15:49:46:805 GMT] 0000001d com.ibm.ws.webcontainer.servlet I SRVE0242I: [customerproject] [/customerproject] [AuthorizationServer]: Initialization successful.
[11/25/14 15:49:46:805 GMT] 0000001d com.ibm.ws.app.manager.AppMessageHelper A CWWKZ0001I: Application customerproject started in 26.351 seconds.
[11/25/14 15:49:46:898 GMT] 0000001a apache.wink.server.internal.application.ApplicationProcessor I The following JAX-RS application has been processed: com.worklight.oauth.AuthorizationServerApplication
[11/25/14 15:49:46:976 GMT] 0000001a org.apache.wink.server.internal.log.Resources I The server has registered the JAX-RS resource class com.worklight.oauth.TokenValidationEndpoint with @Path(/validation).
[11/25/14 15:49:46:976 GMT] 0000001a org.apache.wink.server.internal.log.Resources I The server has registered the JAX-RS resource class com.worklight.oauth.TokenEndpoint with @Path(/token).
[11/25/14 15:49:46:976 GMT] 0000001a org.apache.wink.server.internal.log.Providers I There are no custom JAX-RS providers defined in the application.
[11/25/14 15:49:47:319 GMT] 0000001a com.ibm.ws.webcontainer.servlet I SRVE0242I: [advancedproject2] [/advancedproject2] [AuthorizationServer]: Initialization successful.
[11/25/14 15:49:47:335 GMT] 0000001a com.ibm.ws.app.manager.AppMessageHelper A CWWKZ0001I: Application advancedproject2 started in 26.881 seconds.
[11/25/14 15:49:47:382 GMT] 00000016 com.ibm.ws.kernel.feature.internal.FeatureManager I CWWKF0008I: Feature update completed in 31.270 seconds.
[11/25/14 15:49:47:382 GMT] 00000016 com.ibm.ws.kernel.feature.internal.FeatureManager A CWWKF0011I: The server customer is ready to run a smarter planet.
[11/25/14 15:49:57:159 GMT] 0000001d com.ibm.worklight.dataaccess.datastore.DataStoreUtil I getWorklightDataSourceProperties Read properties file. allProperties: {ibm.worklight.admin.db.jndi.name=java:comp/env/jdbc/WorklightAdminDS}
[11/25/14 15:49:57:159 GMT] 0000001d com.ibm.worklight.dataaccess.datastore.DataStoreUtil I dereferenceProperties Handling propName=ibm.worklight.admin.db.jndi.name propValue=java:comp/env/jdbc/WorklightAdminDS
[11/25/14 15:49:57:159 GMT] 0000001d com.ibm.worklight.dataaccess.datastore.DataStoreUtil I dereferenceProperties Handling propName=ibm.worklight.admin.db.openjpa.Log propValue=
[11/25/14 15:49:57:159 GMT] 0000001d com.ibm.worklight.dataaccess.datastore.DataStoreUtil I dereferenceProperties Handling propName=ibm.worklight.admin.db.type propValue=
[11/25/14 15:49:57:159 GMT] 0000001d com.ibm.worklight.dataaccess.datastore.DataStore I constructor Creating EntityManagerFactory for persistence-unit=WorklightManagementPU-db2 with properties: {openjpa.ConnectionFactory=com.ibm.ws.rsadapter.jdbc.WSJdbcDataSource@5aaacacc}
[11/25/14 15:49:57:299 GMT] 0000001d SystemErr R 31 WorklightManagementPU-db2 INFO [Default Executor-thread-4] openjpa.Runtime - Starting OpenJPA 1.2.2
[11/25/14 15:49:57:315 GMT] 0000001d SystemErr R 47 WorklightManagementPU-db2 INFO [Default Executor-thread-4] openjpa.jdbc.JDBC - Using dictionary class "org.apache.openjpa.jdbc.sql.DB2Dictionary" (DB2/NT64 SQL10010 ,IBM Data Server Driver for JDBC and SQLJ 4.13.127).
[11/25/14 15:49:57:455 GMT] 0000001d com.worklight.common.util.jmx.RuntimeMBeanHandler W Impossible to decode the password
[11/25/14 15:49:57:486 GMT] 0000001d com.ibm.worklight.admin.services.RuntimeService E Failed to obtain JMX connection to access an MBean.
There might be a JMX configuration error: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
[11/25/14 15:49:57:720 GMT] 0000001d com.ibm.worklight.admin.services.RuntimeService W No running mxbeans found
[11/25/14 15:51:47:024 GMT] 00000032 SystemErr R Exception in thread "Thread-23"
[11/25/14 15:51:47:024 GMT] 00000032 SystemErr R java.lang.RuntimeException: Timeout while waiting for the management service to start up
[11/25/14 15:51:47:024 GMT] 00000032 SystemErr R at com.worklight.core.init.WorklightServletInitializer$1.run(WorklightServletInitializer.java:133)
[11/25/14 15:51:47:024 GMT] 00000032 SystemErr R at java.lang.Thread.run(Thread.java:745)
[11/25/14 15:51:47:227 GMT] 00000034 SystemErr R Exception in thread "Thread-25"
[11/25/14 15:51:47:227 GMT] 00000034 SystemErr R java.lang.RuntimeException: Timeout while waiting for the management service to start up
[11/25/14 15:51:47:227 GMT] 00000034 SystemErr R at com.worklight.core.init.WorklightServletInitializer$1.run(WorklightServletInitializer.java:133)
[11/25/14 15:51:47:227 GMT] 00000034 SystemErr R at java.lang.Thread.run(Thread.java:745)
CONSOLE.LOG:
[AUDIT ] CWWKZ0001I: Application customerproject started in 26.351 seconds.
[AUDIT ] CWWKZ0001I: Application advancedproject2 started in 26.881 seconds.
[AUDIT ] CWWKF0011I: The server customer is ready to run a smarter planet.
[err] 31 WorklightManagementPU-db2 INFO [Default Executor-thread-4] openjpa.Runtime - Starting OpenJPA 1.2.2
[err] 47 WorklightManagementPU-db2 INFO [Default Executor-thread-4] openjpa.jdbc.JDBC - Using dictionary class "org.apache.openjpa.jdbc.sql.DB2Dictionary" (DB2/NT64 SQL10010 ,IBM Data Server Driver for JDBC and SQLJ 4.13.127).
[WARNING ] Impossible to decode the password
[ERROR ] Failed to obtain JMX connection to access an MBean.
There might be a JMX configuration error: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
[WARNING ] No running mxbeans found
[err] Exception in thread "Thread-23"
[err] java.lang.RuntimeException: Timeout while waiting for the management service to start up
[err] at com.worklight.core.init.WorklightServletInitializer$1.run(WorklightServletInitializer.java:133)
[err] at java.lang.Thread.run(Thread.java:745)
[err] Exception in thread "Thread-25"
[err] java.lang.RuntimeException: Timeout while waiting for the management service to start up
[err] at com.worklight.core.init.WorklightServletInitializer$1.run(WorklightServletInitializer.java:133)
[err] at java.lang.Thread.run(Thread.java:745)
服务器'customer'的管理服务器设置:
<!-- Declare the Worklight Administration Service application. -->
<application id="customerwladmin" name="customerwladmin" location="worklightadmin.war" type="war">
<application-bnd>
<security-role name="worklightadmin">
<user name="demo"/>
</security-role>
<security-role name="worklightdeployer">
</security-role>
<security-role name="worklightmonitor">
</security-role>
<security-role name="worklightoperator">
</security-role>
</application-bnd>
<classloader delegation="parentLast">
<commonLibrary>
<fileset dir="${wlp.install.dir}/lib" includes="com.ibm.ws.crypto.passwordutil_1.0.4.jar"/>
</commonLibrary>
</classloader>
</application>
服务器'worklight'的管理服务设置
<!-- Declare the Worklight Administration Service application. -->
<application id="wladmin" name="wladmin" location="worklightadmin.war" type="war">
<application-bnd>
<security-role name="worklightadmin">
<user name="demo"/>
</security-role>
<security-role name="worklightdeployer">
</security-role>
<security-role name="worklightmonitor">
</security-role>
<security-role name="worklightoperator">
</security-role>
</application-bnd>
<classloader delegation="parentLast">
<commonLibrary>
<fileset dir="${wlp.install.dir}/lib" includes="com.ibm.ws.crypto.passwordutil_1.0.4.jar"/>
</commonLibrary>
</classloader>
</application>
答案 0 :(得分:1)
有以下例外: sun.security.validator.ValidatorException:PKIX路径构建失败:sun.security.provider.certpath.SunCertPathBuilderException:无法找到所请求目标的有效证书路径
表示证书存在SSL配置问题。
答案 1 :(得分:0)
可能与以下问题重复:No MBean found for worklight project
在那里,问题是server.xml中的设置不正确;您可以按照说明验证您没有遇到同样的问题。
使用日志(在评论部分中请求),很难确定问题,所以这里有更多问题处理相同的错误: