public class SourcesImpl extends ComponentResource implements Sources, Source
auth, readTimeoutMs| Constructor and Description |
|---|
SourcesImpl(javax.ws.rs.client.WebTarget web,
org.apache.pulsar.client.api.Authentication auth,
org.asynchttpclient.AsyncHttpClient asyncHttpClient,
long readTimeoutMs) |
addAuthHeadersasyncDeleteRequest, asyncDeleteRequest, asyncGetRequest, asyncPostRequest, asyncPutRequest, getApiException, getApiException, getReasonFromServer, request, requestAsync, syncpublic SourcesImpl(javax.ws.rs.client.WebTarget web,
org.apache.pulsar.client.api.Authentication auth,
org.asynchttpclient.AsyncHttpClient asyncHttpClient,
long readTimeoutMs)
public List<String> listSources(String tenant, String namespace) throws PulsarAdminException
listSources in interface SourcesPulsarAdminExceptionpublic CompletableFuture<List<String>> listSourcesAsync(String tenant, String namespace)
listSourcesAsync in interface Sourcespublic SourceConfig getSource(String tenant, String namespace, String sourceName) throws PulsarAdminException
getSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<SourceConfig> getSourceAsync(String tenant, String namespace, String sourceName)
getSourceAsync in interface Sourcespublic SourceStatus getSourceStatus(String tenant, String namespace, String sourceName) throws PulsarAdminException
getSourceStatus in interface SourcesPulsarAdminExceptionpublic CompletableFuture<SourceStatus> getSourceStatusAsync(String tenant, String namespace, String sourceName)
getSourceStatusAsync in interface Sourcespublic SourceStatus.SourceInstanceStatus.SourceInstanceStatusData getSourceStatus(String tenant, String namespace, String sourceName, int id) throws PulsarAdminException
getSourceStatus in interface SourcesPulsarAdminExceptionpublic CompletableFuture<SourceStatus.SourceInstanceStatus.SourceInstanceStatusData> getSourceStatusAsync(String tenant, String namespace, String sourceName, int id)
getSourceStatusAsync in interface Sourcespublic void createSource(SourceConfig sourceConfig, String fileName) throws PulsarAdminException
createSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> createSourceAsync(SourceConfig sourceConfig, String fileName)
createSourceAsync in interface Sourcespublic void createSourceWithUrl(SourceConfig sourceConfig, String pkgUrl) throws PulsarAdminException
createSourceWithUrl in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> createSourceWithUrlAsync(SourceConfig sourceConfig, String pkgUrl)
createSourceWithUrlAsync in interface Sourcespublic void deleteSource(String cluster, String namespace, String function) throws PulsarAdminException
deleteSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> deleteSourceAsync(String tenant, String namespace, String function)
deleteSourceAsync in interface Sourcespublic void updateSource(SourceConfig sourceConfig, String fileName, UpdateOptions updateOptions) throws PulsarAdminException
updateSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> updateSourceAsync(SourceConfig sourceConfig, String fileName, UpdateOptions updateOptions)
updateSourceAsync in interface Sourcespublic void updateSource(SourceConfig sourceConfig, String fileName) throws PulsarAdminException
updateSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> updateSourceAsync(SourceConfig sourceConfig, String fileName)
updateSourceAsync in interface Sourcespublic void updateSourceWithUrl(SourceConfig sourceConfig, String pkgUrl, UpdateOptions updateOptions) throws PulsarAdminException
updateSourceWithUrl in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> updateSourceWithUrlAsync(SourceConfig sourceConfig, String pkgUrl, UpdateOptions updateOptions)
updateSourceWithUrlAsync in interface Sourcespublic void updateSourceWithUrl(SourceConfig sourceConfig, String pkgUrl) throws PulsarAdminException
updateSourceWithUrl in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> updateSourceWithUrlAsync(SourceConfig sourceConfig, String pkgUrl)
updateSourceWithUrlAsync in interface Sourcespublic void restartSource(String tenant, String namespace, String functionName, int instanceId) throws PulsarAdminException
restartSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> restartSourceAsync(String tenant, String namespace, String functionName, int instanceId)
restartSourceAsync in interface Sourcespublic void restartSource(String tenant, String namespace, String functionName) throws PulsarAdminException
restartSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> restartSourceAsync(String tenant, String namespace, String functionName)
restartSourceAsync in interface Sourcespublic void stopSource(String tenant, String namespace, String sourceName, int instanceId) throws PulsarAdminException
stopSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> stopSourceAsync(String tenant, String namespace, String sourceName, int instanceId)
stopSourceAsync in interface Sourcespublic void stopSource(String tenant, String namespace, String sourceName) throws PulsarAdminException
stopSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> stopSourceAsync(String tenant, String namespace, String sourceName)
stopSourceAsync in interface Sourcespublic void startSource(String tenant, String namespace, String sourceName, int instanceId) throws PulsarAdminException
startSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> startSourceAsync(String tenant, String namespace, String sourceName, int instanceId)
startSourceAsync in interface Sourcespublic void startSource(String tenant, String namespace, String sourceName) throws PulsarAdminException
startSource in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> startSourceAsync(String tenant, String namespace, String sourceName)
startSourceAsync in interface Sourcespublic List<ConnectorDefinition> getBuiltInSources() throws PulsarAdminException
getBuiltInSources in interface SourcesPulsarAdminExceptionpublic CompletableFuture<List<ConnectorDefinition>> getBuiltInSourcesAsync()
getBuiltInSourcesAsync in interface Sourcespublic void reloadBuiltInSources()
throws PulsarAdminException
reloadBuiltInSources in interface SourcesPulsarAdminExceptionpublic CompletableFuture<Void> reloadBuiltInSourcesAsync()
reloadBuiltInSourcesAsync in interface SourcesCopyright © 2017–2021 Apache Software Foundation. All rights reserved.