<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
<title>2 Minute Serverless — Apache Pulsar</title>
<link>https://www.serverless.fyi/</link>
<description>Apache Pulsar posts from 2 Minute Serverless.</description>
<language>en</language>
<copyright>© Serverless Ventures LLC</copyright>
<generator>serverless-fyi 1.0.0</generator>
<lastBuildDate>Tue, 15 Apr 2025 05:33:48 GMT</lastBuildDate>
<atom:link href="https://www.serverless.fyi/t/apache-pulsar/rss.xml" rel="self" type="application/rss+xml"/>
<image><url>https://www.serverless.fyi/brand/icon-192.png</url><title>2 Minute Serverless — Apache Pulsar</title><link>https://www.serverless.fyi/</link></image>
<item>
<title>How Apache Pulsar Manages Multi-Tenancy</title>
<link>https://www.serverless.fyi/p/how-apache-pulsar-manages-multi-tenancy/</link>
<guid isPermaLink="true">https://www.serverless.fyi/p/how-apache-pulsar-manages-multi-tenancy/</guid>
<pubDate>Wed, 06 Nov 2024 21:05:00 GMT</pubDate>
<dc:creator>Mohinish Shaikh</dc:creator>
<description>Harnessing the Power of Multi-Tenancy in Apache Pulsar for Secure and Scalable Data Streaming</description>
<category>apache-pulsar</category>
<content:encoded><![CDATA[<p>In today's data-driven world, organizations often need to support multiple teams, departments, or even external clients on a single infrastructure. Apache Pulsar is designed with this flexibility in mind, offering robust, built-in support for multi-tenancy. This makes Pulsar a popular choice for companies that need to segment resources securely and efficiently. Let’s explore how Pulsar manages multi-tenancy to provide a scalable and secure data streaming solution.</p>
<h2>1. Tenants and Namespaces</h2>
<p>At the core of Pulsar’s multi-tenancy model are <strong>tenants</strong> and <strong>namespaces</strong>. A <strong>tenant</strong> is the highest level of organizational boundary within Pulsar, typically representing a department, team, or customer. Each tenant has unique configurations and can be administered independently.</p>
<p>Within each tenant, Pulsar provides <strong>namespaces</strong>, which allow further segmentation. Namespaces organize topics into logical groups, making it possible to set policies at a granular level. Policies like quotas, time-to-live (TTL) for messages, and backlog retention can all be applied at the namespace level, offering flexibility and fine control over resource allocation.</p>
<h3>2. Topic Segmentation</h3>
<p>Topics are the fundamental data streams in Pulsar and are created within namespaces. Each topic inherits the policies set at the tenant and namespace levels, ensuring that each tenant has isolated, well-defined topics. This segmentation allows for organized access control and enables each tenant to operate independently.<br>
<br>
To understand this in depth, refer to the post <a href="https://www.serverless.fyi/p/understanding-apache-pulsar-topics-a-deep-dive-into-naming-conventions/"><strong>Understanding Apache Pulsar Topics: A Deep Dive into Naming Conventions</strong></a>.</p>
<h3>3. Authentication and Authorization</h3>
<p>Multi-tenancy demands stringent <strong>authentication</strong> and <strong>authorization</strong> controls, especially when dealing with sensitive data from multiple sources. Pulsar supports several authentication mechanisms, such as TLS, OAuth 2.0, and JWT tokens, to verify user identities. These security measures operate at the tenant level, making it easy to separate permissions between tenants.</p>
<p>Additionally, Pulsar offers <strong>role-based access control (RBAC)</strong>, allowing fine-grained permission settings on read, write, and management operations. This ensures that only authorized users have access to specific tenants, namespaces, and topics.</p>
<h3>4. Resource Isolation and Quotas</h3>
<p>One of Pulsar's strongest features is its ability to apply <strong>quotas</strong> on resources within namespaces. Quotas limit the amount of storage, message retention, and message rates per tenant, preventing one tenant from overusing resources at the expense of others. Pulsar also enables <strong>dispatch throttling</strong> to manage bandwidth usage, preventing high usage by one tenant from impacting the performance of others.</p>
<h3>5. Broker and Storage Isolation</h3>
<p>Pulsar allows organizations to achieve both logical and physical isolation. By running in a <strong>geo-replicated cluster</strong>, specific tenants can have their data spread across multiple regions, while others may remain localized. Pulsar also supports <strong>dedicated clusters</strong> for tenants, providing even greater isolation by assigning specific broker resources.</p>
<h3>6. Monitoring and Metrics</h3>
<p>Effective multi-tenancy relies on real-time insights. Pulsar provides <strong>monitoring and metrics</strong> at every level — from tenants to namespaces to topics. This visibility makes it easy for admins to ensure fair resource usage and quickly resolve tenant-specific issues.</p>
<h3>7. Load Balancing</h3>
<p>Pulsar’s <strong>intelligent load balancing</strong> helps distribute topics and partitions across brokers, ensuring that resources are shared fairly among tenants. This prevents any single tenant from consuming excessive resources and ensures reliable performance across the board.</p>
<h3>Conclusion</h3>
<p>Apache Pulsar’s multi-tenancy features provide a scalable, secure, and efficient solution for organizations supporting multiple teams or customers. With its robust tenant, namespace, and topic structure, coupled with advanced authentication, resource quotas, and monitoring, Pulsar empowers organizations to manage data streaming across diverse users with ease and control. Whether it’s for internal departments or external clients, Pulsar's multi-tenancy framework offers the flexibility and isolation needed to maintain efficient operations.<br>
<br>
For an in-depth comparison and insights on why Apache Pulsar may be a better fit for your organization than Kafka, download our comprehensive white paper <strong><a href="https://streamnative.io/whitepapers/decoding-kafka-challenges-addressing-common-pain-points-in-kafka-deployments">Decoding Kafka Challenges: Addressing Common Pain Points in Kafka Deployments Whitepaper</a></strong>.</p>]]></content:encoded>
</item>
<item>
<title>Understanding Apache Pulsar Topics: A Deep Dive into Naming Conventions</title>
<link>https://www.serverless.fyi/p/understanding-apache-pulsar-topics-a-deep-dive-into-naming-conventions/</link>
<guid isPermaLink="true">https://www.serverless.fyi/p/understanding-apache-pulsar-topics-a-deep-dive-into-naming-conventions/</guid>
<pubDate>Mon, 04 Nov 2024 20:53:48 GMT</pubDate>
<dc:creator>Mohinish Shaikh</dc:creator>
<description>From Hierarchical Naming to Production Best Practices: Mastering Pulsar&apos;s Topic Architecture</description>
<category>apache-pulsar</category>
<content:encoded><![CDATA[<p>In the world of distributed messaging systems, Apache Pulsar stands out for its sophisticated approach to topic organization. Unlike other messaging systems, Pulsar implements a hierarchical naming structure that brings clarity and organization to your messaging architecture. Let's dive into how Pulsar topics work and how to effectively use them.</p>
<h2>The Anatomy of a Pulsar Topic</h2>
<p>A Pulsar topic follows this format:</p>
<pre><code class="language-text">persistent://tenant/namespace/topic-name
</code></pre>
<p>This three-level hierarchy isn't just for show – it's a powerful feature that enables better organization and control of your messaging infrastructure. Let's break down each component:</p>
<h3>1. Persistence Prefix</h3>
<p>The <code>persistent://</code> prefix indicates that messages will be durably stored. For scenarios where persistence isn't needed, you can use <code>non-persistent://</code> instead. This choice affects how Pulsar handles your messages and their storage.</p>
<h3>2. Tenant</h3>
<p>The tenant represents the highest level of isolation in Pulsar. Think of it as your organization's private space. For example, if your company is called Acme, you might use <code>acme-corp</code> as your tenant name.</p>
<h3>3. Namespace</h3>
<p>Namespaces provide logical grouping within a tenant. They're perfect for separating different departments, environments, or regions. For instance, you might have namespaces like <code>marketing</code>, <code>production</code>, or <code>us-east</code>.</p>
<h3>4. Topic Name</h3>
<p>The final component is your actual topic name, which describes the specific message stream, such as <code>order-events</code> or <code>user-clicks</code>.</p>
<h2>Real-World Examples</h2>
<p>Here are some practical examples of Pulsar topics:</p>
<pre><code class="language-text">persistent://trading-company/market-data/stock-quotes
persistent://ecommerce/order-processing/purchase-events
persistent://gaming-platform/us-west/player-statistics
</code></pre>
<h2>Best Practices for Topic Organization</h2>
<p>Consider these patterns when structuring your topics:</p>
<ol>
<li>
<p><strong>Regional Separation</strong></p>
<ul>
<li><code>persistent://company/us-west/events</code></li>
<li><code>persistent://company/eu-central/events</code></li>
</ul>
</li>
<li>
<p><strong>Environment Isolation</strong></p>
<ul>
<li><code>persistent://company/production/user-events</code></li>
<li><code>persistent://company/staging/user-events</code></li>
</ul>
</li>
<li>
<p><strong>Team-Based Organization</strong></p>
<ul>
<li><code>persistent://company/marketing/email-campaigns</code></li>
<li><code>persistent://company/sales/lead-tracking</code></li>
</ul>
</li>
</ol>
<p>This hierarchical structure not only provides clear organization but also enables granular control over authentication, authorization, and resource quotas at each level. Whether you're building a small application or a large-scale distributed system, understanding Pulsar's topic structure is key to effectively organizing your messaging architecture.</p>]]></content:encoded>
</item>
</channel>
</rss>
