Skip to main content

Outline

At a glance
  • Two integration patterns: Content Synchronization and Routing.
  • Synchronization: Replicates external data into the Optimizely content repository.
  • Routing: Resolves content dynamically at request time without storing it locally.
  • Best practice: Use routing for large, dynamic, or externally owned datasets.
  • Architecture insight: Hybrid approaches combining both patterns are common in enterprise Optimizely implementations.


Introduction

Modern Optimizely CMS 12 solutions frequently integrate with external systems such as Product Information Management (PIM) platforms, CRM systems, commerce engines, or headless content services. Developers must decide how external data should be surfaced within the CMS.

Two architectural approaches dominate these integrations:

  • Content Synchronization – external content is copied and stored inside Optimizely.
  • Routing – external content is dynamically resolved during URL processing without persisting it in the CMS database.

Choosing the correct pattern directly affects scalability, database size, editorial workflows, performance characteristics, and long-term maintainability of the solution.


1. Content Synchronization Overview

Content synchronization is the process of importing and maintaining external content within the Optimizely content repository. This approach treats external data as native CMS content by persisting it inside the Optimizely database.

Once synchronized, the content participates fully in Optimizely's editorial features, including versioning, workflows, search indexing, and personalization.

Structural Synchronization (Code-First Model)

Optimizely CMS follows a code-first content modeling approach. During application startup, the system scans assemblies for content models decorated with attributes such as ContentType.

These definitions are synchronized with the CMS database automatically.

[ContentType(DisplayName = "Article Page")] public class ArticlePage : PageData { public virtual string Summary { get; set; } }

The CMS automatically creates or updates the corresponding schema representation in the database.

Data Synchronization

Beyond structural synchronization, content instances may be imported from external systems through scheduled or event-driven processes.

  • Scheduled synchronization – jobs periodically import full datasets or incremental changes.
  • Event-driven synchronization – external system events trigger immediate updates.
  • Serialization pipelines – content is serialized before being transmitted to downstream systems such as Optimizely Graph.

Typical Synchronization Scenarios

  • Indexing content in Optimizely Graph
  • Supporting site search across internal and external content
  • Providing full editorial control over imported content
  • Migrating legacy CMS or database content into Optimizely


2. Routing and Dynamic Content Resolution

Routing provides a fundamentally different approach to integration. Instead of replicating external data into the CMS database, routing resolves content dynamically when a user requests a URL.

This pattern allows Optimizely to function as a presentation layer while the authoritative data remains in an external system.

IContentProvider

An IContentProvider exposes external data as if it were part of the Optimizely content tree. These items implement the IContent interface but are not stored in the CMS database.

This abstraction allows editors and APIs to interact with external data using familiar Optimizely interfaces.

IPartialRouter

An IPartialRouter intercepts URL segments and resolves them to content dynamically. It enables custom routing logic that extends beyond the standard CMS page tree.

public class ProductPartialRouter : IPartialRouter { public object RoutePartial(PageData content, SegmentContext segmentContext) { var productId = segmentContext.GetNextValue(); return ProductService.GetProduct(productId); } }

This mechanism enables flexible SEO-friendly URLs while retrieving data on demand.


3. Architectural Differences

Aspect Content Synchronization Routing
Data Storage Stored inside Optimizely database Remains in external system
Source of Truth CMS may become secondary or primary source External system remains authoritative
Content Volume Large datasets increase database size Handles massive datasets efficiently
Content Volatility Better for stable datasets Ideal for frequently changing data
Editorial Workflow Full CMS editing capabilities Limited or delegated to external system
Performance Fast reads after synchronization Dependent on external API latency


4. When Routing is the Better Choice

  • High-frequency updates – such as real-time pricing or inventory data.
  • Large external catalogs – storing millions of items in the CMS database would be inefficient.
  • External system ownership – when another platform is the definitive source of truth.
  • Flexible SEO URL structures – when URLs must be generated dynamically.
  • Database optimization – avoiding unnecessary replication of external datasets.
  • Aggregated multi-system content – presenting unified content from multiple APIs.


5. When Synchronization is Preferable

  • Editors must fully manage and version the content inside Optimizely.
  • Content must be indexed by Optimizely Graph or native search services.
  • The dataset is moderate in size and relatively stable.
  • The CMS must maintain complex relationships between content items.
  • Performance must be consistent even when external APIs are unavailable.


6. Hybrid Integration Architectures

Enterprise implementations often combine both approaches to balance editorial flexibility with performance and scalability.

  • Structure Synchronization + Dynamic Data Routing – content types are defined in Optimizely while live data is retrieved from an external system.
  • Partial Synchronization – only selected high-value items are synchronized for editorial control.
  • Cached Routing – dynamic data retrieved via routing is cached to reduce external API dependency.


Conclusion

The decision between routing and content synchronization in Optimizely CMS 12 is primarily driven by data ownership, volume, volatility, and editorial requirements.

Content synchronization enables deep CMS integration and editorial control, while routing provides a lightweight architecture for presenting dynamic or large external datasets without database duplication.

Understanding these trade-offs allows developers to design scalable and maintainable Optimizely architectures that balance performance, flexibility, and operational complexity.