Skip to content

Commit

Permalink
Register JAXRS attributes as runtime read-only attribute
Browse files Browse the repository at this point in the history
  • Loading branch information
jmesnil committed Nov 13, 2018
1 parent 98ebcde commit d07c57c
Showing 1 changed file with 3 additions and 3 deletions.
Expand Up @@ -135,15 +135,15 @@ private DeploymentRestResourcesDefintion() {

@Override
public void registerAttributes(ManagementResourceRegistration resourceRegistration) {
resourceRegistration.registerReadOnlyAttribute(RESOURCE_CLASS, new AbstractRestResReadHandler() {
resourceRegistration.registerMetric(RESOURCE_CLASS, new AbstractRestResReadHandler() {
@Override
void handleAttribute(String className, List<JaxrsResourceMethodDescription> methodInvokers,
List<JaxrsResourceLocatorDescription> locatorIncokers, Collection<String> servletMappings,
ModelNode response) {
response.set(className);
}
});
resourceRegistration.registerReadOnlyAttribute(RESOURCE_PATHS, new AbstractRestResReadHandler() {
resourceRegistration.registerMetric(RESOURCE_PATHS, new AbstractRestResReadHandler() {
@Override
void handleAttribute(String className, List<JaxrsResourceMethodDescription> methodInvokers,
List<JaxrsResourceLocatorDescription> locatorIncokers, Collection<String> servletMappings,
Expand All @@ -154,7 +154,7 @@ void handleAttribute(String className, List<JaxrsResourceMethodDescription> meth
}
});

resourceRegistration.registerReadOnlyAttribute(SUB_RESOURCE_LOCATORS, new AbstractRestResReadHandler() {
resourceRegistration.registerMetric(SUB_RESOURCE_LOCATORS, new AbstractRestResReadHandler() {
@Override
void handleAttribute(String className, List<JaxrsResourceMethodDescription> methodInvokers,
List<JaxrsResourceLocatorDescription> locatorIncokers, Collection<String> servletMappings,
Expand Down

0 comments on commit d07c57c

Please sign in to comment.