WSO2-IS 5.11.0 - 拦截 HTTP 请求时 CORS 管理服务错误 - MySQL DB
WSO2-IS 5.11.0 - CORS management service error when intercepting an HTTP request - MySQL DB
我正在尝试访问 WSO2 身份服务器的 carbon 登录页面,但在 deployment.toml 中更改默认数据库时收到错误消息。如果我使用 h2 内部数据库,一切正常,但如果我更改为在 docker 环境中使用 mysql 数据库 运行,则会出现错误。
这个有效:
[database.identity_db]
type = "h2"
url = "jdbc:h2:./repository/database/WSO2IDENTITY_DB;DB_CLOSE_ON_EXIT=FALSE;LOCK_TIMEOUT=60000"
username = "wso2carbon"
password = "wso2carbon"
这行不通
[database.identity_db]
type = "mysql"
url = "jdbc:mysql://csm-wso2-mysqldb:3306/WSO2_IDENTITY_DB?autoReconnect=true&useSSL=false"
username = "regadmin"
password = "regadmin"
driver = "com.mysql.cj.jdbc.Driver"
csm-wso2-mysqldb是一个docker容器名
错误:
csm-wso2-is | [2021-08-28 17:54:15,197] [1deadc88-3363-427e-b238-89a418231406] ERROR {org.wso2.carbon.identity.cors.valve.CORSValve} -
CORS management service error when intercepting an HTTP request. org.wso2.carbon.identity.cors.mgt.core.exception.CORSManagementServiceServerException: CMS-65006
csm-wso2-is | at org.wso2.carbon.identity.cors.service.internal.impl.CORSManagerImpl.getCORSConfiguration(CORSManagerImpl.java:101)
csm-wso2-is | at org.wso2.carbon.identity.cors.valve.CORSValve.invoke(CORSValve.java:81)
csm-wso2-is | at org.wso2.carbon.identity.authz.valve.AuthorizationValve.invoke(AuthorizationValve.java:110)
csm-wso2-is | at org.wso2.carbon.identity.auth.valve.AuthenticationValve.invoke(AuthenticationValve.java:102)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.CompositeValve.continueInvocation(CompositeValve.java:99)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.TomcatValveContainer.invokeValves(TomcatValveContainer.java:49)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.CompositeValve.invoke(CompositeValve.java:62)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.CarbonStuckThreadDetectionValve.invoke(CarbonStuckThreadDetectionValve.java:145)
csm-wso2-is | at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:690)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.CarbonContextCreatorValve.invoke(CarbonContextCreatorValve.java:57)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.RequestEncodingValve.invoke(RequestEncodingValve.java:49)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.RequestCorrelationIdValve.invoke(RequestCorrelationIdValve.java:126)
csm-wso2-is | at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
csm-wso2-is | at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
csm-wso2-is | at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:373)
csm-wso2-is | at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
csm-wso2-is | at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868)
csm-wso2-is | at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1590)
csm-wso2-is | at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
csm-wso2-is | at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
csm-wso2-is | at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
csm-wso2-is | at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
csm-wso2-is | at java.base/java.lang.Thread.run(Thread.java:834)
csm-wso2-is | Caused by: org.wso2.carbon.identity.cors.mgt.core.exception.CORSManagementServiceServerException: CMS-65006
csm-wso2-is | at org.wso2.carbon.identity.cors.mgt.core.internal.util.ErrorUtils.handleServerException(ErrorUtils.java:56)
csm-wso2-is | at org.wso2.carbon.identity.cors.mgt.core.dao.impl.CORSConfigurationDAOImpl.getCORSConfigurationByTenantDomain(CORSConfigurationDAOImpl.java:76)
csm-wso2-is | at org.wso2.carbon.identity.cors.service.internal.impl.CORSManagerImpl.getCORSConfiguration(CORSManagerImpl.java:93)
csm-wso2-is | ... 22 more
csm-wso2-is | Caused by: org.wso2.carbon.identity.configuration.mgt.core.exception.ConfigurationManagementClientException: Configuration management feature is not enabled.
csm-wso2-is | at org.wso2.carbon.identity.configuration.mgt.core.ConfigurationManagerImpl.checkFeatureStatus(ConfigurationManagerImpl.java:809)
csm-wso2-is | at org.wso2.carbon.identity.configuration.mgt.core.ConfigurationManagerImpl.getResource(ConfigurationManagerImpl.java:194)
csm-wso2-is | at org.wso2.carbon.identity.cors.mgt.core.dao.impl.CORSConfigurationDAOImpl.getResource(CORSConfigurationDAOImpl.java:123)
csm-wso2-is | at org.wso2.carbon.identity.cors.mgt.core.dao.impl.CORSConfigurationDAOImpl.getCORSConfigurationByTenantDomain(CORSConfigurationDAOImpl.java:67)
我做错了什么?我检查了 table 和用户是否存在。
我使用的是旧版本的数据库脚本。 WSO2-IS 5.11.0 需要 IDN_CONFIG_TYPE、IDN_CONFIG_RESOURCE、IDN_CONFIG_ATTRIBUTE 和 IDN_CONFIG_FILE 表。
我正在尝试访问 WSO2 身份服务器的 carbon 登录页面,但在 deployment.toml 中更改默认数据库时收到错误消息。如果我使用 h2 内部数据库,一切正常,但如果我更改为在 docker 环境中使用 mysql 数据库 运行,则会出现错误。
这个有效:
[database.identity_db]
type = "h2"
url = "jdbc:h2:./repository/database/WSO2IDENTITY_DB;DB_CLOSE_ON_EXIT=FALSE;LOCK_TIMEOUT=60000"
username = "wso2carbon"
password = "wso2carbon"
这行不通
[database.identity_db]
type = "mysql"
url = "jdbc:mysql://csm-wso2-mysqldb:3306/WSO2_IDENTITY_DB?autoReconnect=true&useSSL=false"
username = "regadmin"
password = "regadmin"
driver = "com.mysql.cj.jdbc.Driver"
csm-wso2-mysqldb是一个docker容器名
错误:
csm-wso2-is | [2021-08-28 17:54:15,197] [1deadc88-3363-427e-b238-89a418231406] ERROR {org.wso2.carbon.identity.cors.valve.CORSValve} -
CORS management service error when intercepting an HTTP request. org.wso2.carbon.identity.cors.mgt.core.exception.CORSManagementServiceServerException: CMS-65006
csm-wso2-is | at org.wso2.carbon.identity.cors.service.internal.impl.CORSManagerImpl.getCORSConfiguration(CORSManagerImpl.java:101)
csm-wso2-is | at org.wso2.carbon.identity.cors.valve.CORSValve.invoke(CORSValve.java:81)
csm-wso2-is | at org.wso2.carbon.identity.authz.valve.AuthorizationValve.invoke(AuthorizationValve.java:110)
csm-wso2-is | at org.wso2.carbon.identity.auth.valve.AuthenticationValve.invoke(AuthenticationValve.java:102)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.CompositeValve.continueInvocation(CompositeValve.java:99)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.TomcatValveContainer.invokeValves(TomcatValveContainer.java:49)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.CompositeValve.invoke(CompositeValve.java:62)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.CarbonStuckThreadDetectionValve.invoke(CarbonStuckThreadDetectionValve.java:145)
csm-wso2-is | at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:690)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.CarbonContextCreatorValve.invoke(CarbonContextCreatorValve.java:57)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.RequestEncodingValve.invoke(RequestEncodingValve.java:49)
csm-wso2-is | at org.wso2.carbon.tomcat.ext.valves.RequestCorrelationIdValve.invoke(RequestCorrelationIdValve.java:126)
csm-wso2-is | at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
csm-wso2-is | at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
csm-wso2-is | at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:373)
csm-wso2-is | at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
csm-wso2-is | at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868)
csm-wso2-is | at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1590)
csm-wso2-is | at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
csm-wso2-is | at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
csm-wso2-is | at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
csm-wso2-is | at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
csm-wso2-is | at java.base/java.lang.Thread.run(Thread.java:834)
csm-wso2-is | Caused by: org.wso2.carbon.identity.cors.mgt.core.exception.CORSManagementServiceServerException: CMS-65006
csm-wso2-is | at org.wso2.carbon.identity.cors.mgt.core.internal.util.ErrorUtils.handleServerException(ErrorUtils.java:56)
csm-wso2-is | at org.wso2.carbon.identity.cors.mgt.core.dao.impl.CORSConfigurationDAOImpl.getCORSConfigurationByTenantDomain(CORSConfigurationDAOImpl.java:76)
csm-wso2-is | at org.wso2.carbon.identity.cors.service.internal.impl.CORSManagerImpl.getCORSConfiguration(CORSManagerImpl.java:93)
csm-wso2-is | ... 22 more
csm-wso2-is | Caused by: org.wso2.carbon.identity.configuration.mgt.core.exception.ConfigurationManagementClientException: Configuration management feature is not enabled.
csm-wso2-is | at org.wso2.carbon.identity.configuration.mgt.core.ConfigurationManagerImpl.checkFeatureStatus(ConfigurationManagerImpl.java:809)
csm-wso2-is | at org.wso2.carbon.identity.configuration.mgt.core.ConfigurationManagerImpl.getResource(ConfigurationManagerImpl.java:194)
csm-wso2-is | at org.wso2.carbon.identity.cors.mgt.core.dao.impl.CORSConfigurationDAOImpl.getResource(CORSConfigurationDAOImpl.java:123)
csm-wso2-is | at org.wso2.carbon.identity.cors.mgt.core.dao.impl.CORSConfigurationDAOImpl.getCORSConfigurationByTenantDomain(CORSConfigurationDAOImpl.java:67)
我做错了什么?我检查了 table 和用户是否存在。
我使用的是旧版本的数据库脚本。 WSO2-IS 5.11.0 需要 IDN_CONFIG_TYPE、IDN_CONFIG_RESOURCE、IDN_CONFIG_ATTRIBUTE 和 IDN_CONFIG_FILE 表。