Can the StateServer be used by a ASP.Net 4.5 website?

#1
Hi,
When I run the sample applications, which are in VS 2008, the system works fine. However when I try to integrate using a VS 2012 project, I get the error "Could not load file or assembly 'soss_svcdotnet' or one of its dependencies. An attempt was made to load a program with an incorrect format"
I have the StateServer 64bit version 5.0 installed to evaluate whether it can be used for our application. can you please let me know if there is something that I need to setup or if ASP.Net 4.5 is not yet supported by the StateServer, since I can only see reference to .Net 4.0 on the forums.
Thanks.
 

admin

Administrator
#1
Yes, ASP.NET 4.5 is fully supported by our .NET APIs and our session state provider. Which sample are you trying to run--is it the SessionTest sample web app that shows how to use our session provider? If so, there's another version of that sample in the DOTNET4.0 folder that's under the product's installation directory, and it targets the .NET 4.0/4.5 Frameworks.

In general, when moving a project from .NET 2.0-3.5 to .NET 4.x, the following changes should be made to any projects that use ScaleOut's .NET APIs:

1) If using ScaleOut's ASP.NET session state provider, edit the <sessionState> element in your app's web.config file to reference version 5.0.0.0 of the soss_storeprovider assembly (this version of the assembly targets .NET 4.0 & 4.5). For example:

Code:
<sessionState mode="Custom" customProvider="SossStoreProvider" cookieless="UseCookies" >
  <providers>
    <add name="SossStoreProvider" type="Soss.Web.SossStoreProvider, soss_storeprovider, Version=5.0.0.0, Culture=neutral, PublicKeyToken=a1ec0b86f746a476" />
  </providers>
</sessionState>
2) If your project uses ScaleOut's caching APIs directly, change your project references to point to the .NET 4.0 versions of ScaleOut's API assemblies (soss_svcdotnet.dll and soss_namedcache.dll), which can be found in the DOTNET4.0 folder under the StateServer installation directory (typically C:\Program Files\ScaleOut_Software\StateServer\DOTNET4.0).

Microsoft's .NET 4.5 is actually an "in-place" upgrade of .NET 4.0... it adds new framework libraries and makes some tweaks to the 4.0 runtime, but 4.5 still uses the version 4.0 runtime at its core. So ScaleOut's .NET 4.0 libraries work well in .NET 4.5 applications.
 
Top