Today I received the following question from Davez:
I’m using the RTM version and the SubscribeEvent completely ignores any UserID(i.e. “DomainNameuserName”) I pass in. It always logs the subscription under the windows Identity I’m logged in under. Am I doing something wrong here?
Well Davez, I checked with the tool and found exactly the same results as you described.
I asked people on the TFS Team and they confirmed that the API changed in terms of semantics. The UserID parameter is no longer used and the API always takes the SID of the calling user context as the user.
They did not change the API because it was frozen at the time they made the change and so the API will stay this way in the future. Semantics will be that the UserID argument is ignored and the subscription will be made under the calling application security context. For an UI tool that is normally the interactive user, but when you create subscriptions from a service, this will in fact become the Serve Account you are running under. This is something you need to keep in mind, because this API is not documented yet properly in the extensibility kit.
Hope this helps