13Sep/110
WCF + ASP.NET + AppFabric (Velocity) Caching == Awesome
Just getting started on a WCF Service that is going to be handling all of the business logic for the company I work for. With the amount of data, caching was a necessity. Was playing around with Membase last week, couldn't quite get it to work properly and then started yesterday afternoon with AppFabric. Microsoft's own answer to caching (among other things). It installs pretty easily, the built in IIS extensions are very cool. However the setup isn't for the faint of heart. To sum it up:
- Install AppFabric on your SQL Server with all of the options
- Then install AppFabric on your Web Server and create your WCF and ASP.NET sites
- From the PowerShell Cache console type:
New-Cache(Whereis the name you want to call it, so it could be: New-Cache RandomTexels- Verify it got created by:
Get-CacheIf you don't see it or get an error make sure the AppFabric Cache Service is running, open up the Run Window (Windows Key + R) and type: services.msc. It should be one of the top items depending on your setup.- After configuring your other server for .NET 4, usual web site permissions and settings in IIS then do this command:
Grant-CacheAllowedClientAccount DOMAIN\WEBSERVER$Replace DOMAIN with your domain name (ie MOJO) and WEBSERVER with the physical name of your webserver. So for instance:Grant-CacheAllowedClientAccount MOJO\BIGWS$for a domain callled MOJO and a WebServer called BIGWS. - Verify it got created by:
There's plenty of code examples o,,ut there, but as I create the architecture for this WCF I'll discuss my findings.