Announcement Announcement Module
Collapse
No announcement yet.
PayloadTypeRouter not working properly Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • PayloadTypeRouter not working properly

    Hi Guys, The PayloadTypeRouter is not working properly. I was not able to find any existing thread on that or any bug repport.

    The issue is that the traversing of the payload type hierarchy is not checking extended interfaces (Interface with Multiple Inheritance)

    Here is one simple use case:
    1. Interfaces definition:
    Code:
    public interface BroadcastStartMsg extends BroadcastMsg 
    public interface BroadcastEndMsg extends BroadcastMsg
    2. router declaration:
    Code:
    <int:payload-type-router input-channel="channelA" >
            <int:mapping type="BroadcastMsg " channel="channelB"/>
    </int:payload-type-router>
    BroadcastStartMsg and BroadcastEndMsg must be routed from channelA to channelB

    Problem: The PayloadTypeRouter fail to route any instance of BroadcastStartMsg or BroadcastEndMsg

    Reason: the implementation of getChannelIdentifiers (...) in PayloadTypeRouter is checking only implemented interfaces (in this case BroadcastStartMsg or BroadcastEndMsg) but not extended interface (which must be BroadcastMsg).

    I'm not sure if the way it's working is an expected behavior.

    I implemented my own router to solve it (see attachment), but I thought it must be a default behavior of the payload type router.

    Thanks for any feedback on that.

  • #2
    Thanks for pointing this out. What you describe is a bug.
    Could you please file a JIRA issue here https://jira.springsource.org/browse/INT. We'll be able to address it rather shortly and we are targeting a new release some time next week anyway.

    Comment


    • #3
      Thanks Oleg. A JIRA issue was created: https://jira.springsource.org/browse/INT-1969

      Comment

      Working...
      X