Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-29614

address "null pointer exception" when ttl has expired

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Won't Do
    • Affects Version/s: ADDONS_10.10
    • Fix Version/s: ADDONS_10.10
    • Component/s: Aspera Connector
    • Tags:
    • Sprint:
      nxApps 2020 Cycle 9

      Description

      currently, we set a ttl for our batch transfers. when we reach the "end" of the ttl, we get null pointer exception results because the batch is removed, but as we are still "working" when we try to get batch info, we get a "null...". One option, is to increase the ttl and also the cpu (longer lives mean more memory hogging potential). This could turn into a performance nightmare once we have many transfers in process in parallel (i.e. production scenarios)

      A more "long-term" solutions would be the following:
      What we have
      One a user (or scheduler for auto) completes the transfer we create a batch with auto generated batch key and we assign it to each worker of each file. And we wait until the worker is processed (if the TTL is expire then we get the error).
      What we can rework
      As the batch key is common for all workers / files of a given transfer. We can use the id of the transfer as the batch key. And we don't create any batch until the one the of the workers start -> one it starts we create the batch -> but we can have a race condition if 4 worker of the same transfers start at the same time -> from what I saw the KVS are threadsafe -> we can try to get a batch of transfer if it's not present we create it and it's the responsibility of the KVS to manage the threadsafe
      to make this modification we need to enable some configuration:
      <?xml version="1.0"?>
      <component name="com.nuxeo.aspera.connector.configuration.test">
      <extension point="configuration" target="org.nuxeo.runtime.ConfigurationService">
      <property name="allowClientGeneratedBatchId">true</property>
      </extension>
      </component>

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: