These packages include the Free Usage Quotas listed below. The list of supported packages are also listed on nuget.org/profiles/ServiceStack. Dedicated support for these packages is available for Windows, Linux and OSX on .NET Core or Windows only for .NET Framework.

Dependencies

Once comfortable with creating a ServiceStack web service, we also recommend exploring ServiceStack by walking through the EmailContacts solution for a guidance on the recommended layout and configuration of a typical medium-sized ServiceStack project.

ServiceStack with OrmLite, Redis and adapters

Would like to use Redis and/or OrmLite, create an Empty ASP.NET project and:

Redis is a popular and indispensable tool in creating high-performance systems. It's often used as a cache, but as it supports comp-sci collections, Pub/Sub, Transactions and server-side LUA scripting, it's finding more use-cases every day.

PM> Install-Package ServiceStack.Redis

Dependencies

ServiceStack.Common

Running Redis on Windows

OrmLite is a fast, simple, convention-based, config-free lightweight ORM that uses code-first POCO classes and Annotation attributes to infer and generate RDBMS table schemas. It's simply provides extension methods over ADO.NET's IDbConnection so is highly-flexible and can even be easily used seamlessly with other Micro ORM's like that uses extension methods like Dapper.

OrmLite has packages for all major RDBMS's, and you just need to install the package for the one you're using, which typically for .NET will be SQL Server:

PM> Install-Package ServiceStack.OrmLite.SqlServer

Dependencies

ServiceStack.Common

Otherwise if you're using an alternative database, install the one you need:

ServiceStack's message-based design enables it to host Services on a variety of different transports including a number of different MQ Servers via the Messaging API all MQ Servers implement making it trivial to swap between different MQ Brokers.

If you're hosted on AWS you can take advantage Amazon's reliable, scalable, fully managed message queuing service. SQS makes it simple and cost-effective to decouple the components of a cloud application. You can use SQS to transmit any volume of data, at any level of throughput, without losing messages or requiring other services to be always available.

If you're hosted on Azure you can utilize Azure Service Bus's highly-reliable and managed cloud messaging service or Windows Service Bus if running Service Bus on Windows Server.

PM> Install-Package ServiceStack.Azure

In Memory MQ

ServiceStack.Server also includes an In Memory MQ option useful for testing and for when other MQ Broker options are not available. Although not being able to accept network requests limits its usefulness.

Amazon Web Services

You can participate in AWS's vibrant ecosystem with ServiceStack's first-class support and deep integration with AWS that seamlessly integrates with popular back-end AWS technologies allowing hosting of ServiceStack solutions entirely on the managed AWS platform

Dependencies

ServiceStack allows you to persist your User Auth information in a variety of different back-end persistence providers. Redis and InMemory are built-in to ServiceStack whilst ServiceStack.Server includes the OrmLite Auth Repository letting you store Users Authentication information in any of the RDBMS's that OrmLite supports: Sql Server, Sqlite, MySql and PostgreSQL.

In addition to these options you can also persist UserAuth info in RavenDB:

PM> Install-Package ServiceStack.Authentication.RavenDB

Dependencies

ServiceStack

RavenDB.Client

Mongo DB:

PM> Install-Package ServiceStack.Authentication.MongoDB

Dependencies

ServiceStack

mongocsharpdriver

or NHibernate:

PM> Install-Package ServiceStack.Authentication.NHibernate

Dependencies

In Memory Caching is available in ServiceStack and ServiceStack.Redis includes the Redis cache client, whilst an OrmLiteCacheClient is available in ServiceStack.Server for utilizing an existing RDBMS as a distributed cache.

Other External caching providers are also available:

AWS Dynamo DB:

PM> Install-Package ServiceStack.Aws

Dependencies

ServiceStack

AWSSDK.Core

AWSSDK.DynamoDBv2

AWSSDK.S3

AWSSDK.SQS

Memcached:

PM> Install-Package ServiceStack.Caching.Memcached

Dependencies

ServiceStack.Common

EnyimMemcached

Azure:

PM> Install-Package ServiceStack.Caching.Azure

Dependencies

ServiceStack also provides an implementation and dependency-free logging API with adapters for all of .NET's popular logging providers. It allows your business logic to bind to an easily-mockable and testable dependency-free interface whilst providing the flexibility to switch logging providers at runtime.

Console, Debug and Empty logging providers are already in ServiceStack, whilst you can use NuGet to get the adapter for your preferred logging framework:

In addition to compiling Razor Views, ServiceStack also has transparent support for embedded resources, allowing your entire application, razor views and web assets to be compiled into .NET dlls that can be ILMerged into a Single cross-platform .exe.

As ServiceStack is just a pure HTTP web service it can be accessed with any HTTP-capable client. However in order to provide the least friction and most productivity end-to-end, we also maintain generic C# clients available at:

PM> Install-Package ServiceStack.Client

Or use the HttpClient-based JsonHttpClient instead with:

PM> Install-Package ServiceStack.HttpClient

Also includes Android, iOS, Windows Store, WPF and Silverlight clients, see Mobile documentation for more info.

See the Hello Repository for a portable solution showing how to re-use DTO's and client libraries between Android, iOS, Windows Store, WPF and Silverlight platforms.

Service Clients are unrestricted

Explicitly included in the free quotas is an exception enabling free, unrestricted use of ServiceStack Service Clients for calling any ServiceStack service.

Signed Packages

Starting from ServiceStack v5 all .NET 4.5 NuGet packages are now strong named.

Otherwise for a self-hosting Console Application, place it before initializing the AppHost, as shown above.

c) Add the System Environment Variable

To simplify license key registration when developing multiple ServiceStack solutions you can register the License Key once in the SERVICESTACK_LICENSE Environment Variable on each pc using ServiceStack libraries:

Variable Value
SERVICESTACK_LICENSE {licenseKeyText}

Note: you'll need to restart IIS or VS.NET for them to pickup any new Environment Variables.

d) Copy license key text into an external text file

Similar to above, we can register the license from an external plain-text file containing the license key text, e.g:

For Self-Hosting set the BuildAction to Copy if Newer and use "~/license.txt".MapAbsolutePath() extension method.

Note: the license key is white-space insensitive so can be broken up over multiple lines.

Free Quotas

Whilst ServiceStack v4 is a commercially-supported product, we also allow free usage for small projects and evaluation purposes. The NuGet packages above include the quota's below which can be unlocked with a license key:

10 Operations in ServiceStack (i.e. Request DTOs)

10 Database Tables in OrmLite

10 DynamoDB Tables in PocoDynamo

20 Different Types in Redis Client Typed APIs

6000 requests per hour with the Redis Client

Resources

About ServiceStack

ServiceStack started development in 2008 with the mission of creating a best-practices services framework with an emphasis on simplicity and speed, reducing the effort in creating and maintaining resilient message-based SOA Services and rich web apps.