Skip to content

Commit

Permalink
Inject ResourceService into Dropwizard runtime (#1077)
Browse files Browse the repository at this point in the history
Resolves #963
  • Loading branch information
acoburn authored Sep 26, 2020
1 parent 3bba370 commit 4ebc43e
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -156,11 +156,17 @@ public void run(final T config, final Environment environment) throws Exception
@Override
protected void configure() {
bind(webac).to(WebAcService.class);
bind(getServiceBundler().getResourceService()).to(ResourceService.class);
}
});
});

environment.jersey().register(new AbstractBinder() {
@Override
protected void configure() {
bind(getServiceBundler().getResourceService()).to(ResourceService.class);
}
});

// WebSub
ofNullable(config.getHubUrl()).ifPresent(hub -> {
final WebSubHeaderFilter webSubFilter = new WebSubHeaderFilter();
Expand Down

0 comments on commit 4ebc43e

Please sign in to comment.