Skip to content

Commit 28a5562

Browse files
committed
Enhance PulsarResourcesExtended interface with detailed documentation and flexible topic listing method
1 parent 3eaded2 commit 28a5562

1 file changed

Lines changed: 19 additions & 1 deletion

File tree

pip/pip-452.md

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,11 +100,24 @@ import org.apache.pulsar.common.api.proto.CommandGetTopicsOfNamespace;
100100
import org.apache.pulsar.common.naming.NamespaceName;
101101
import org.jspecify.annotations.Nullable;
102102

103+
/**
104+
* Extended PulsarResources that provides additional functionality beyond PulsarResources.
105+
*
106+
* <p>This interface is designed to be pluggable, allowing custom implementations
107+
* to provide extended PulsarResources capabilities such as custom topic listing strategies</p>
108+
*
109+
* <p>Implementations of this interface can be registered with PulsarService to
110+
* provide extended resource management capabilities.</p>
111+
*/
112+
@InterfaceStability.Evolving
103113
public interface PulsarResourcesExtended {
104114

105115
/**
106116
* Lists topics in a namespace with optional property-based filtering.
107117
*
118+
* <p>This method provides a flexible way to list topics in a namespace,
119+
* supporting property-based filtering through the properties parameter.</p>
120+
*
108121
* @param namespaceName the namespace to list topics from
109122
* @param mode the listing mode (ALL, PERSISTENT, NON_PERSISTENT)
110123
* @param properties optional property filters for topic listing
@@ -116,9 +129,14 @@ public interface PulsarResourcesExtended {
116129

117130
/**
118131
* Initializes this extended resources instance with the PulsarService.
132+
*
133+
* <p>This method is called during broker startup to provide the implementation
134+
* with access to the PulsarService and its dependencies.</p>
135+
*
136+
* @param pulsarService the PulsarService instance
119137
*/
120138
void initialize(PulsarService pulsarService);
121-
139+
122140
/**
123141
* Closes this extended resources instance and releases any resources.
124142
*

0 commit comments

Comments
 (0)