You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Pulsar Function jar file extraction fails when functions with large parallelism are created and /tmp is a mounted volume #12645
The fix made in #11343 to fix #11340/#11379 concurrency issues in NarUnpacker doesn't work when /tmp is a mounted volume (in a container). This is due to the fact that docker volumes don't support file locking across containers.
To Reproduce
Similar steps as there are for #11340/#11379 with the difference that /tmp/pulsar-nar is a mounted directory.
Expected behavior
It should be possible to configure Pulsar Functions to use another file locking solution that doesn't require operating system level file locking functionality. Alternatively it should be possible to configure the function instance to use a unique directory for the function instance instead of using the shared /tmp/pulsar-nar directory.
The extraction directory cannot be unique for each extraction since that would cause the disk space usage to grow when functions get started/restarted.
Error message
ERROR org.apache.pulsar.common.nar.NarUnpacker - There was a problem extracting the nar file. Deleting /tmp/pulsar-nar/functions.jar-unpacked/Zii1vei7Ohhaishu_Bohc6kaesaechoofeishaiN8 to clean up state.
java.io.FileNotFoundException: /tmp/pulsar-nar/functions.jar-unpacked/Zii1vei7Ohhaishu_Bohc6kaesaechoofeishaiN8/META-INF/MANIFEST.MF (No such file or directory)
at java.io.FileOutputStream.open0(Native Method) ~[?:?]
at java.io.FileOutputStream.open(FileOutputStream.java:298) ~[?:?]
at java.io.FileOutputStream.<init>(FileOutputStream.java:237) ~[?:?]
at java.io.FileOutputStream.<init>(FileOutputStream.java:187) ~[?:?]
at org.apache.pulsar.common.nar.NarUnpacker.makeFile(NarUnpacker.java:144) ~[java-instance.jar:?]
at org.apache.pulsar.common.nar.NarUnpacker.unpack(NarUnpacker.java:127) ~[java-instance.jar:?]
at org.apache.pulsar.common.nar.NarUnpacker.doUnpackNar(NarUnpacker.java:96) ~[java-instance.jar:?]
at org.apache.pulsar.common.nar.NarUnpacker.unpackNar(NarUnpacker.java:65) ~[java-instance.jar:?]
at org.apache.pulsar.common.nar.NarClassLoader.getFromArchive(NarClassLoader.java:153) ~[java-instance.jar:?]
Activity
eolivelli commentedon Nov 8, 2021
@lhotari I have posted a PR for branch-2.7
#12665
I will send a new PR for master/branch-2.8/branch-2.9, the code was moved
eolivelli commentedon Nov 8, 2021
@lhotari
please close this issue if you think that my explanation is reasonable
lhotari commentedon Nov 8, 2021
Closed this issue, since it wasn't a problem with the lock file.