Uploaded image for project: 'Dev - Nexus Repo'
  1. Dev - Nexus Repo
  2. NEXUS-20295

Error on deserialization of Serializable DB name="security"

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Parked
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Scripting, Security
    • Labels:
      None

      Description

      Hello,

       

          I write some script in Groovy to create repositories, privileges and roles.

      When I create roles with privileges, there is no problem during script execution.

      But, when I access to roles in Nexus Interface, I did not see created roles and I got this error in nexus.log : Error on deserialization of Serializable DB name="security"

      More information in attachment.

       

      About the Groovy script, this is an extract :

      def app="test"
      def repoList = ['test.snapshots','test.releases','test.thirdparty']
      def roleTypes = ['Readers','Developers']
      
      roleTypes.each(){ roleType ->
      	
      	def roleId = "${app}.${roleType}".tr('A-Z_', 'a-z-') // [test.readers|test.developers]
      	def rolePrivileges = repoList.collect{"nx-repository-view-maven2-${it}-browse"}
      	
      	log.info("Create role '${roleId}'...")
      	security.addRole(roleId,"${app} ${roleType}", "${app} ${roleType}", rolePrivileges, [])	
      	log.info("Role '${roleId}' created with success")
      }
      

      I noticed that if rolePrivileges are hard values, there is no problem.

      Thank you for you help

       

      Regards,

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              PICSIT Nadia GUERROUANI
              Last Updated By:
              Rich Seddon Rich Seddon
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Date of First Response:

                  tigCommentSecurity.panel-title