dropwizard No 'Access-Control-Allow-Origin' on admin

Viewed 2805

I've got a problem with my DropWizard server when I want to access it from an angular app. The error is:

XMLHttpRequest cannot load https://localhost:8080/admin/metrics. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:8000' is therefore not allowed access.

I already looked here Dropwizard resolving CORS issues

And it actually works for addresses like : https://localhost:8080/myResource/list

but not the pre-configured /admin resources https://localhost:8080/admin/metrics.

It seems to indicate the filter added to the environment is only used for /api and not for /admin ...

I would need help ?

1 Answers
Related