Blogs Connectivity & SEO Infrastructure
The Blogs Connectivity system provides automated syndication and SEO optimization for blog posts across the Ngwenya Federation. It ensures that every Malet (Outlet) has its own discoverable feed and that search engines can correctly index content across the multi-tenant architecture.
1. Automated Canonical URLs
To prevent duplicate content issues in search engines, the blogs subgraph automatically computes and persists a canonical URL for every blog post if one isn't manually provided by the Malet Owner.
Computation Logic
The BlogQueryService intercepts createOne and updateOne operations to calculate the URL using the following pattern:
https://mallnline.com/[malet-handle]/blog/[blog-slug]
- Handle Resolution: The service uses a
MaletStubto look up the uniquehandleassociated with themaletId. - Fallback: If the Malet has not yet configured a handle, the system falls back to the
maletIdas the URL segment. - Manual Override: If a Malet Owner explicitly provides a value in the
seo.canonicalUrlfield, the automatic computation is skipped.
2. RSS Syndication
The Ngwenya Gateway proxies dynamic RSS 2.0 feeds for individual Malets, allowing Visitors to subscribe to updates via content aggregators.
Endpoint
GET /rss/m/:handle/blogs.xml
Technical Workflow
- The Gateway resolves the
:handleto amaletIdusing the internalMaletStub(synced via Typegoose). - It executes a high-performance GraphQL query (
recentBlogs) against theblogssubgraph. - The response is transformed into an XML RSS 2.0 payload with Atom namespace support.
- Caching: RSS feeds are bypassed by the default gateway thottle via
@SkipThrottleto ensure compatibility with periodic aggregator polling.
3. Multi-Tenant XML Sitemaps
The platform generates standard XML sitemaps to assist search engine crawlers in discovering deep-linked blog content.
Sitemap Routes
| Route | Content |
|---|---|
/sitemap-blogs.xml |
Global sitemap index listing all published blog posts across the platform. |
/sitemap/m/:handle/blogs.xml |
Tenant-specific sitemap containing only the blog posts for a specific Malet. |
Configuration Details
- Locally Managed: Sitemaps are served directly by the
gatewayfor maximum performance. - Prioritization:
- Global blogs:
0.6priority,monthlychange frequency. - Per-Malet blogs:
0.7priority,monthlychange frequency.
- Global blogs:
- Validation: Only posts with
PUBLISHEDstatus and a validslugare included.
4. Federated Service Integration
The connectivity infrastructure relies on cross-subgraph communication patterns:
- blogs microservice: Responsible for data persistence and the
BlogQueryServicelifecycle hooks. - ngwenya-gateway: Serves as the public-facing edge for RSS and Sitemap XML generation, aggregating data from the
blogssubgraph via internal fetch requests. - Malet Model Stubs: Both services maintain thin stubs of the
Maletentity to resolve handles and IDs without requiring full federation overhead for high-frequency SEO tasks.
5. Metadata & Open Graph
SEO meta tags are managed via the SeoService in the blogs subgraph, which provides structured data for:
- JSON-LD:
BlogPostingandRecipeschema types. - Open Graph: Title, description, and featured image mapping.
- Twitter Cards: Summary Large Image format support.
Related
- Blog Analytics API โ Post volume, status distribution, author rankings, and engagement analytics
- Search Engine Administration โ Blog posts are indexed for full-text search with per-vertical synonyms
- Universal Search Index โ Blog posts as searchable entities with TCP event sync to Meilisearch
- Edit History Audit Trail โ Blog post field-level change tracking via
blogPostEditHistoryquery