[Carbon-dev] [jira] Resolved: (CARBON-3262) "UserStoreException: Error modifying the database" error occurs when trying to add a new role in a fresh system
Dimuthu Leelarathne (JIRA)
jira at wso2.org
Sun Feb 22 23:06:05 PST 2009
[ https://wso2.org/jira/browse/CARBON-3262?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Dimuthu Leelarathne resolved CARBON-3262.
-----------------------------------------
Resolution: Fixed
Fixed on the branch and the trunk.
> "UserStoreException: Error modifying the database" error occurs when trying to add a new role in a fresh system
> ---------------------------------------------------------------------------------------------------------------
>
> Key: CARBON-3262
> URL: https://wso2.org/jira/browse/CARBON-3262
> Project: WSO2 Carbon
> Issue Type: Bug
> Components: User Management
> Environment: winxp, jdk15
> Reporter: Charitha Kankanamge
> Assignee: Dimuthu Leelarathne
> Priority: Highest
>
> Following error occurs when trying to add a new role.
> Steps to reproduce:
> ================
> 1. In a fresh system, click on "user management" in the left menu
> 2. Select Roles--> Add new role
> 3. Give a role name and click next
> 4. select few permissions
> 5. In the step 3, search with * and select admin user
> 6. Click on "Finish"
> ERROR - Error modifying the database {org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver}
> org.wso2.carbon.user.mgt.service.UserMgtException: Error modifying the database
> at org.wso2.carbon.user.mgt.service.UserMgtServiceImpl.addRoleToInternalStore(UserMgtServiceImpl.java:140)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at org.apache.axis2.rpc.receivers.RPCUtil.invokeServiceClass(RPCUtil.java:198)
> at org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver.invokeBusinessLogic(RPCInOnlyMessageReceiver.java:63)
> at org.apache.axis2.receivers.AbstractMessageReceiver.receive(AbstractMessageReceiver.java:100)
> at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:176)
> at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:275)
> at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:133)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> at org.eclipse.equinox.http.servlet.internal.ServletRegistration.handleRequest(ServletRegistration.java:90)
> at org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:111)
> at org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:67)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> at org.wso2.carbon.bridge.BridgeServlet.service(BridgeServlet.java:116)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
> at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
> at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
> at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
> at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
> at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
> at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
> at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870)
> at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
> at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
> at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
> at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
> at java.lang.Thread.run(Thread.java:595)
> Caused by: org.wso2.carbon.user.core.UserStoreException: Error modifying the database
> at org.wso2.carbon.user.core.def.DefaultUserStoreAdmin.addRole(DefaultUserStoreAdmin.java:403)
> at org.wso2.carbon.user.mgt.service.UserMgtServiceImpl.addRoleToInternalStore(UserMgtServiceImpl.java:131)
> ... 32 more
> Caused by: java.sql.SQLException: The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or unique index identified by 'SQL090218122306921' defined on 'UM_ROLES'.
> at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
> at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Unknown Source)
> at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(Unknown Source)
> at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Unknown Source)
> at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown Source)
> at org.apache.derby.impl.jdbc.ConnectionChild.handleException(Unknown Source)
> at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(Unknown Source)
> at org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeStatement(Unknown Source)
> at org.apache.derby.impl.jdbc.EmbedPreparedStatement.execute(Unknown Source)
> at org.apache.commons.dbcp.DelegatingPreparedStatement.execute(DelegatingPreparedStatement.java:169)
> at org.wso2.carbon.user.core.def.DefaultUserStoreAdmin.addRole(DefaultUserStoreAdmin.java:398)
> ... 33 more
> Caused by: ERROR 23505: The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or unique index identified by 'SQL090218122306921' defined on 'UM_ROLES'.
> at org.apache.derby.iapi.error.StandardException.newException(Unknown Source)
> at org.apache.derby.impl.sql.execute.IndexChanger.insertAndCheckDups(Unknown Source)
> at org.apache.derby.impl.sql.execute.IndexChanger.doInsert(Unknown Source)
> at org.apache.derby.impl.sql.execute.IndexChanger.insert(Unknown Source)
> at org.apache.derby.impl.sql.execute.IndexSetChanger.insert(Unknown Source)
> at org.apache.derby.impl.sql.execute.RowChangerImpl.insertRow(Unknown Source)
> at org.apache.derby.impl.sql.execute.InsertResultSet.normalInsertCore(Unknown Source)
> at org.apache.derby.impl.sql.execute.InsertResultSet.open(Unknown Source)
> at org.apache.derby.impl.sql.GenericPreparedStatement.execute(Unknown Source)
> ... 38 more
> [2009-02-20 14:03:10,156] ERROR - Error modifying the database {org.apache.axis2.engine.AxisEngine}
> org.apache.axis2.AxisFault: Error modifying the database
> at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430)
> at org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver.invokeBusinessLogic(RPCInOnlyMessageReceiver.java:83)
> at org.apache.axis2.receivers.AbstractMessageReceiver.receive(AbstractMessageReceiver.java:100)
> at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:176)
> at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:275)
> at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:133)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> at org.eclipse.equinox.http.servlet.internal.ServletRegistration.handleRequest(ServletRegistration.java:90)
> at org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:111)
> at org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:67)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> at org.wso2.carbon.bridge.BridgeServlet.service(BridgeServlet.java:116)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
> at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
> at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
> at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
> at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
> at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
> at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
> at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870)
> at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
> at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
> at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
> at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
> at java.lang.Thread.run(Thread.java:595)
> Caused by: org.wso2.carbon.user.mgt.service.UserMgtException: Error modifying the database
> at org.wso2.carbon.user.mgt.service.UserMgtServiceImpl.addRoleToInternalStore(UserMgtServiceImpl.java:140)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at org.apache.axis2.rpc.receivers.RPCUtil.invokeServiceClass(RPCUtil.java:198)
> at org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver.invokeBusinessLogic(RPCInOnlyMessageReceiver.java:63)
> ... 26 more
> Caused by: org.wso2.carbon.user.core.UserStoreException: Error modifying the database
> at org.wso2.carbon.user.core.def.DefaultUserStoreAdmin.addRole(DefaultUserStoreAdmin.java:403)
> at org.wso2.carbon.user.mgt.service.UserMgtServiceImpl.addRoleToInternalStore(UserMgtServiceImpl.java:131)
> ... 32 more
> Caused by: java.sql.SQLException: The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or unique index identified by 'SQL090218122306921' defined on 'UM_ROLES'.
> at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
> at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Unknown Source)
> at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(Unknown Source)
> at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Unknown Source)
> at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown Source)
> at org.apache.derby.impl.jdbc.ConnectionChild.handleException(Unknown Source)
> at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(Unknown Source)
> at org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeStatement(Unknown Source)
> at org.apache.derby.impl.jdbc.EmbedPreparedStatement.execute(Unknown Source)
> at org.apache.commons.dbcp.DelegatingPreparedStatement.execute(DelegatingPreparedStatement.java:169)
> at org.wso2.carbon.user.core.def.DefaultUserStoreAdmin.addRole(DefaultUserStoreAdmin.java:398)
> ... 33 more
> Caused by: ERROR 23505: The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or unique index identified by 'SQL090218122306921' defined on 'UM_ROLES'.
> at org.apache.derby.iapi.error.StandardException.newException(Unknown Source)
> at org.apache.derby.impl.sql.execute.IndexChanger.insertAndCheckDups(Unknown Source)
> at org.apache.derby.impl.sql.execute.IndexChanger.doInsert(Unknown Source)
> at org.apache.derby.impl.sql.execute.IndexChanger.insert(Unknown Source)
> at org.apache.derby.impl.sql.execute.IndexSetChanger.insert(Unknown Source)
> at org.apache.derby.impl.sql.execute.RowChangerImpl.insertRow(Unknown Source)
> at org.apache.derby.impl.sql.execute.InsertResultSet.normalInsertCore(Unknown Source)
> at org.apache.derby.impl.sql.execute.InsertResultSet.open(Unknown Source)
> at org.apache.derby.impl.sql.GenericPreparedStatement.execute(Unknown Source)
> ... 38 more
> [2009-02-20 14:03:10,203] ERROR - org.apache.axis2.AxisFault: Error modifying the database {org.wso2.carbon.user.ui.client.UserMgtClient}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://wso2.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the Carbon-dev
mailing list