hmsonline/dropwizard-spring

Issue with DW managed objects

Opened this issue · 0 comments

Hi there,

I'm having a bit of a hard time getting managed objects up and running, whenever I try adding managed beans I get something like

Exception in thread "main" java.lang.IllegalArgumentException: Unknown bean com.schnaub.managed.Foo@3ff0dbfd
    at org.eclipse.jetty.util.component.ContainerLifeCycle.manage(ContainerLifeCycle.java:352)
    at com.hmsonline.dropwizard.spring.SpringService.loadManagedBeans(SpringService.java:165)
    at com.hmsonline.dropwizard.spring.SpringService.run(SpringService.java:60)
    at com.hmsonline.dropwizard.spring.SpringService.run(SpringService.java:30)
    at io.dropwizard.cli.EnvironmentCommand.run(EnvironmentCommand.java:42)
    at io.dropwizard.cli.ConfiguredCommand.run(ConfiguredCommand.java:76)
    at io.dropwizard.cli.Cli.run(Cli.java:70)
    at io.dropwizard.Application.run(Application.java:72)

In the main app I'm on right now all other beans are created just fine.

I've created a super simple demo app here that highlights the issue: https://github.com/JanGorman/ManagedBeanDemo/

Thanks in advance.
Best regards
Jan