Uploaded image for project: 'AppFormer'
  1. AppFormer
  2. AF-2254

Throwing NPE from IOServiceIndexedImpl

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Minor Minor
    • None
    • None
    • VFS
    • None
    • 2020 Week 19-21 (from May 4), 2020 Week 22-24 (from May 25)
    • NEW
    • NEW

      While testing the new nio2 implementation, encountered the following NPE.

      15:56:04,650 ERROR [stderr] (Thread-125) Exception in thread "Thread-125" java.lang.NullPointerException
      15:56:04,650 ERROR [stderr] (Thread-125) 	at org.uberfire.ext.metadata.io.IOServiceIndexedImpl$1$1.getRealCreatedPaths(IOServiceIndexedImpl.java:409)
      15:56:04,650 ERROR [stderr] (Thread-125) 	at org.uberfire.ext.metadata.io.IOServiceIndexedImpl$1$1.lambda$run$0(IOServiceIndexedImpl.java:315)
      15:56:04,651 ERROR [stderr] (Thread-125) 	at java.lang.Iterable.forEach(Iterable.java:75)
      15:56:04,651 ERROR [stderr] (Thread-125) 	at org.uberfire.ext.metadata.io.IOServiceIndexedImpl$1$1.run(IOServiceIndexedImpl.java:312)
      15:56:04,651 ERROR [stderr] (Thread-125) 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      15:56:04,651 ERROR [stderr] (Thread-125) 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      15:56:04,651 ERROR [stderr] (Thread-125) 	at java.lang.Thread.run(Thread.java:748)
      
      

      It may related to this line of code:
      https://github.com/kiegroup/appformer/blob/92d05f8620fb775a9fdd96574273de2deda3d215/uberfire-extensions/uberfire-metadata/uberfire-metadata-commons-io/src/main/java/org/uberfire/ext/metadata/io/IOServiceIndexedImpl.java#L467

      Since the method, 'getFileName', will return null for root path.

              aparedes@redhat.com Adriel Paredes
              evan.zhang@redhat.com Evan Zhang (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: