Deliver superior customer experiences with an AI-driven platform for creating and deploying cognitive chatbots
Deliver Awesome UI with the most complete toolboxes for .NET, Web and Mobile development
Automate UI, load and performance testing for web, desktop and mobile
A complete cloud platform for an app or your entire digital business
Detect and predict anomalies by automating machine learning to achieve higher asset uptime and maximized yield
Automate decision processes with a no-code business rules engine
Optimize data integration with high-performance connectivity
Connect to any cloud or on-premises data source using a standard interface
Build engaging multi-channel web and digital experiences with intuitive web content management
Personalize and optimize the customer experience across digital touchpoints
Build, protect and deploy apps across any platform and mobile device
Rapidly develop, manage and deploy business apps, delivered as SaaS in the cloud
The content you're reading is getting on in years
This post is on the older side and its content may be out of date.
Be sure to visit our blogs homepage for our latest news, updates and information.
Here are a few words about these components:
PipeSettings - this class holds all information for creating a pipe. It is persistent and it is used to restore a pipe saved in the database.
Mappings - this class contains information how data is transformed when moving through the pipe. The mappings are part of the PipeSettings and are persistent.
Definitions - this is a collection of items describing the type members used by the mappings. They are used in the UI for changing the default mappings and they are not persistent.
Template - this is another thing used in the UI. It describes which pipes will be displayed in the Create and Edit screens for search indexes and feeds. They are not persistent.
Note: By using the methods of the PublishingSystemFactory you cannot change the settings and mappings of existent publishing points (feeds), because they are persistent.
All built-in Sitefinity pipes use the PublishingSystemFactory for getting their components. This means that one can change the default components of the built-in pipes and thus change the way they work. One even can replace a built-in pipe by calling the necessary methods:
The first is to choose where to place your code. One possible place is where you initialize your module. But if you change the settings of the built-in pipes you have to be sure that this is done after SearchModule and PublishingModule are initialized. The best moment to register a custom pipe is after all modules including PublishingModule are initialized. This moment is Bootstrapper.Initialized event and in its event handler we can write our code for registering the custom pipe.
The first thing we do is to register the custom pipe as a type with the following code:
After that we register the pipe settings, the mappings, the definitions and eventually we add the pipe to the search template depending on whether we want the pipe to be used by a search index. Registering the pipe settings and the mappings is mandatory, while the definitions may be implemented to be returned directly by the pipe and adding the pipe to a template may be skipped.
Most of the methods in PublishingSystemFactory has the following signature:
pipeName, XXX xxx);
// Registers the XXX component
// Checks if the XXX component is registered
// Unregister the XXX component
// Unregister all XXX components
// Gets a XXX component
pipeName, PublishingManager manager);
// Gets a persistent ready component
First get default pipe settings:
PipeSettings pipeSettings = PublishingSystemFactory.CreateDefaultContentInboundPipeSettings(
or create pipe settings like this:
PipeSettings pipeSettings =
pipeSettings.InvocationMode = PipeInvokationMode.Push;
and then register them:
We can call a built-in method (e.g. CreateDefaultContentInboundPipeSettings) to get pipe settings but one can write his/her own. Passing the name of your custom pipe is mandatory because this name is set to the PipeName property of the PipeSettings. To get the registered pipe settings of a pipe one calls
pipeName, PublishingManager manager)
pipeName, PipeSettings settings)
Unfortunately there is no possibility to create a class that inherits one of the built-in classes for PipeSettings. The problem lies in a limitation in Sitefinity/OpenAccess for mapping inheriting classes. That is why we added a new persisted property to PipeSettings class. The property is of type IDictionary<string, string> and is named AdditionalData. A developer can use this property to add his/her specific data.
The PublishingSystemFactory can be used to change the default components of the pipes. For example by default the MaxItems property of the pipe settings (this property defines how many items a pipe will provide) used by the ContentInboundPipe is 25. If a developer wants to change this number he/she can use this code:
var pipeSettings = PublishingSystemFactory.GetPipeSettings(ContentInboundPipe.PipeName);
pipeSettings.MaxItems = 50;
Get default pipe mappings:
List<Mapping> mappingsList = PublishingSystemFactory.GetDefaultInboundMappingForContent();
or create pipe mappings like this:
List<Mapping> mappingsList =
var contentMapping =
var linkMapping =
TranslatorName = UrlShortenerTranslator.TranslatorName
Again we can use one of the built-in methods to get a list of mappings but one can implement his/her own. There is an extra parameter when calling RegisterPipeMappings method. This parameter specifies whether the pipe is inbound or outbound (correspondingly we pass true or false). This is necessary because one pipe can be used for both purposes - to pass data to a publishing point or to take data from a publishing point. In these two cases the pipe may need different mappings. To get the registered mappings for one pipe one should use
isInbound, PublishingManager manager)
Get default pipe definitions:
IDefinitionField definitions = PublishingSystemFactory.CreateDefaultRSSPipeDefinitions();
or create pipe definitions like this:
IDefinitionField definitions =
We can use one of the built-in methods to get an array of definitions but one can implement his/her own. To get the registered definitions for one pipe one should use
.definition = PublishingSystemFactory.GetPipeDefinitions(
This is quite easy:
var pipeSettings = PublishingSystemFactory.GetPipeSettings(
To sum up all the code samples above here I'll give you the code used for registering the ProductInboundPipe inside our Publishing module. I
want to point that this code is just for reference what your code should look like
at the end. If you are looking for a working sample please look at this post http://www.sitefinity.com/blogs/teodorgeorgiev/posts/11-08-18/publishing_system_brief_walkthrough.aspx
//Subscribe for the Initialized event
/* ... */
Bootstrapper.Initialized -= Bootstrapper_Initialized;
Bootstrapper.Initialized += Bootstrapper_Initialized;
sender, Telerik.Sitefinity.Data.ExecutedEventArgs e)
//Check if all modules are initialized
//Check if the module is initialized and active
var catalogModule = SystemManager.GetApplicationModule(CatalogModule.moduleName);
//Check if the pipe is already registered
//Register the type of the pipe
//Get the default mappings and register them
var mappingsList = ProductInboundPipe.GetDefaultInboundMappingForProduct();
//Get the default pipe settings and regiser them
var pipeSettings = (SitefinityContentPipeSettings)PublishingSystemFactory.CreateDefaultContentInboundPipeSettings(ProductInboundPipe.PipeName);
//Get the previously registered settings and register them for the template used by the search index UI
var contentPipeSettings = (SitefinityContentPipeSettings)PublishingSystemFactory.GetPipeSettings(ProductInboundPipe.PipeName);
contentPipeSettings.MaxItems = 0;
, contentPipeSettings, ps => ps.PipeName == ProductInboundPipe.PipeName);
//Get the default definitions and register them
var contentPipeProductsDefinitions = ProductInboundPipe.CreateDefaultProductPipeDefinitions();
In this post I tried to give you all the basic information to set up your custom pipe for using is Sitefinity. It may seem a lot of effort to do this but actually it's not so hard if you follow the samples above and especially the last one. If you have any questions or a remarks please write them down.
View all posts from The Progress Guys on the Progress blog. Connect with us about all things application development and deployment, data integration and digital business.
Copyright © 2018 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.
Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.