Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-96652

An ExceptionInInitializerError is thrown in case of enabling text.extraction.fork.process.* in portal-ext.properties

    Details

      Description

      An ExceptionInInitializerError is thrown in case of enabling text.extraction.fork.process properties in portal-ext.properties

      Regression caused by LPS-75188

      Steps to reproduce

      1. Before starting Liferay, configure in portal-ext.properties:
        text.extraction.fork.process.enabled=true
        text.extraction.fork.process.mime.types=application/x-tika-ooxml,application/pdf
        
      2. Upload a PDF file to document library
        • Expected behavior: no exception is thrown
        • Wrong behavior: following exception is thrown
          2019-06-10 16:08:21.223 WARN  [liferay/document_library_raw_metadata_processor-1][RawMetadataProcessorMessageListener:38] Unable to save metadata for file version 35939
          com.liferay.portal.kernel.exception.SystemException: java.util.concurrent.ExecutionException: com.liferay.petra.process.ProcessException: java.lang.ExceptionInInitializerError
                  at com.liferay.portal.metadata.TikaRawMetadataProcessor.extractMetadata(TikaRawMetadataProcessor.java:148)
                  at com.liferay.portal.metadata.BaseRawMetadataProcessor.getRawMetadataMap(BaseRawMetadataProcessor.java:71)
                  at com.liferay.portal.kernel.metadata.RawMetadataProcessorUtil.getRawMetadataMap(RawMetadataProcessorUtil.java:40)
                  at com.liferay.portlet.documentlibrary.util.RawMetadataProcessorImpl.saveMetadata(RawMetadataProcessorImpl.java:131)
                  at com.liferay.document.library.kernel.util.RawMetadataProcessorUtil.saveMetadata(RawMetadataProcessorUtil.java:113)
                  at com.liferay.portlet.documentlibrary.messaging.RawMetadataProcessorMessageListener.doReceive(RawMetadataProcessorMessageListener.java:34)
                  at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java:26)
                  at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener.java:74)
                  at com.liferay.portal.kernel.messaging.SerialDestination$1.run(SerialDestination.java:58)
                  at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExecutor.java:752)
                  at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor.java:664)
                  at java.lang.Thread.run(Thread.java:748)
          Caused by: java.util.concurrent.ExecutionException: com.liferay.petra.process.ProcessException: java.lang.ExceptionInInitializerError
                  at java.util.concurrent.FutureTask.report(FutureTask.java:122)
                  at java.util.concurrent.FutureTask.get(FutureTask.java:192)
                  at com.liferay.portal.metadata.TikaRawMetadataProcessor.extractMetadata(TikaRawMetadataProcessor.java:145)
                  ... 11 more
          Caused by: com.liferay.petra.process.ProcessException: java.lang.ExceptionInInitializerError
                  at com.liferay.petra.process.local.LocalProcessLauncher.main(LocalProcessLauncher.java:153)
          Caused by: java.lang.ExceptionInInitializerError
                  at com.liferay.portal.metadata.TikaRawMetadataProcessor$ExtractMetadataProcessCallable.call(TikaRawMetadataProcessor.java:203)
                  at com.liferay.portal.metadata.TikaRawMetadataProcessor$ExtractMetadataProcessCallable.call(TikaRawMetadataProcessor.java:189)
                  at com.liferay.petra.process.local.LocalProcessLauncher.main(LocalProcessLauncher.java:135)
          Caused by: java.lang.NullPointerException: A registry instance was never set
                  at com.liferay.registry.RegistryUtil.getRegistry(RegistryUtil.java:27)
                  at com.liferay.portal.kernel.util.ServiceProxyFactory._openServiceTracker(ServiceProxyFactory.java:192)
                  at com.liferay.portal.kernel.util.ServiceProxyFactory._newServiceTrackedInstance(ServiceProxyFactory.java:171)
                  at com.liferay.portal.kernel.util.ServiceProxyFactory.newServiceTrackedInstance(ServiceProxyFactory.java:85)
                  at com.liferay.portal.kernel.util.ServiceProxyFactory.newServiceTrackedInstance(ServiceProxyFactory.java:50)
                  at com.liferay.portal.metadata.TikaRawMetadataProcessor.<clinit>(TikaRawMetadataProcessor.java:183)
                  ... 3 more
          

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                yvonne.han Yvonne Han
                Reporter:
                jorge.diaz Jorge Diaz
                Participants of an Issue:
                Recent user:
                Jason Pince
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  23 weeks, 2 days ago

                  Packages

                  Version Package
                  7.0.0 DXP FP84
                  7.0.X
                  7.1.10 DXP FP13
                  7.1.X
                  7.2.10 DXP FP1
                  7.2.X
                  7.2.1 CE GA2
                  Master