Describe the bug
Deploying my funqy lamda function in jvm works perfectly fine.
After cleaning and building new with mvn package -Pnative -Dquarkus.native.container-build=true and deploying with ./manage.sh native create the functions times out https://i.imgur.com/JVfUfIy.png
Expected behavior
Maybe any response? :)
Actual behavior
Not getting any response :(
To Reproduce
https://github.com/EzxD/Quarkus-Funqy-Native-Example
Steps to reproduce the behavior:
Configuration
quarkus.hibernate-orm.database.generation=drop-and-create
quarkus.funqy.export=helloWorld.
Screenshots
https://i.imgur.com/JVfUfIy.png
Environment (please complete the following information):
uname -a or ver: Linux Pauls-PC 4.19.128-microsoft-standard #1 SMP Tue Jun 23 12:58:10 UTC 2020 x86_64 x86_64 x86_64 GNU/Linuxjava -version: mvnw --version or gradlew --version): Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)/cc @Sanne, @gsmet, @matejvasek, @patriot1burke
@EzxD Could you please try adding some input pram for the helloWorld function? I have suspicion there is an issue when function takes no input.
I think that this is caused by this code:
https://github.com/quarkusio/quarkus/commit/4e2502bee17e21b8870592abedd4bcad95301426#diff-b0bcdc4c5807481b0e5fc7652e0ea523623924d6e2acfc0f555deb1a001082d3R66-R70
I think that this is caused by this code:
[4e2502b#diff-b0bcdc4c5807481b0e5fc7652e0ea523623924d6e2acfc0f555deb1a001082d3R66-R70]
(https://github.com/quarkusio/quarkus/commit/4e2502bee17e21b8870592abedd4bcad95301426#diff-b0bcdc4c5807481b0e5fc7652e0ea523623924d6e2acfc0f555deb1a001082d3R66-R70)
Doesn't this only apply for JVM based artifacts?
Even using the native image with the createUser method the function is timing out
https://i.imgur.com/0jwlhOc.png
I am even getting a timeout using following application.properties
quarkus.datasource.db-kind=h2
quarkus.datasource.jdbc.url=jdbc:h2:tcp://localhost/mem:test
quarkus.hibernate-orm.log.sql=true
quarkus.hibernate-orm.database.generation=drop-and-create
quarkus.funqy.export=createUser
https://i.imgur.com/3qORuUv.png
thats the output of the CloudWatchLogs
Error loading class io.quarkus.funqy.lambda.FunqyStreamHandler: Metaspace: java.lang.OutOfMemoryError
java.lang.OutOfMemoryError: Metaspace
Exception in thread "main" java.lang.Error: java.lang.OutOfMemoryError: Metaspace
at lambdainternal.AWSLambda.startRuntime(AWSLambda.java:194)
at lambdainternal.AWSLambda.main(AWSLambda.java:187)
Caused by: java.lang.OutOfMemoryError: Metaspace
Exception in thread "Thread-4" java.lang.OutOfMemoryError: Metaspace
START RequestId: 89061110-0c92-4c14-b1df-a0fa705e7b6a Version: $LATEST
END RequestId: 89061110-0c92-4c14-b1df-a0fa705e7b6a
REPORT RequestId: 89061110-0c92-4c14-b1df-a0fa705e7b6a Duration: 15003.09 ms Billed Duration: 15000 ms Memory Size: 256 MB Max Memory Used: 53 MB
2020-12-01T20:36:54.853Z 89061110-0c92-4c14-b1df-a0fa705e7b6a Task timed out after 15.00 seconds
Error loading class io.quarkus.funqy.lambda.FunqyStreamHandler: Metaspace: java.lang.OutOfMemoryError
java.lang.OutOfMemoryError: Metaspace
Exception in thread "main" java.lang.Error: java.lang.OutOfMemoryError: Metaspace
at lambdainternal.AWSLambda.startRuntime(AWSLambda.java:194)
at lambdainternal.AWSLambda.main(AWSLambda.java:187)
Caused by: java.lang.OutOfMemoryError: Metaspace
Exception in thread "Thread-4" java.lang.OutOfMemoryError: Metaspace
START RequestId: 4ccc99b9-f98b-43ea-9b7a-2e052d7f2ac8 Version: $LATEST
END RequestId: 4ccc99b9-f98b-43ea-9b7a-2e052d7f2ac8
REPORT RequestId: 4ccc99b9-f98b-43ea-9b7a-2e052d7f2ac8 Duration: 15014.73 ms Billed Duration: 15000 ms Memory Size: 256 MB Max Memory Used: 54 MB
2020-12-01T20:41:16.655Z 4ccc99b9-f98b-43ea-9b7a-2e052d7f2ac8 Task timed out after 15.01 seconds
Error loading class io.quarkus.funqy.lambda.FunqyStreamHandler: Metaspace: java.lang.OutOfMemoryError
java.lang.OutOfMemoryError: Metaspace
Exception in thread "main" java.lang.Error: java.lang.OutOfMemoryError: Metaspace
at lambdainternal.AWSLambda.startRuntime(AWSLambda.java:194)
at lambdainternal.AWSLambda.main(AWSLambda.java:187)
Caused by: java.lang.OutOfMemoryError: Metaspace
Exception in thread "Thread-4" java.lang.OutOfMemoryError: Metaspace
We'll try to replace the H2 and use an in-memory list
Ok, we tried the "UserCreate" function of our example and it worked. Conclusion would be, that it's really a problem with function not having parameters at all.
I'll submit PR then.
Most helpful comment
I'll submit PR then.