Replies: 1 comment 1 reply
-
To resolve the issue with Spring Modulith dependency injection:
Recheck these and it should resolve your dependency issue. |
Beta Was this translation helpful? Give feedback.
-
Any chance you provide a simple reproducer that shows the verification error appearing? |
Beta Was this translation helpful? Give feedback.
-
Hello, I find development with Spring Modulith very exciting and am currently rewriting an existing project. This involves resolving many dependencies and sharing services. However, I am having problems allowing dependencies. TheVerify method always throws errors.
I want to allow the service "userService" from the user module in the customer module.
I created a packet info for each one.
directly in the packetService
For user:
@org.springframework.modulith.NamedInterface("userService")
package app.user.rep.service;
For customer
@org.springframework.modulith.ApplicationModule(
allowedDependencies = "user:: userService"
)
Unfortunately, I keep getting the error message
CustomerResource has parameter of type UserService.
What am I doing wrong? Thanks in advance for your help.
module user:
user
- user.a.java
- user.b.java
user.rep
- user.rep.a.java
- user.rep.b.java
user.repo.service
- user.repo.service.userService
package-info.java
module customer:
customer
customer.controller
- customer.resource.java
package-info.java
customer.rep
customer.model
Beta Was this translation helpful? Give feedback.
All reactions