{"action":"created","issue":{"url":"https://api.github.com/repos/Particular/NServiceBus/issues/4874","repository_url":"https://api.github.com/repos/Particular/NServiceBus","labels_url":"https://api.github.com/repos/Particular/NServiceBus/issues/4874/labels{/name}","comments_url":"https://api.github.com/repos/Particular/NServiceBus/issues/4874/comments","events_url":"https://api.github.com/repos/Particular/NServiceBus/issues/4874/events","html_url":"https://github.com/Particular/NServiceBus/issues/4874","id":246041975,"number":4874,"title":"Extend ITransportReceiveContext with transport meta data about logical/physical queues","user":{"login":"ramonsmits","id":152998,"avatar_url":"https://avatars1.githubusercontent.com/u/152998?v=4","gravatar_id":"","url":"https://api.github.com/users/ramonsmits","html_url":"https://github.com/ramonsmits","followers_url":"https://api.github.com/users/ramonsmits/followers","following_url":"https://api.github.com/users/ramonsmits/following{/other_user}","gists_url":"https://api.github.com/users/ramonsmits/gists{/gist_id}","starred_url":"https://api.github.com/users/ramonsmits/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ramonsmits/subscriptions","organizations_url":"https://api.github.com/users/ramonsmits/orgs","repos_url":"https://api.github.com/users/ramonsmits/repos","events_url":"https://api.github.com/users/ramonsmits/events{/privacy}","received_events_url":"https://api.github.com/users/ramonsmits/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/Particular/NServiceBus/milestones/151","html_url":"https://github.com/Particular/NServiceBus/milestone/151","labels_url":"https://api.github.com/repos/Particular/NServiceBus/milestones/151/labels","id":2052790,"number":151,"title":"Future","description":"","creator":{"login":"andreasohlund","id":125028,"avatar_url":"https://avatars1.githubusercontent.com/u/125028?v=4","gravatar_id":"","url":"https://api.github.com/users/andreasohlund","html_url":"https://github.com/andreasohlund","followers_url":"https://api.github.com/users/andreasohlund/followers","following_url":"https://api.github.com/users/andreasohlund/following{/other_user}","gists_url":"https://api.github.com/users/andreasohlund/gists{/gist_id}","starred_url":"https://api.github.com/users/andreasohlund/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andreasohlund/subscriptions","organizations_url":"https://api.github.com/users/andreasohlund/orgs","repos_url":"https://api.github.com/users/andreasohlund/repos","events_url":"https://api.github.com/users/andreasohlund/events{/privacy}","received_events_url":"https://api.github.com/users/andreasohlund/received_events","type":"User","site_admin":false},"open_issues":117,"closed_issues":14,"state":"open","created_at":"2016-10-06T16:19:18Z","updated_at":"2017-08-03T15:17:56Z","due_on":null,"closed_at":null},"comments":3,"created_at":"2017-07-27T13:36:31Z","updated_at":"2017-08-04T09:55:58Z","closed_at":null,"body":"I had the need to create a behavior to snoop info about the message being fetched/processed. I wanted to use this to send meta data about the message to be used for telemetry.\r\n\r\nI wanted to know transport meta data:\r\n\r\n- from which logical queue the message was fetched\r\n  - `myendpointqueue`\r\n  - `myendpointqueue-discriminator`\r\n- from which physical queue the message was fetched\r\n  - `myendpointqueue@zolder`\r\n  - `myendpointqueue-discriminator`\r\n  - `myendpointqueue-discriminator`\r\n- when the message was fetched from the queue (if possible, maybe not supported by all transports) which is different from when processing started (prefetching to processing latency)\r\n- how long it took to fetch a message (if possible, maybe not supported by all transports)\r\n- meta data about the connection/broker\r\n  - which Azure subscription?\r\n  - which SQL Server?\r\n\r\nIf would be nice if most of these static values would be set to one or more context properties:\r\n\r\n- ITransportReceiveContext.LogicalQueue:Uri\r\n- ITransportReceiveContext.PhysicalQueue:Uri\r\n- ITransportReceiveContext.Message.FetchedAt:DateTime\r\n- ITransportReceiveContext.Message.FetchCompletedAt:TimeSpan\r\n\r\n\r\nThe last can probably be global per endpoint instance and not need to be part of the receive context."},"comment":{"url":"https://api.github.com/repos/Particular/NServiceBus/issues/comments/320209142","html_url":"https://github.com/Particular/NServiceBus/issues/4874#issuecomment-320209142","issue_url":"https://api.github.com/repos/Particular/NServiceBus/issues/4874","id":320209142,"user":{"login":"ramonsmits","id":152998,"avatar_url":"https://avatars1.githubusercontent.com/u/152998?v=4","gravatar_id":"","url":"https://api.github.com/users/ramonsmits","html_url":"https://github.com/ramonsmits","followers_url":"https://api.github.com/users/ramonsmits/followers","following_url":"https://api.github.com/users/ramonsmits/following{/other_user}","gists_url":"https://api.github.com/users/ramonsmits/gists{/gist_id}","starred_url":"https://api.github.com/users/ramonsmits/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ramonsmits/subscriptions","organizations_url":"https://api.github.com/users/ramonsmits/orgs","repos_url":"https://api.github.com/users/ramonsmits/repos","events_url":"https://api.github.com/users/ramonsmits/events{/privacy}","received_events_url":"https://api.github.com/users/ramonsmits/received_events","type":"User","site_admin":false},"created_at":"2017-08-04T09:55:58Z","updated_at":"2017-08-04T09:55:58Z","body":"@timbussmann I did not try to do more plumbing besides creating this issue. If it would have been present the NServiceBus.Metrics could be made much more interesting. If the meta data would have been available the monitoring samples currently made in docs for Azure Application Insights, Prometheus en maybe in the future for AWS Cloudfront could show much more meaningful data."}}
{"actor":{"display_login":"ramonsmits"}}