2 Replies Latest reply on Apr 16, 2013 8:48 AM by torte

    Failed to delete RHQ User

    torte Newbie

      Hello All,

       

      i got an user which i can't delete in rhq. Login "was" working over LDAP. The user is not in the LDAP anymore but still in the RHQ.

       

      When i try to delete that user I receive the following error message. It seams there are existing things from this user which are

       

      avoid to delete that user. Another Question: What will happen if i delete the user directly in the database? Thank you in advance

       

      for any attention, information and help.

       

      Regards, Torte

       

      Message :

      Failed to delete user Mr.XXXXXXX

      Severity :

      Error

      Time :

      Tuesday, April 16, 2013 11:33:41 AM UTC+2

      Detail :
      java.lang.RuntimeException:[1366104821504] java.lang.RuntimeException:javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state -> javax.transaction.RollbackException:[com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state -> javax.persistence.EntityExistsException:org.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch update -> org.hibernate.exception.ConstraintViolationException:Could not execute JDBC batch update -> java.sql.BatchUpdateException:Batch entry 0 delete from RHQ_SUBJECT where ID='10121' was aborted.  Call getNextException to see the cause.[SQLException=Batch entry 0 delete from RHQ_SUBJECT where ID='10121' was aborted.  Call getNextException to see the cause. -> ERROR: update or delete on table "rhq_subject" violates foreign key constraint "rhq_saved_search_subject_id_fkey" on table "rhq_saved_search" Detail: Key (id)=(10121) is still referenced from table "rhq_saved_search".(error-code=0,sql-state=23503)]
      --- STACK TRACE FOLLOWS ---
      [1366104821504] java.lang.RuntimeException:javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state -> javax.transaction.RollbackException:[com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state -> javax.persistence.EntityExistsException:org.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch update -> org.hibernate.exception.ConstraintViolationException:Could not execute JDBC batch update -> java.sql.BatchUpdateException:Batch entry 0 delete from RHQ_SUBJECT where ID='10121' was aborted.  Call getNextException to see the cause.[SQLException=Batch entry 0 delete from RHQ_SUBJECT where ID='10121' was aborted.  Call getNextException to see the cause. -> ERROR: update or delete on table "rhq_subject" violates foreign key constraint "rhq_saved_search_subject_id_fkey" on table "rhq_saved_search" Detail: Key (id)=(10121) is still referenced from table "rhq_saved_search".(error-code=0,sql-state=23503)]
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)
         at Unknown.anonymous(Unknown Source)