I have application that accepts data for updating products prices and I wondering how I can optimize it.
Data is received in some kind of queue ( rabbitMQ )
Few key notes:
- I can't change incoming data format ( data is received from third party )
- Updates must be performed in order from product perspective ( due attributes )
- Each of product CAN have additional attributes by which system can behave differently when updating prices internally
I was thinking about using some messaging system too to distribute processing something like that:
where :
Q1 is queue for handling only p1 product updates. Q2 is queue for handling only p2 product updates. and so on..
However I have found it is likely to be more anti-pattern: Dynamic queue creation with RabbitMQ For example seems with RabbitMQ it would be even quite hard to achieve since we need to have predefined queues in order to listen them.
The question is:
1) Should I use another pattern in case this is not valid and which pattern I should use 2) In case this pattern is valid is there some kind different messaging system that would allow distribute data by this pattern