Closed mmirzaeyan closed 12 months ago
I'm afraid there isn't enough detail to diagnose if this is a Spring Boot issue, a WildFly issue or a problem with your code. If you'd like us to spend some time investigating, please take the time to provide a complete minimal sample (something that we can unzip or git clone, build, and deploy) that reproduces the problem. Please also provide exact details of how we can deploy the application into WildFly.
I'm push a light sample of my application in this repository :
repo I'm build the app as a war file and put in the deplyment directory of Wildfly 27 and start it . I'm not using any Wildfly Maven Plugin .
Thanks for the repo but it isn't quite what we're looking for.
The sample should be minimal. This means that it should not contain any code or dependencies that are not related to the problem. For example, the sample currently seems to require an Oracle database which is unlikely to be related to a problem with Hibernate Validator. Please strip it down to the bare minimum that is required to reproduce the problem.
I'm try to do it as simple as I can , I'm remove Oracle database depenecies and push it to the repository .
Unfortunately that hasn't really helped as your application won't start without a database. It also still contains dependencies that are adding complexity yet do not seem to be related to the problem. A notable example of this is camunda-bpm-spring-boot-starter-webapp
it has transitive dependencies on spring-boot-starter-tomcat
and spring-boot-starter-jersey
, both of which clash with Wildfly and its built-in components.
Please minimise the sample as much as possible and verify that it reproduces the problem. We can then take another look.
Do we nead beans.xml in Spring boot project when we try deploy it on Wildfly for cdi management ? I'm put a beans.xml file in my WEB-INF directory and put the bean-discovery-mode to all , the exception was changes to :
jakarta.enterprise.inject.UnsatisfiedResolutionException: Unable to resolve a bean for 'org.springframework.data.redis.core.RedisOperations' with qualifiers [@jakarta.enterprise.inject.Default(), @jakarta.enterprise.inject.Any()].
do you have any idea ?
Spring Boot makes no use of CDI so, AFAIK, there should be no need for a beans.xml file. Perhaps Wildfly needs one for some reason but that would be a Wildfly problem and not something that we can help with. FWIW, our deployment test with Wildfly does not have one.
If you'd like us to spend and more time on this, please provide the requested minimal sample otherwise I think it would be best to close this issue as it isn't the right place to find Wildfly expertise and that appears to be what's needed here.
Which version of Wildfly can run Spring boot 3 ? Does 27 ok ??
Spring Boot 3 requires Jakarta EE 9. 10 is also supported. Any version of Wildfly that meets those requirements should work. I’m going to close this one now. There’s no evidence of a Spring Boot bug and, as I said above, this isn’t the right place for questions about Wildfly.
after some search and review on Wildfly i understand we need to use a jboss-deployment-structure.xml to exclude bean-validation subsystem. i'm alo exclude jsf and weld as well.
Thanks for your support @wilkinsona.
In an application with Spirng boot and Jboss Wildfly i take this error when i migarte the app to Spring boot 3.1.1 and wildfly 27 :
this app work fine with Spring boot 2.7 and Jboss WildFly 15 .
for more information that can help , I deploy war file of the app to Wildfly and excluding embeded containers and import jakarta.servlet-api when i try to build the app :
and this app work fine with embeded containers.