Announcement Announcement Module
Collapse
No announcement yet.
Which class is being used Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Which class is being used

    Hello Folks,
    This is a regular Spring framework question but it is also Spring Integration related, so I am posting it here.

    I have started to use the new Spring Integration/AMQP XML tags like the following:-

    <int-amqp:inbound-channel-adapter channel="testRabbitChannel"
    queue-names="testQueue"
    connection-factory="connectionFactory" />

    Now, my rudimentary question is:- Which Spring class is really being used here? I guess this is a basic question that every Spring developer faces when moving to the new (actually not so new) XML notation. I was using the bean id="beanName" class="org.springframework.SomeClass" notation so far.

    Is there a quick way I can find out (by looking at the source code?) which class is exactly being used?

    Thanks.

  • #2
    You might want to take a look at the AmqpInboundChannelAdapterParser which contains the code to register all the needed beans.

    Comment


    • #3
      Thank you very much Marten. That is exactly what I was looking for. There are *Parser.java classes that I can use to find out what class is actually being used.

      For example, I looked at org.springframework.scheduling.config.ScheduledTas ksBeanDefinitionParser and it has this method which helped me identify the class used when I use the scheduled-tasks tag in my XML

      @Override
      protected String getBeanClassName(Element element) {
      return "org.springframework.scheduling.config.ScheduledTa skRegistrar";
      }

      Comment

      Working...
      X