Monday, 6 March 2023

Micronaut: How to import beans from other libraries?

Using @Import annotation, we can import the beans from third party libraries.

import io.micronaut.context.annotation.Import;

@Import( 
        packages = { 
                "com.sample.app",
                "com.sample.chatserver"},
        annotated = "*") 
public class App {
}

 

Previous                                                    Next                                                    Home

No comments:

Post a Comment