Error when compiling native for AWS Lambda: org.springframework.cloud.function.serverless.web.ServerlessAutoConfiguration.ServerlessServletWebServerFactory has private access in org.springframework.cloud.function.serverless.web.ServerlessAutoConfiguration
eugeniace opened this issue · 1 comments
Describe the bug
We are trying to build native a spring boot with rest controllers for AWS Lambda. On build, we are receiving the following error:
[ERROR] Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:3.3.0-SNAPSHOT:process-aot (process-aot) on project sample-app: Unable to compile generated source
[ERROR] org.springframework.cloud.function.serverless.web.ServerlessAutoConfiguration.ServerlessServletWebServerFactory has private access in org.springframework.cloud.function.serverless.web.ServerlessAutoConfiguration c:\sample-app\target\spring-aot\main\sources\org\springframework\cloud\function\serverless\web\ServerlessAutoConfiguration__ManagementBeanDefinitions.java 21:68
The problem seems also to be related to actuator. If I remove dependency to actuator, I am not receiving this error anymore.
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>
I've change it to public, so give it a shot and feel free to reopen if you still have issues. You'd need to manually upgrade 4.1.2-SNAPSHOT once it is ready (few hours from the time of this posting)