Uploaded image for project: 'Jira Service Management Data Center'
  1. Jira Service Management Data Center
  2. JSDSERVER-16066

The creation or editing of assets objects fails due to a NullPointerException.

XMLWordPrintable

      Issue Summary

      Assets have a limit on the number of object attributes set to the Java integer limit of 2,147,483,647. When the number of object attributes exceeds this limit, the code will fail with a Null Pointer Exception (NPE) when new objects are created or when additional attributes are added to existing objects.

      Steps to Reproduce

      A straightforward method to replicate this issue is to check the maximum ID in the AO_8542F1_IFJ_OBJ_ATTR table or the sequence AO_8542F1_IFJ_OBJ_ATTR_ID_seq, ensuring it exceeds the value of 2,147,483,647.

      Expected Results

      Asset object creation, editing, and deletion should function without encountering any NullPointerException.

      Actual Results

      The below exception is thrown in the Atlassian-jira.log file:

      2025-02-19 08:40:07,027+0000 http-nio-8080-exec-61 WARN  /rest/insight/1.0/object/create \[c.r.j.p.i.services.core.ObjectServiceImpl] Failed to create object Test (null)
      java.lang.NullPointerException
      at com.riadalabs.jira.plugins.insight.services.core.dal.impl.ObjectAttributeDalImpl.addObjectAttributeValue(ObjectAttributeDalImpl.java:360)
      at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195)
      at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:177)
      at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1655)
      at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
      at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
      at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:913)
      at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
      at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:578)
      at com.riadalabs.jira.plugins.insight.services.core.dal.impl.ObjectAttributeDalImpl.handleValueBeans(ObjectAttributeDalImpl.java:316)
      at com.riadalabs.jira.plugins.insight.services.core.dal.impl.ObjectAttributeDalImpl.storeValueToAttribute(ObjectAttributeDalImpl.java:254)
      at com.riadalabs.jira.plugins.insight.services.core.dal.impl.ObjectAttributeDalImpl.lambda$bulkChangeAttributeValues$11(ObjectAttributeDalImpl.java:660)
      at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195)
      at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195)
      at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1655)
      at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
      at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474 

      Workaround

      Required, if there is no workaround please state:
      Currently there is no known workaround for this behavior. A workaround will be added here when available

      Versions Tested

      Please confirm all versions that have been tested for this issue, and indicate whether the tested version is affected or not affected, below: 

      Testing Requirements Version Affected Version
      Customers Reported Version Example: 9.14.2 (Yes / No)
      Most Recent Bug-Fix Release    
      Previous Major Release    
      Most Recent LTS    
      Previous Supported LTS    
      Other Versions..    
      (Add rows as needed)    

              c8bcca445054 Benjamin Suess
              90afaff088e0 Navneeth S
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: