Currently looking at monitoring a switchyard app for the BAM work. I am using some test exchange handlers to generate some test activity events - however had some questions/observations:
1) Currently communications between services defined in a switchyard app are internal to a server. Is there expected to be a distributed version of the infrastructure, so that one service may execute on ServerA and another on ServerB, for load balancing purposes? If so, will there be a way to order the exchange handlers so that they can either be before or after the message is distributed between the servers?
- reason being that if I am interested in monitoring the performance of communications between two services packaged in a single switchyard app, I need to be able to record an event at the point that service 1 'sends' the message, and then another event when the service 2 'receives' the event.
- so this means ideally two separate handlers would be required, one at the beginning of the exchange pipeline (before the message may be distributed to a remote server), and another at the end of the pipeline, just prior to it being dispatched to the target service.
- the other reason for being able to position the handlers is that the logged event may need to include the representation of the message as it is seen by the service, and not after it may have been transformed.
2) Knowledge of whether the exchange begins or ends at a binding
- from a monitoring perspective, a message received by a binding has actually been 'sent' by another external service that may also be monitored.
- however currently there does not seem to be a way within the exchange handler to determine whether this is such a case, and therefore whether to create the 'sent' activity event.
- so this means that potentially the monitoring system may have the 'sent' activity recorded twice
- as the binding is essentially a proxy for the external calling/called service, it would be good if the handler could be aware of this, and therefore not record those activity events