Search code examples
c#.netc#-4.0streaminsight

StreamInsight: Access is denied


I hosted a StreamInsight server to windows service. The windows service run with LocalSystem.

In OnNext() method, I have code access to server

      using (
            var server =
                Server.Connect(
                    new EndpointAddress(@StreamInsightConfiguration.Default.StreamInsightServiceHostURL))
            )
        {
            var application = server.Applications[StreamInsightConfiguration.Default.StreamInsightApplicationName];

            return application;
        }

At line server.Applications[StreamInsightConfiguration.Default.StreamInsightApplicationName]; I received a message Access is denied.

I also add NT\SYSTEM to StreamInsightUsers$Default group.

How to fix this problem ?


Solution

  • If a user is logged in while the account is being added to the group, the user must log off and then log on again in order for the group membership to become effective. Users that are not members of this group will receive "access denied" errors when attempting to connect to the server’s Web service endpoint in the Event Flow Debugger and other client programs.

    Courtesy:- https://msdn.microsoft.com/en-us/library/ee378749(v=sql.111).aspx