title: Get session in ASP boilerplate service layer
body: <p>I am currently use <a href="https://aspnetboilerplate.com/" rel="nofollow noreferrer">AspNetBoilerplate</a> to implement my services in service layer...</p>
  
  <p>So I can access session in MVC controller like:</p>
  
  <pre><code> Token token = HttpContext.Session["Token"] as Token; 
  </code></pre>
  
  <p>After login <code>Token</code> session be initiated....</p>
  
  <p>I can access thta everywhere in MVC controllers but in ApplicationServiceBase it is null like:</p>
  
  <pre><code>public class AuditAppService : ApplicationServiceBase, IAuditAppService
  {
      public GetUserActions_Box GetUserActions()
      {
          var token = HttpContext.Current.Session.GetToken();
          return GetUserActions_Box.Empty;
      }
  }
  </code></pre>
  
  <p><code>HttpContext.Current.Session</code> is null why?  </p>
  
  <p>that app services are implemented in separate library which is added in main web application.</p>
  
  <p>I followed the documentation and crossed <a href="https://aspnetboilerplate.com/Pages/Documents/v1.0.0.0/Abp-Session" rel="nofollow noreferrer">This</a>, I think <code>AbpSession</code> is not my solution which mean by it we can access some basics info about session that initiated by AbpBoilerPlate authentication system not ours.</p>