Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Open more actions menu
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RavenSessionStateStoreProvider

An ASP.NET session-state store-provider implementation using RavenDB for persistence.

NuGet

The easiest way to install is via the NuGet package (http://nuget.org/List/Packages/Raven.AspNet.SessionState).

Configuration

<configuration>

    <connectionStrings>
            <add name="SessionState" connectionString="Url = http://localhost:8080; DefaultDatabase=SessionState;" />
    </connectionStrings>


    <system.web>
        <sessionState  mode="Custom" customProvider="RavenSessionStateStore">
                <providers>
                    <add name="RavenSessionStateStore" type="Raven.AspNet.SessionState.RavenSessionStateStoreProvider" connectionStringName="SessionState" />
                </providers>
            </sessionState>
    </system.web>

</configuration>

Notes

To have RavenDb automatically remove expired session state, install the Expiration Bundle.

Instrumentation

Run-time instrumentation is provided via NLog and Glimpse

NLog

The RavenDB SessionStateStoreProvider logs via NLog. See NLog documentation for details on how to configure NLog.

For example, to log to a text file, place a file called NLog.config in your bin directory, with the contents:

<?xml version="1.0" encoding="utf-8"?>
<nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

<targets>
    <target xsi:type="File" name="file" layout="${longdate}|${level:uppercase=true}|${logger}|${message}${exception:format=tostring}"
            fileName="${basedir}/ravenDbSessionState.log"></target>
</targets>
<rules>
    <logger name="Raven.AspNet.SessionState.*" minlevel="Debug" writeTo="file" />
</rules>
</nlog>

Glimpse

Instrumentation is also provided via the RavenDB profiling plugin for Glimpse.

See the Glimpse documentation for information on configuring and enabling Glimpse.

About

An ASP.NET session-state store-provider implementation using RavenDB for persistence.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Morty Proxy This is a proxified and sanitized view of the page, visit original site.