Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/cmake/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Aws lambda Quarkus本机编译错误:";映像堆中不允许有sun.security.provider.NativePRNG实例;_Aws Lambda_Quarkus_Graalvm_Graalvm Native Image - Fatal编程技术网

Aws lambda Quarkus本机编译错误:";映像堆中不允许有sun.security.provider.NativePRNG实例;

Aws lambda Quarkus本机编译错误:";映像堆中不允许有sun.security.provider.NativePRNG实例;,aws-lambda,quarkus,graalvm,graalvm-native-image,Aws Lambda,Quarkus,Graalvm,Graalvm Native Image,我正在尝试编译一个AWS Lambda Quarkus原生项目 当我尝试添加和使用HTTP客户端时,编译被破坏 错误如下: Error: No instances of sun.security.provider.NativePRNG are allowed in the image heap as this class should be initialized at image runtime. To see how this object got instantiated use -H:+

我正在尝试编译一个AWS Lambda Quarkus原生项目

当我尝试添加和使用HTTP客户端时,编译被破坏

错误如下:

Error: No instances of sun.security.provider.NativePRNG are allowed in the image heap as this class should be initialized at image runtime. To see how this object got instantiated use -H:+TraceClassInitialization.
Detailed message:
Trace:  object java.security.SecureRandom
    object sun.security.ssl.SSLContextImpl$TLSContext
    object sun.security.ssl.SSLSocketFactoryImpl
    object org.apache.http.conn.ssl.SSLConnectionSocketFactory
    object java.util.concurrent.ConcurrentHashMap$Node
    object java.util.concurrent.ConcurrentHashMap$Node[]
    object java.util.concurrent.ConcurrentHashMap
    object org.apache.http.config.Registry
    object org.apache.http.impl.conn.DefaultHttpClientConnectionOperator
    object org.apache.http.impl.conn.PoolingHttpClientConnectionManager
    object org.apache.http.impl.client.HttpClientBuilder$2
    object java.lang.Object[]
    object java.util.ArrayList
    object org.apache.http.impl.client.InternalHttpClient
    method io.mirko.alexa.home.raspberry.impl.DynamoDBDeviceRepository.getAWSId(String)
我尝试过使用OkHTTP和Apache HTTP客户端,但没有成功

我还尝试了选项
--在运行时初始化
,但没有与以下任何类相关的结果:

  • io.mirko.alexa.home.raspberry.impl.DynamoDBDeviceRepository\u客户代理
  • io.mirko.alexa.home.raspberry.impl.DynamoDBDeviceRepository
  • org.apache.http.impl.client
  • java.security.SecureRandom
  • org.apache.http.impl.client.InternalHttpClient
  • sun.security.provider.NativePRNG
  • 我对使用哪个HTTP客户端没有限制。仅在Quarkus Native中使用一个就足够了


    谢谢。

    使用MyPrimeREST客户端来考虑考虑吗?@ StvEC感谢您的评论。是的,我做了,我把它作为一个解决办法。但是,更具体地说,我有两个问题:我可能无法控制源代码,因此最好有一个广泛采用的HTTP客户端与Quarkus一起工作(想象一下,如果我需要使用使用Apache HTTP客户端的OAuth库)。第二个问题是,如果我事先不知道URL,我就不能声明性地定义我的客户机。可能Quarkus中有一个较低级别的组件,但我找不到它们。