title: ServiceStack marker Attribute not found in Collection
body: <p>I  have a custom attribute and I want to check via a GlobalFilter, if the methods I'm calling has this marker attribute.
  I can't find a way, to get the information that the called method where my request aims to has the Attribute.
  I've found already another post, which recommends to use <code>FilterAttributeCache.GetRequestFilterAttributes(request.GetType())</code> but this and also other methods are retuning just no elements.</p>
  <p>Could you please help me in what I'm missing here?</p>
  <p>Following the example code:</p>
  <p>CustomAttribute:</p>
  <pre><code>using ServiceStack;
  using ServiceStack.Web;
  
  namespace MyProject.Web
  {
      public class CustomAttribute : RequestFilterAttribute
      {
          public string ServiceName;
          public string ServiceClass;
          public string ServiceMethod;
  
          public JwtAuthAttribute(string serviceName, string serviceClass, string serviceMethod)
          {
              ServiceName = serviceName;
              ServiceClass = serviceClass;
              ServiceMethod = serviceMethod;
          }
  
          public override void Execute(IRequest req, IResponse res, object requestDto)
          {
              //Nothing in here
          }
      }
  }
  </code></pre>
  <p>Filter:</p>
  <pre><code>using System;
  using System.Linq;
  using ServiceStack.Support.WebHost;
  using ServiceStack.Web;
  
  namespace MyProject.Web
  {
      public class CustomFilter
      {
          private readonly ICustomManager _customManager;
  
          public CustomFilter(ICustomManager customManager)
          {
              _customManager= customManager;
          }
  
          public void Execute(IRequest request)
          {
              var customHeader = request.Headers.GetValues(&quot;CustomHeader&quot;);
  
              if (customHeader == null)
              {
                  return;
              }
  
              var customAttribute = FilterAttributeCache.GetRequestFilterAttributes(request.GetType())
                  .OfType&lt;CustomAttribute&gt;().FirstOrDefault();
  
              if (customAttribute == null)
              {
                  return;
              }
  
              // Do other things here
          }
      }
  }
  </code></pre>
  <p>Registration of GlobalFilter in Global.asax:</p>
  <pre><code>public override void Configure(Container container)
  {
      //other configurations
      
      GlobalRequestFilters.Add((req, res, dto) =&gt; req.ResponseContentType = MimeTypes.Json);
      GlobalRequestFilters.Add((req, res, dto) =&gt;
      {
          var customFilter = new CustomFilter(request.TryResolve&lt;ICustomManager&gt;());
          customFilter.Execute(req);
      });
  }
  </code></pre>
  <p>Method with marker CustomAttribute:</p>
  <pre><code>namespace MyProject.Web
  {
      [Authenticate]
      [RequiredRole(&quot;CustomUser&quot;)]
      public class CustomService : Service
      {
          [Custom(&quot;Service&quot;, &quot;ServiceClass&quot;, &quot;ServiceMethod&quot;)]
          public object Get(CustomRequest request)
          {
              //Additional code
          }   
      }
  }
  </code></pre>