NFX.ServiceModel NamespaceNFX Class Library

[This is preliminary documentation and is subject to change.]

Provides fundamental concepts for writing in-process services
Classes

  ClassDescription
Public classApplicationDontAutoStartServiceAttribute
Designates service-derivative classes that should NOT be auto-started by the app container
Public classCompositeServiceHost
Represents a service that contains other child services. Start/Stop commands translate into child sub-commands. This class is used to host other services in various job/background process hosts
Public classService
Represents a lightweight service that can be controlled by Start/SignalStop-like commands. This class serves a a base for various implementations (i.e. LogService) including their composites. This class is thread-safe
Public classService TDirector 
Represents service with typed ComponentDirector property
Public classServiceWithInstrumentationBase TDirector 
Provides base implementation for Service with IInstrumentable logic
Public classSvcHostException
Thrown by CompositeServiceHost
Public classWorkItemAggregatorService TContext 
Aggregates same/equal (as defined by item's IAggregatableWorkItem.AggregationKey) work items posted into queue to limit the penetration of duplicate work items in destination queue
Protected classWorkItemList TContext 
Public classWorkQueue TContext 
Maintains a queue of pending work - every WorkItem posting in the queue will be executed by the host of the queue. WorkQueues are useful for coordination of complex data/event flows in multi-threaded/service applications
Structures

  StructureDescription
Public structureChildService
Child service entry as managed by CompositeServiceHost class
Interfaces

  InterfaceDescription
Public interfaceIAggregatableWorkItem
Represents an item that may be posted into WorkItemAggregatorService queue
Public interfaceIService
Defines abstraction for an entity that is controlled by Start/Stop commands and has a status
Public interfaceIWorkItem TContext 
Defines a base for items executable by WorkQueue
Public interfaceIWorkQueue TContext 
Defines contract for work queue that work items can be posted to
Delegates

  DelegateDescription
Public delegatePostItemFilter TContext 
A filter delegate that gets called within PostItem before adding work to this queue. This is useful for re-routing work to some other queue/s when needed. Return null if work item is going to be processed by some other queue that this delegate should post into. Keep in mind that this delegate is invoked by posters thread
Enumerations

  EnumerationDescription
Public enumerationControlStatus
Stipulates control phase statuses like: Active/Inactive etc...
Public enumerationWorkItemAggregationIntervalKind
Defines how intervals should be handled. Sliding means that every time message is posted into in queue interval starts to count from scratch, periodic counts from the first message post