Uploaded image for project: 'Spring Integration'
  1. Spring Integration
  2. INT-3852

Cannot Customize JMX ObjectNames

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Complete
    • Affects Version/s: None
    • Fix Version/s: 4.2.1
    • Component/s: JMX Support
    • Labels:

      Description

      @IntegrationManagedResource("${customObjectName}")
      public static class HandlerWithCustomObjectName extends AbstractMessageHandler {
      
      	@Override
      	protected void handleMessageInternal(Message<?> message) throws Exception {
      	}
      
      }
      

      Does not work because the handler gets wrapped in a LifecycleTrackableMessageHandlerMetrics with its own IntegrationManagedResource annotation.

      @IntegrationManagedResource(objectName="${customObjectName}")
      public static class ChannelWithCustomObjectName extends AbstractMessageChannel {
      
      	@Override
      	protected boolean doSend(Message<?> message, long timeout) {
      		return false;
      	}
      
      }
      

      Works fine.

        Attachments

          Activity

            People

            Assignee:
            grussell Gary Russell
            Reporter:
            grussell Gary Russell
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: