Can't Get Glimpse To Work On Remote IIS
Asked Answered
O

2

6

I've tried everything I can think of, so I'm turning to SO. I can't get Glimpse to work on a remote IIS server. I'm using Glimpse 1.2 with ADO, ASP.NET, EF5, and Mvc4 extensions. Everything works wonderfully when I launch the web application locally using the VS development server. However, I can't seem to get the Glimpse icon to show up when deploying to our remote development server. Here's what I've tried and noticed:

  • I am ignoring the LocalPolicy in my web.config:

    <glimpse defaultRuntimePolicy="On" endpointBaseUri="~/Glimpse.axd">
        <inspectors>
            <ignoredTypes>
                <add type="Glimpse.Mvc.Inspector.DependencyInjectionInspector, Glimpse.Mvc4" />
                <add type="Glimpse.AspNet.Policy.LocalPolicy, Glimpse.AspNet"/>
            </ignoredTypes>
        </inspectors>
    </glimpse>
    
  • I am able to access /Glimpse.axd and press the enable button without issue

  • A cookie gets set with the content:

    glimpsePolicy
    On
    backofficetest/
    1088
    2027053056
    32990064
    3189135193
    30291671
    *
    
  • Turning on the Glimpse log does not show any error or warning messages. It generates the following for each request:

2013-04-11 12:43:06.8992 | DEBUG | RuntimePolicy set to 'Off' by IRuntimePolicy of type 'Glimpse.AspNet.Policy.LocalPolicy' during RuntimeEvent 'BeginRequest'.

  • Fiddler verifies that no calls are being made to any Glimpse-related resources during a request.

  • Nothing related to Glimpse appears in the page source.

I'm sure I've just missed a setting somewhere, but this is driving me nuts. Anyone have any ideas?

Thanks.

Oneman answered 11/4, 2013 at 17:34 Comment(1)
Great investigation and question BTW. You provided all the info needed to give you an answer and I appreciate that you read through the docs.Housewarming
H
13

You configuration needs to be updated, like so:

<glimpse defaultRuntimePolicy="On" endpointBaseUri="~/Glimpse.axd">
  <inspectors> 
    <ignoredTypes> 
      <add type="Glimpse.Mvc.Inspector.DependencyInjectionInspector, Glimpse.Mvc4" /> 
    </ignoredTypes> 
  </inspectors>
  <runtimePolicies>
    <ignoredTypes>
        <add type="Glimpse.AspNet.Policy.LocalPolicy, Glimpse.AspNet"/>
    </ignoredTypes>
  </runtimePolicies>
</glimpse>

Runtime policies and inspectors are two different things and are configured in their own nodes.

Housewarming answered 11/4, 2013 at 18:4 Comment(1)
That makes perfect sense - I was sure I missed something obvious like this. I had added the inspector ignore to get around problems with our Unity use, but didn't even notice the parent element name for the LocalPolicy ignore section was different. Everything works perfectly now. Thanks!Oneman
A
4

Even I had a similar problem. It worked on my local machine, but when hosted on IIS it didnt work. I used nikmd23 code and it worked, later realized that only the <runtimePolicies> was required.

Here is what works for me :

<glimpse defaultRuntimePolicy="On" endpointBaseUri="~/Glimpse.axd">      
  <runtimePolicies>
    <ignoredTypes>
        <add type="Glimpse.AspNet.Policy.LocalPolicy, Glimpse.AspNet"/>
    </ignoredTypes>
  </runtimePolicies>
</glimpse>
Ankney answered 19/3, 2014 at 12:58 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.