ServiceStack.Interfaces
This instructs the generator tool to generate translator methods for the types supplied.
A {TypeName}.generated.cs partial class will be generated that contains the methods required
to generate to and from that type.
Error information pertaining to a particular named field.
Used for returning multiple field validation errors.s
If the Service also implements this interface,
IRestPutService.Put() will be used instead of IService.Execute() for
EndpointAttributes.HttpPut requests
A thin wrapper around ASP.NET or HttpListener's HttpResponse
Signal that this response has been handled and no more processing should be done.
When used in a request or response filter, no more filters or processing is done on this request.
Calls Response.End() on ASP.NET HttpResponse otherwise is an alias for Close().
Useful when you want to prevent ASP.NET to provide it's own custom error page.
Response.Flush() and OutputStream.Flush() seem to have different behaviour in ASP.NET
The underlying ASP.NET or HttpListener HttpResponse
Gets a value indicating whether this instance is closed.
Subscribe to channels by name
Subscribe to channels matching the supplied patterns
The number of active subscriptions this client has
Registered handler called after client *Subscribes* to each new channel
Registered handler called when each message is received
Registered handler called when each channel is unsubscribed
Wrap the common redis list operations under a IList[string] interface.
Creates a Debug Logger, that logs all messages to: System.Diagnostics.Debug
Made public so its testable
Factory to create ILog instances
Gets the logger.
The type.
Gets the logger.
Name of the type.
Contract indication that the Response DTO has a ResponseStatus
interface to operation that can queue commands
For messaging exceptions that should by-pass the messaging service's configured
retry attempts and store the message straight into the DLQ
Base Exception for all ServiceStack.Messaging exceptions
Default logger is to Console.WriteLine
Made public so its testable
Logs a message in a running application
Logs a Debug message.
The message.
Logs a Debug message and exception.
The message.
The exception.
Logs a Debug format message.
The format.
The args.
Logs a Error message.
The message.
Logs a Error message and exception.
The message.
The exception.
Logs a Error format message.
The format.
The args.
Logs a Fatal message.
The message.
Logs a Fatal message and exception.
The message.
The exception.
Logs a Error format message.
The format.
The args.
Logs an Info message and exception.
The message.
Logs an Info message and exception.
The message.
The exception.
Logs an Info format message.
The format.
The args.
Logs a Warning message.
The message.
Logs a Warning message and exception.
The message.
The exception.
Logs a Warning format message.
The format.
The args.
Gets or sets a value indicating whether this instance is debug enabled.
true if this instance is debug enabled; otherwise, false.
Initializes a new instance of the class.
The type.
Initializes a new instance of the class.
The type.
Logs the specified message.
The message.
The exception.
Logs the format.
The message.
The args.
Logs the specified message.
The message.
Base interface all webservices need to implement.
For simplicity this is the only interface you need to implement
The HTTP Response Status Code
The HTTP Status Description
The HTTP Response ContentType
Additional HTTP Headers
Response DTO
A specific template, if not the default (for HTML, Markdown, etc. ContentTypes)
if not provided, get's injected by ServiceStack
Holds the request call context
Resolve a dependency from the AppHost's IOC
Pipeline interface shared by typed and non-typed pipelines
Interface to operations that allow queued commands to be completed
The same functionality is on IServiceResolver
Creates a Debug Logger, that logs all messages to: System.Diagnostics.Debug
Made public so its testable
This instructs the generator tool to generate translator extension methods for the types supplied.
A {TypeName}.generated.cs static class will be generated that contains the extension methods required
to generate to and from that type.
The source type is what the type the attribute is decorated on which can only be resolved at runtime.
Utility interface that implements all Rest operations
If the Service also implements this interface,
IRestGetService.Get() will be used instead of IService.Execute() for
EndpointAttributes.HttpGet requests
If the Service also implements this interface,
IRestPostService.Post() will be used instead of IService.Execute() for
EndpointAttributes.HttpPost requests
If the Service also implements this interface,
IRestDeleteService.Delete() will be used instead of IService.Execute() for
EndpointAttributes.HttpDelete requests
If the Service also implements this interface,
IRestPutService.Patch() will be used instead of IService.Execute() for
EndpointAttributes.HttpPatch requests
Interface to redis typed pipeline
interface to queueable operation using typed redis client
Publish the specified message into the durable queue @queueName
Publish the specified message into the transient queue @queueName
Synchronous blocking get.
Non blocking get message
Blocking wait for notifications on any of the supplied channels
Logging API for this library. You can inject your own implementation otherwise
will use the DebugLogFactory to write to System.Diagnostics.Debug
Gets the logger.
The type.
Gets the logger.
Name of the type.
Gets or sets the log factory.
Use this to override the factory that is used to create loggers
The log factory.
Sends the specified request.
The request.
Common ResponseStatus class that should be present on all response DTO's
Initializes a new instance of the class.
A response status without an errorcode == success
Initializes a new instance of the class.
A response status with an errorcode == failure
Initializes a new instance of the class.
A response status with an errorcode == failure
Holds the custom ErrorCode enum if provided in ValidationException
otherwise will hold the name of the Exception type, e.g. typeof(Exception).Name
A value of non-null means the service encountered an error while processing the request.
A human friendly error message
For multiple detailed validation errors.
Can hold a specific error message for each named field.
Log every service request
Log a request
Returns a Read/Write client (The default) using the hosts defined in ReadWriteHosts
Returns a ReadOnly client using the hosts defined in ReadOnlyHosts.
Returns a Read/Write ICacheClient (The default) using the hosts defined in ReadWriteHosts
Returns a ReadOnly ICacheClient using the hosts defined in ReadOnlyHosts.
Basic implementation of IMessage[T]
Tests logger which stores all log messages in a member list which can be examined later
Made public so its testable
Initializes a new instance of the class.
The type.
Initializes a new instance of the class.
The type.
Logs the specified message.
The message.
The exception.
Logs the format.
The message.
The args.
Logs the specified message.
The message.
Allow the registration of user-defined routes for services
Maps the specified REST path to the specified request DTO.
The type of request DTO to map
the path to.
The path to map the request DTO to.
See RestServiceAttribute.Path
for details on the correct format.
The same instance;
never .
Maps the specified REST path to the specified request DTO, and
specifies the HTTP verbs supported by the path.
The type of request DTO to map
the path to.
The path to map the request DTO to.
See RestServiceAttribute.Path
for details on the correct format.
The comma-delimited list of HTTP verbs supported by the path,
such as "GET,PUT,DELETE". Specify empty or
to indicate that all verbs are supported.
The same instance;
never .
Maps the specified REST path to the specified request DTO,
specifies the HTTP verbs supported by the path, and indicates
the default MIME type of the returned response.
The type of request DTO to map
the path to.
The path to map the request DTO to.
See RestServiceAttribute.Path
for details on the correct format.
The comma-delimited list of HTTP verbs supported by the path,
such as "GET,PUT,DELETE".
The default MIME type in which the response object returned to the client
is formatted, if formatting hints are not provided by the client.
Specify or empty to require formatting hints from
the client.
The same instance;
never .
Maps the specified REST path to the specified request DTO,
specifies the HTTP verbs supported by the path, and indicates
the default MIME type of the returned response.
The type of request DTO to map the path to.
The path to map the request DTO to.
See RestServiceAttribute.Path
for details on the correct format.
The comma-delimited list of HTTP verbs supported by the path,
such as "GET,PUT,DELETE".
The default MIME type in which the response object returned to the client
is formatted, if formatting hints are not provided by the client.
Specify or empty to require formatting hints from
the client.
The same instance;
never .
A light interface over a cache client.
This interface was inspired by Enyim.Caching.MemcachedClient
Only the methods that are intended to be used are required, if you require
extra functionality you can uncomment the unused methods below as they have been
implemented in DdnMemcachedClient
Removes the specified item from the cache.
The identifier for the item to delete.
true if the item was successfully removed from the cache; false otherwise.
Removes the cache for all the keys provided.
The keys.
Retrieves the specified item from the cache.
The identifier for the item to retrieve.
The retrieved item, or null if the key was not found.
Increments the value of the specified key by the given amount. The operation is atomic and happens on the server.
The identifier for the item to increment.
The amount by which the client wants to increase the item.
The new value of the item or -1 if not found.
The item must be inserted into the cache before it can be changed. The item must be inserted as a . The operation only works with values, so -1 always indicates that the item was not found.
Increments the value of the specified key by the given amount. The operation is atomic and happens on the server.
The identifier for the item to increment.
The amount by which the client wants to decrease the item.
The new value of the item or -1 if not found.
The item must be inserted into the cache before it can be changed. The item must be inserted as a . The operation only works with values, so -1 always indicates that the item was not found.
Inserts an item into the cache with a cache key to reference its location.
The key used to reference the item.
The object to be inserted into the cache.
true if the item was successfully stored in the cache; false otherwise.
The item does not expire unless it is removed due memory pressure.
Inserts an item into the cache with a cache key to reference its location.
The key used to reference the item.
The object to be inserted into the cache.
The time when the item is invalidated in the cache.
true if the item was successfully stored in the cache; false otherwise.
Removes all data from the cache.
Retrieves multiple items from the cache.
The list of identifiers for the items to retrieve.
a Dictionary holding all items indexed by their key.
Base transaction interface, shared by typed and non-typed transactions
Redis transaction for typed client
Default logger is to System.Diagnostics.Debug.WriteLine
Made public so its testable
Initializes a new instance of the class.
The type.
Initializes a new instance of the class.
The type.
Logs the specified message.
The message.
The exception.
Logs the format.
The message.
The args.
Logs the specified message.
The message.
For providers that want a cleaner API with a little more perf
Allow delegation of dependencies to other IOC's
Resolve Property Dependency
Resolve Constructor Dependency
An Error Message Type that can be easily serialized
Simple definition of an MQ Host
Register DTOs and hanlders the MQ Host will process
Register DTOs and hanlders the MQ Host will process
Get Total Current Stats for all Message Handlers
Get a Stats dump
Start the MQ Host if not already started.
Stop the MQ Host if not already stopped.
Factory to create consumers and producers that work with this service
Default logger is to System.Diagnostics.Debug.Print
Made public so its testable
Initializes a new instance of the class.
The type.
Initializes a new instance of the class.
The type.
Logs the specified message.
The message.
The exception.
Logs the format.
The message.
The args.
Logs the specified message.
The message.
Manages a connection to a persistance provider
This changes the default behaviour for the
Used to decorate Request DTO's to associate a RESTful request
path mapping with a service. Multiple attributes can be applied to
each request DTO, to map multiple paths to the service.
Initializes an instance of the class.
The path template to map to the request. See
RestServiceAttribute.Path
for details on the correct format.
Initializes an instance of the class.
The path template to map to the request. See
RestServiceAttribute.Path
for details on the correct format.
A comma-delimited list of HTTP verbs supported by the
service. If unspecified, all verbs are assumed to be supported.
Initializes an instance of the class.
The path template to map to the request. See
RestServiceAttribute.Path
for details on the correct format.
A comma-delimited list of HTTP verbs supported by the
service. If unspecified, all verbs are assumed to be supported.
The default MIME type in which the response
object returned to the client is formatted, if formatting hints are unspecified
in the URL. Specify or empty to require formatting
hints from the client.
Gets or sets the path template to be mapped to the request.
A value providing the path mapped to
the request. Never .
Some examples of valid paths are:
- "/Inventory"
- "/Inventory/{Category}/{ItemId}"
- "/Inventory/{ItemPath*}"
Variables are specified within "{}"
brackets. Each variable in the path is mapped to the same-named property
on the request DTO. At runtime, ServiceStack will parse the
request URL, extract the variable values, instantiate the request DTO,
and assign the variable values into the corresponding request properties,
prior to passing the request DTO to the service object for processing.
It is not necessary to specify all request properties as
variables in the path. For unspecified properties, callers may provide
values in the query string. For example: the URL
"http://services/Inventory?Category=Books&ItemId=12345" causes the same
request DTO to be processed as "http://services/Inventory/Books/12345",
provided that the paths "/Inventory" (which supports the first URL) and
"/Inventory/{Category}/{ItemId}" (which supports the second URL)
are both mapped to the request DTO.
Please note that while it is possible to specify property values
in the query string, it is generally considered to be less RESTful and
less desirable than to specify them as variables in the path. Using the
query string to specify property values may also interfere with HTTP
caching.
The final variable in the path may contain a "*" suffix
to grab all remaining segments in the path portion of the request URL and assign
them to a single property on the request DTO.
For example, if the path "/Inventory/{ItemPath*}" is mapped to the request DTO,
then the request URL "http://services/Inventory/Books/12345" will result
in a request DTO whose ItemPath property contains "Books/12345".
You may only specify one such variable in the path, and it must be positioned at
the end of the path.
Gets or sets a comma-delimited list of HTTP verbs supported by the service, such as
"GET,PUT,POST,DELETE".
A providing a comma-delimited list of HTTP verbs supported
by the service, or empty if all verbs are supported.
Gets or sets the default MIME type in which the response
object returned to the client is formatted, when format hints
are not provided in the URI. Some valid examples are such as
"application/json", or "application/xml".
A providing the default MIME type of the response;
or empty if formatting hints are required
from the client.
Interface to redis transaction
A common interface implementation that is implemeneted by most cache providers
Removes the specified item from the cache.
The identifier for the item to delete.
true if the item was successfully removed from the cache; false otherwise.
Removes the cache for all the keys provided.
The keys.
Retrieves the specified item from the cache.
The identifier for the item to retrieve.
The retrieved item, or null if the key was not found.
Increments the value of the specified key by the given amount.
The operation is atomic and happens on the server.
A non existent value at key starts at 0
The identifier for the item to increment.
The amount by which the client wants to increase the item.
The new value of the item or -1 if not found.
The item must be inserted into the cache before it can be changed. The item must be inserted as a . The operation only works with values, so -1 always indicates that the item was not found.
Increments the value of the specified key by the given amount.
The operation is atomic and happens on the server.
A non existent value at key starts at 0
The identifier for the item to increment.
The amount by which the client wants to decrease the item.
The new value of the item or -1 if not found.
The item must be inserted into the cache before it can be changed. The item must be inserted as a . The operation only works with values, so -1 always indicates that the item was not found.
Adds a new item into the cache at the specified cache key only if the cache is empty.
The key used to reference the item.
The object to be inserted into the cache.
true if the item was successfully stored in the cache; false otherwise.
The item does not expire unless it is removed due memory pressure.
Sets an item into the cache at the cache key specified regardless if it already exists or not.
Replaces the item at the cachekey specified only if an items exists at the location already.
Invalidates all data on the cache.
Sets multiple items to the cache.
The values.
Used to decorate Request DTO's to alter the behaviour of a service.
Sets a single access restriction
The restrict access to.
Set multiple access scenarios
The restrict access to scenarios.
If the Service also implements this interface,
IAsyncService.ExecuteAsync() will be used instead of IService.Execute() for
EndpointAttributes.AsyncOneWay requests
Interface to redis pipeline
Creates a Debug Logger, that logs all messages to: System.Diagnostics.Debug
Made public so its testable
Returns a Read/Write client (The default) using the hosts defined in ReadWriteHosts
Returns a ReadOnly client using the hosts defined in ReadOnlyHosts.
Returns a Read/Write ICacheClient (The default) using the hosts defined in ReadWriteHosts
Returns a ReadOnly ICacheClient using the hosts defined in ReadOnlyHosts.
Util static generic class to create unique queue names for types
Util class to create unique queue names for runtime types
Responsible for executing the operation within the specified context.
The operation types.
Returns the first matching RestPath
Executes the DTO request under the supplied requestContext.
Returns a list of operation types available in this service
The operation types.
Returns a list of ALL operation types available in this service
The operation types.
Allow the registration of custom routes
Implement on services that need access to the RequestContext
Creates a test Logger, that stores all log messages in a member list
A Users Session
Set a typed value at key
Get a typed value at key
Store any object at key