Package org.apache.storm
Class LocalCluster
java.lang.Object
org.apache.storm.LocalCluster
- All Implemented Interfaces:
AutoCloseable,Nimbus.Iface,ILocalCluster,ILocalClusterTrackedTopologyAware
A stand alone storm cluster that runs inside a single process. It is intended to be used for testing. Both internal testing for Apache
Storm itself and for people building storm topologies.
LocalCluster is an AutoCloseable so if you are using it in tests you can use a try block to be sure it is shut down.
try (LocalCluster cluster = new LocalCluster()) { // Do some tests } // The cluster has been shut down.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classSimple way to configure a LocalCluster to meet your needs.classWhen running a topology locally, for tests etc.Nested classes/interfaces inherited from interface org.apache.storm.ILocalCluster
ILocalCluster.ILocalTopology -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionCreate a default LocalCluster.LocalCluster(String zkHost, Long zkPort) Create a LocalCluster that connects to an existing Zookeeper instance. -
Method Summary
Modifier and TypeMethodDescriptionvoidActivate a topology.Add another supervisor to the topology.addSupervisor(Number ports) Add another supervisor to the topology.addSupervisor(Number ports, String id) Add another supervisor to the topology.Add another supervisor to the topology.voidadvanceClusterTime(int secs) Advance the cluster time when the cluster is using SimulatedTime.voidadvanceClusterTime(int secs, int incSecs) Advance the cluster time when the cluster is using SimulatedTime.beginBlobDownload(String key) beginCreateBlob(String key, SettableBlobMeta meta) beginUpdateBlob(String key) voidcancelBlobUpload(String session) voidclose()voidvoiddeactivate(String topologyName) Deactivate a topology.voidEnable/disable logging the tuples generated in topology via an internal EventLogger bolt.voiddeleteBlob(String key) downloadBlobChunk(String session) downloadChunk(String id) voidfinishBlobUpload(String session) voidfinishFileUpload(String location) getBlobMeta(String key) intgetBlobReplication(String key) Get cluster information.This is intended for internal testing only.getComponentPageInfo(String topologyId, String componentId, String window, boolean isIncludeSys) getComponentPendingProfileActions(String id, String componentId, ProfileAction action) Get daemon configuration.getLogConfig(String name) Reference to metrics registry.Reference to nimbus.getOwnerResourceSummaries(String owner) getSupervisor(String id) Get a specific Supervisor.Get assigned assignments for a specific supervisorgetSupervisorPageInfo(String id, String host, boolean isIncludeSys) intgetTopology(String id) Get the compiled storm topology.The config of a topology as a JSON string.getTopologyHistory(String user) Get the state of a topology.getTopologyInfoByName(String name) Get the state of a topology.getTopologyInfoByNameWithOpts(String name, GetInfoOptions options) Get the state of a topology.getTopologyInfoWithOpts(String id, GetInfoOptions options) Get the state of a topology.getTopologyPageInfo(String id, String window, boolean isIncludeSys) If the cluster is tracked get the id for the tracked cluster.Returns the user specified topology as submitted originally.booleanisRemoteBlobExists(String blobKey) Decide if the blob is removed from cluster.booleanisTopologyNameAllowed(String name) voidkillSupervisor(String id) Kill a specific supervisor.voidkillTopology(String topologyName) Kill a topology (if you are not using ILocalTopology).voidkillTopologyWithOpts(String name, KillOptions options) Kill a topology (if you are not using ILocalTopology).static voidMain entry point to running in local mode.voidprocessWorkerMetrics(WorkerMetrics metrics) voidrebalance(String name, RebalanceOptions options) Rebalance a topology.voidSend supervisor local worker heartbeat when a supervisor is unreachablevoidSend supervisor worker heartbeats for a specific supervisorvoidsetBlobMeta(String key, SettableBlobMeta meta) voidsetLogConfig(String name, LogConfig config) voidsetWorkerProfiler(String id, ProfileRequest profileRequest) voidshutdown()Shut down the cluster.voidsubmitTopology(String name, String uploadedJarLocation, String jsonConf, StormTopology topology) submitTopology(String topologyName, Map<String, Object> conf, StormTopology topology) Submit a topology to be run in local mode.submitTopology(String topologyName, Map<String, Object> conf, TrackedTopology topology) Submit a tracked topology to be run in local mode.voidsubmitTopologyWithOpts(String name, String uploadedJarLocation, String jsonConf, StormTopology topology, SubmitOptions options) submitTopologyWithOpts(String topologyName, Map<String, Object> conf, StormTopology topology, SubmitOptions submitOpts) Submit a topology to be run in local mode.submitTopologyWithOpts(String topologyName, Map<String, Object> conf, TrackedTopology topology, SubmitOptions submitOpts) Submit a tracked topology to be run in local mode.intupdateBlobReplication(String key, int replication) voiduploadBlobChunk(String session, ByteBuffer chunk) voiduploadChunk(String location, ByteBuffer chunk) voiduploadNewCredentials(String topologyName, Credentials creds) Upload new credentials to a topology.voidWait for the cluster to be idle.voidwaitForIdle(long timeoutMs) Wait for the cluster to be idle.static <T> TwithLocalModeOverride(Callable<T> c, long ttlSec) Run c with a local mode cluster overriding the NimbusClient and DRPCClient calls.static <T> TwithLocalModeOverride(Callable<T> c, long ttlSec, Map<String, Object> daemonConf) Run c with a local mode cluster overriding the NimbusClient and DRPCClient calls.
-
Field Details
-
KILL_NOW
-
-
Constructor Details
-
Method Details
-
withLocalModeOverride
Run c with a local mode cluster overriding the NimbusClient and DRPCClient calls. NOTE local mode override happens by default now unless netty is turned on for the local cluster.- Parameters:
c- the callable to run in this modettlSec- the number of seconds to let the cluster run after c has completed- Returns:
- the result of calling C
- Throws:
Exception- on any Exception.
-
withLocalModeOverride
public static <T> T withLocalModeOverride(Callable<T> c, long ttlSec, Map<String, Object> daemonConf) throws ExceptionRun c with a local mode cluster overriding the NimbusClient and DRPCClient calls. NOTE local mode override happens by default now unless netty is turned on for the local cluster.- Parameters:
c- the callable to run in this modettlSec- the number of seconds to let the cluster run after c has completeddaemonConf- configs to set for the daemon processes.- Returns:
- the result of calling C
- Throws:
Exception- on any Exception.
-
main
Main entry point to running in local mode.- Parameters:
args- arguments to be run in local mode- Throws:
Exception- on any error when running.
-
getNimbus
Reference to nimbus.- Returns:
- Nimbus itself so you can interact with it directly, if needed.
-
getMetricRegistry
Reference to metrics registry.- Returns:
- The metrics registry for the local cluster.
-
getDaemonConf
Get daemon configuration.- Returns:
- the base config for the daemons
-
submitTopology
public LocalCluster.LocalTopology submitTopology(String topologyName, Map<String, Object> conf, StormTopology topology) throws org.apache.storm.thrift.TExceptionDescription copied from interface:ILocalClusterSubmit a topology to be run in local mode.- Specified by:
submitTopologyin interfaceILocalCluster- Parameters:
topologyName- the name of the topology to useconf- the config for the topologytopology- the topology itself.- Returns:
- an AutoCloseable that will kill the topology.
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
submitTopology
public LocalCluster.LocalTopology submitTopology(String topologyName, Map<String, Object> conf, TrackedTopology topology) throws org.apache.storm.thrift.TExceptionDescription copied from interface:ILocalClusterTrackedTopologyAwareSubmit a tracked topology to be run in local mode.- Specified by:
submitTopologyin interfaceILocalClusterTrackedTopologyAware- Parameters:
topologyName- the name of the topology to useconf- the config for the topologytopology- the topology itself.- Returns:
- an AutoCloseable that will kill the topology.
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
submitTopology
public void submitTopology(String name, String uploadedJarLocation, String jsonConf, StormTopology topology) throws AlreadyAliveException, InvalidTopologyException, AuthorizationException, org.apache.storm.thrift.TException - Specified by:
submitTopologyin interfaceNimbus.Iface- Throws:
AlreadyAliveExceptionInvalidTopologyExceptionAuthorizationExceptionorg.apache.storm.thrift.TException
-
submitTopologyWithOpts
public LocalCluster.LocalTopology submitTopologyWithOpts(String topologyName, Map<String, Object> conf, StormTopology topology, SubmitOptions submitOpts) throws org.apache.storm.thrift.TExceptionDescription copied from interface:ILocalClusterSubmit a topology to be run in local mode.- Specified by:
submitTopologyWithOptsin interfaceILocalCluster- Parameters:
topologyName- the name of the topology to useconf- the config for the topologytopology- the topology itself.submitOpts- options for topology- Returns:
- an AutoCloseable that will kill the topology.
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
submitTopologyWithOpts
public LocalCluster.LocalTopology submitTopologyWithOpts(String topologyName, Map<String, Object> conf, TrackedTopology topology, SubmitOptions submitOpts) throws org.apache.storm.thrift.TExceptionDescription copied from interface:ILocalClusterTrackedTopologyAwareSubmit a tracked topology to be run in local mode.- Specified by:
submitTopologyWithOptsin interfaceILocalClusterTrackedTopologyAware- Parameters:
topologyName- the name of the topology to useconf- the config for the topologytopology- the topology itself.submitOpts- options for topology- Returns:
- an AutoCloseable that will kill the topology.
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
submitTopologyWithOpts
public void submitTopologyWithOpts(String name, String uploadedJarLocation, String jsonConf, StormTopology topology, SubmitOptions options) throws AlreadyAliveException, InvalidTopologyException, AuthorizationException, org.apache.storm.thrift.TException - Specified by:
submitTopologyWithOptsin interfaceNimbus.Iface- Throws:
AlreadyAliveExceptionInvalidTopologyExceptionAuthorizationExceptionorg.apache.storm.thrift.TException
-
uploadNewCredentials
public void uploadNewCredentials(String topologyName, Credentials creds) throws org.apache.storm.thrift.TException Description copied from interface:ILocalClusterUpload new credentials to a topology.- Specified by:
uploadNewCredentialsin interfaceILocalCluster- Specified by:
uploadNewCredentialsin interfaceNimbus.Iface- Parameters:
topologyName- the name of the topologycreds- the new credentails for the topology.- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
killTopology
Description copied from interface:ILocalClusterKill a topology (if you are not using ILocalTopology).- Specified by:
killTopologyin interfaceILocalCluster- Specified by:
killTopologyin interfaceNimbus.Iface- Parameters:
topologyName- the name of the topology- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
killTopologyWithOpts
public void killTopologyWithOpts(String name, KillOptions options) throws org.apache.storm.thrift.TException Description copied from interface:ILocalClusterKill a topology (if you are not using ILocalTopology).- Specified by:
killTopologyWithOptsin interfaceILocalCluster- Specified by:
killTopologyWithOptsin interfaceNimbus.Iface- Parameters:
name- the name of the topologyoptions- for how to kill the topology- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
activate
Description copied from interface:ILocalClusterActivate a topology.- Specified by:
activatein interfaceILocalCluster- Specified by:
activatein interfaceNimbus.Iface- Parameters:
topologyName- the name of the topology to activate- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
deactivate
Description copied from interface:ILocalClusterDeactivate a topology.- Specified by:
deactivatein interfaceILocalCluster- Specified by:
deactivatein interfaceNimbus.Iface- Parameters:
topologyName- the name of the topology to deactivate- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
rebalance
public void rebalance(String name, RebalanceOptions options) throws org.apache.storm.thrift.TException Description copied from interface:ILocalClusterRebalance a topology.- Specified by:
rebalancein interfaceILocalCluster- Specified by:
rebalancein interfaceNimbus.Iface- Parameters:
name- the name of the topologyoptions- options for rebalanceing the topology.- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
shutdown
public void shutdown()Description copied from interface:ILocalClusterShut down the cluster.- Specified by:
shutdownin interfaceILocalCluster
-
getTopologyConf
Description copied from interface:ILocalClusterThe config of a topology as a JSON string.- Specified by:
getTopologyConfin interfaceILocalCluster- Specified by:
getTopologyConfin interfaceNimbus.Iface- Parameters:
id- the id of the topology (not the name)- Returns:
- The config of a topology as a JSON string
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
getTopology
Description copied from interface:ILocalClusterGet the compiled storm topology.- Specified by:
getTopologyin interfaceILocalCluster- Specified by:
getTopologyin interfaceNimbus.Iface- Parameters:
id- the id of the topology (not the name)- Returns:
- the compiled storm topology
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
getClusterInfo
Description copied from interface:ILocalClusterGet cluster information.- Specified by:
getClusterInfoin interfaceILocalCluster- Specified by:
getClusterInfoin interfaceNimbus.Iface- Returns:
- a summary of the current state of the cluster
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
getTopologySummaries
- Specified by:
getTopologySummariesin interfaceILocalCluster- Specified by:
getTopologySummariesin interfaceNimbus.Iface- Throws:
org.apache.storm.thrift.TException
-
getTopologySummaryByName
public TopologySummary getTopologySummaryByName(String name) throws org.apache.storm.thrift.TException - Specified by:
getTopologySummaryByNamein interfaceILocalCluster- Specified by:
getTopologySummaryByNamein interfaceNimbus.Iface- Throws:
org.apache.storm.thrift.TException
-
getTopologySummary
- Specified by:
getTopologySummaryin interfaceILocalCluster- Specified by:
getTopologySummaryin interfaceNimbus.Iface- Throws:
org.apache.storm.thrift.TException
-
getTopologyInfo
Description copied from interface:ILocalClusterGet the state of a topology.- Specified by:
getTopologyInfoin interfaceILocalCluster- Specified by:
getTopologyInfoin interfaceNimbus.Iface- Parameters:
id- the id of the topology (not the name)- Returns:
- the state of a topology
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
getTopologyInfoByName
Description copied from interface:ILocalClusterGet the state of a topology.- Specified by:
getTopologyInfoByNamein interfaceILocalCluster- Specified by:
getTopologyInfoByNamein interfaceNimbus.Iface- Parameters:
name- the name of the topology (not the id)- Returns:
- the state of a topology
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
getTopologyInfoWithOpts
public TopologyInfo getTopologyInfoWithOpts(String id, GetInfoOptions options) throws org.apache.storm.thrift.TException Description copied from interface:ILocalClusterGet the state of a topology.- Specified by:
getTopologyInfoWithOptsin interfaceILocalCluster- Specified by:
getTopologyInfoWithOptsin interfaceNimbus.Iface- Parameters:
id- the id of the topology (not the name)options- This is to choose number of Error(s) in TopologyInfo.- Returns:
- the state of a topology
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
getTopologyInfoByNameWithOpts
public TopologyInfo getTopologyInfoByNameWithOpts(String name, GetInfoOptions options) throws org.apache.storm.thrift.TException Description copied from interface:ILocalClusterGet the state of a topology.- Specified by:
getTopologyInfoByNameWithOptsin interfaceILocalCluster- Specified by:
getTopologyInfoByNameWithOptsin interfaceNimbus.Iface- Parameters:
name- the name of the topology (not the id)options- This is GetInfoOptions to choose Error(s) in on TopologyInfo.- Returns:
- the state of a topology
- Throws:
org.apache.storm.thrift.TException- on any error from nimbus
-
getThriftServerPort
public int getThriftServerPort() -
isRemoteBlobExists
public boolean isRemoteBlobExists(String blobKey) throws AuthorizationException, org.apache.storm.thrift.TException Description copied from interface:Nimbus.IfaceDecide if the blob is removed from cluster.- Specified by:
isRemoteBlobExistsin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
close
- Specified by:
closein interfaceAutoCloseable- Throws:
Exception
-
getSupervisor
Get a specific Supervisor. This is intended mostly for internal testing.- Parameters:
id- the id of the supervisor
-
killSupervisor
Kill a specific supervisor. This is intended mostly for internal testing.- Parameters:
id- the id of the supervisor
-
addSupervisor
Add another supervisor to the topology. This is intended mostly for internal testing.- Throws:
Exception
-
addSupervisor
Add another supervisor to the topology. This is intended mostly for internal testing.- Parameters:
ports- the number of ports/slots the supervisor should have- Throws:
Exception
-
addSupervisor
Add another supervisor to the topology. This is intended mostly for internal testing.- Parameters:
ports- the number of ports/slots the supervisor should haveid- the id of the new supervisor, so you can find it later.- Throws:
Exception
-
addSupervisor
Add another supervisor to the topology. This is intended mostly for internal testing.- Parameters:
ports- the number of ports/slots the supervisor should haveconf- any config values that should be added/over written in the daemon conf of the cluster.id- the id of the new supervisor, so you can find it later.- Throws:
Exception
-
waitForIdle
Wait for the cluster to be idle. This is intended to be used with Simulated time and is for internal testing. Note that this does not wait for spout or bolt executors to be idle.- Throws:
InterruptedException- if interrupted while waiting.AssertionError- if the cluster did not come to an idle point with a timeout.
-
waitForIdle
Wait for the cluster to be idle. This is intended to be used with Simulated time and is for internal testing. Note that this does not wait for spout or bolt executors to be idle.- Parameters:
timeoutMs- the number of ms to wait before throwing an error.- Throws:
InterruptedException- if interrupted while waiting.AssertionError- if the cluster did not come to an idle point with a timeout.
-
advanceClusterTime
Description copied from interface:ILocalClusterAdvance the cluster time when the cluster is using SimulatedTime. This is intended for internal testing only.- Specified by:
advanceClusterTimein interfaceILocalCluster- Parameters:
secs- the number of seconds to advance time- Throws:
InterruptedException
-
advanceClusterTime
Description copied from interface:ILocalClusterAdvance the cluster time when the cluster is using SimulatedTime. This is intended for internal testing only.- Specified by:
advanceClusterTimein interfaceILocalCluster- Parameters:
secs- the number of seconds to advance timeincSecs- the number of steps we should take when advancing simulated time- Throws:
InterruptedException
-
getClusterState
Description copied from interface:ILocalClusterThis is intended for internal testing only.- Specified by:
getClusterStatein interfaceILocalCluster- Returns:
- an internal class that holds the state of the cluster.
-
getTrackedId
Description copied from interface:ILocalClusterIf the cluster is tracked get the id for the tracked cluster. This is intended for internal testing only.- Specified by:
getTrackedIdin interfaceILocalCluster- Returns:
- the id of the tracked cluster
-
setLogConfig
- Specified by:
setLogConfigin interfaceNimbus.Iface- Throws:
org.apache.storm.thrift.TException
-
getLogConfig
- Specified by:
getLogConfigin interfaceNimbus.Iface- Throws:
org.apache.storm.thrift.TException
-
debug
public void debug(String name, String component, boolean enable, double samplingPercentage) throws NotAliveException, AuthorizationException, org.apache.storm.thrift.TException Description copied from interface:Nimbus.IfaceEnable/disable logging the tuples generated in topology via an internal EventLogger bolt. The component name is optional and if null or empty, the debug flag will apply to the entire topology. The 'samplingPercentage' will limit loggging to a percentage of generated tuples.- Specified by:
debugin interfaceNimbus.Iface- Throws:
NotAliveExceptionAuthorizationExceptionorg.apache.storm.thrift.TException
-
setWorkerProfiler
public void setWorkerProfiler(String id, ProfileRequest profileRequest) throws org.apache.storm.thrift.TException - Specified by:
setWorkerProfilerin interfaceNimbus.Iface- Throws:
org.apache.storm.thrift.TException
-
getComponentPendingProfileActions
public List<ProfileRequest> getComponentPendingProfileActions(String id, String componentId, ProfileAction action) throws org.apache.storm.thrift.TException - Specified by:
getComponentPendingProfileActionsin interfaceNimbus.Iface- Throws:
org.apache.storm.thrift.TException
-
beginCreateBlob
public String beginCreateBlob(String key, SettableBlobMeta meta) throws AuthorizationException, KeyAlreadyExistsException, org.apache.storm.thrift.TException - Specified by:
beginCreateBlobin interfaceNimbus.Iface- Throws:
AuthorizationExceptionKeyAlreadyExistsExceptionorg.apache.storm.thrift.TException
-
beginUpdateBlob
public String beginUpdateBlob(String key) throws AuthorizationException, KeyNotFoundException, org.apache.storm.thrift.TException - Specified by:
beginUpdateBlobin interfaceNimbus.Iface- Throws:
AuthorizationExceptionKeyNotFoundExceptionorg.apache.storm.thrift.TException
-
uploadBlobChunk
public void uploadBlobChunk(String session, ByteBuffer chunk) throws AuthorizationException, org.apache.storm.thrift.TException - Specified by:
uploadBlobChunkin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
finishBlobUpload
public void finishBlobUpload(String session) throws AuthorizationException, org.apache.storm.thrift.TException - Specified by:
finishBlobUploadin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
cancelBlobUpload
public void cancelBlobUpload(String session) throws AuthorizationException, org.apache.storm.thrift.TException - Specified by:
cancelBlobUploadin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
getBlobMeta
public ReadableBlobMeta getBlobMeta(String key) throws AuthorizationException, KeyNotFoundException, org.apache.storm.thrift.TException - Specified by:
getBlobMetain interfaceNimbus.Iface- Throws:
AuthorizationExceptionKeyNotFoundExceptionorg.apache.storm.thrift.TException
-
setBlobMeta
public void setBlobMeta(String key, SettableBlobMeta meta) throws AuthorizationException, KeyNotFoundException, org.apache.storm.thrift.TException - Specified by:
setBlobMetain interfaceNimbus.Iface- Throws:
AuthorizationExceptionKeyNotFoundExceptionorg.apache.storm.thrift.TException
-
beginBlobDownload
public BeginDownloadResult beginBlobDownload(String key) throws AuthorizationException, KeyNotFoundException, org.apache.storm.thrift.TException - Specified by:
beginBlobDownloadin interfaceNimbus.Iface- Throws:
AuthorizationExceptionKeyNotFoundExceptionorg.apache.storm.thrift.TException
-
downloadBlobChunk
public ByteBuffer downloadBlobChunk(String session) throws AuthorizationException, org.apache.storm.thrift.TException - Specified by:
downloadBlobChunkin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
deleteBlob
public void deleteBlob(String key) throws AuthorizationException, KeyNotFoundException, org.apache.storm.thrift.TException - Specified by:
deleteBlobin interfaceNimbus.Iface- Throws:
AuthorizationExceptionKeyNotFoundExceptionorg.apache.storm.thrift.TException
-
listBlobs
- Specified by:
listBlobsin interfaceNimbus.Iface- Throws:
org.apache.storm.thrift.TException
-
getBlobReplication
public int getBlobReplication(String key) throws AuthorizationException, KeyNotFoundException, org.apache.storm.thrift.TException - Specified by:
getBlobReplicationin interfaceNimbus.Iface- Throws:
AuthorizationExceptionKeyNotFoundExceptionorg.apache.storm.thrift.TException
-
updateBlobReplication
public int updateBlobReplication(String key, int replication) throws AuthorizationException, KeyNotFoundException, org.apache.storm.thrift.TException - Specified by:
updateBlobReplicationin interfaceNimbus.Iface- Throws:
AuthorizationExceptionKeyNotFoundExceptionorg.apache.storm.thrift.TException
-
createStateInZookeeper
- Specified by:
createStateInZookeeperin interfaceNimbus.Iface- Throws:
org.apache.storm.thrift.TException
-
beginFileUpload
- Specified by:
beginFileUploadin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
uploadChunk
public void uploadChunk(String location, ByteBuffer chunk) throws AuthorizationException, org.apache.storm.thrift.TException - Specified by:
uploadChunkin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
finishFileUpload
public void finishFileUpload(String location) throws AuthorizationException, org.apache.storm.thrift.TException - Specified by:
finishFileUploadin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
downloadChunk
public ByteBuffer downloadChunk(String id) throws AuthorizationException, org.apache.storm.thrift.TException - Specified by:
downloadChunkin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
getNimbusConf
- Specified by:
getNimbusConfin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
getLeader
- Specified by:
getLeaderin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
isTopologyNameAllowed
public boolean isTopologyNameAllowed(String name) throws AuthorizationException, org.apache.storm.thrift.TException - Specified by:
isTopologyNameAllowedin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
getTopologyPageInfo
public TopologyPageInfo getTopologyPageInfo(String id, String window, boolean isIncludeSys) throws NotAliveException, AuthorizationException, org.apache.storm.thrift.TException - Specified by:
getTopologyPageInfoin interfaceNimbus.Iface- Throws:
NotAliveExceptionAuthorizationExceptionorg.apache.storm.thrift.TException
-
getSupervisorPageInfo
public SupervisorPageInfo getSupervisorPageInfo(String id, String host, boolean isIncludeSys) throws NotAliveException, AuthorizationException, org.apache.storm.thrift.TException - Specified by:
getSupervisorPageInfoin interfaceNimbus.Iface- Throws:
NotAliveExceptionAuthorizationExceptionorg.apache.storm.thrift.TException
-
getComponentPageInfo
public ComponentPageInfo getComponentPageInfo(String topologyId, String componentId, String window, boolean isIncludeSys) throws NotAliveException, AuthorizationException, org.apache.storm.thrift.TException - Specified by:
getComponentPageInfoin interfaceNimbus.Iface- Throws:
NotAliveExceptionAuthorizationExceptionorg.apache.storm.thrift.TException
-
getUserTopology
public StormTopology getUserTopology(String id) throws NotAliveException, AuthorizationException, org.apache.storm.thrift.TException Description copied from interface:Nimbus.IfaceReturns the user specified topology as submitted originally. CompareNimbus.Iface.getTopology(String id).- Specified by:
getUserTopologyin interfaceNimbus.Iface- Throws:
NotAliveExceptionAuthorizationExceptionorg.apache.storm.thrift.TException
-
getTopologyHistory
public TopologyHistoryInfo getTopologyHistory(String user) throws AuthorizationException, org.apache.storm.thrift.TException - Specified by:
getTopologyHistoryin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
getOwnerResourceSummaries
public List<OwnerResourceSummary> getOwnerResourceSummaries(String owner) throws AuthorizationException, org.apache.storm.thrift.TException - Specified by:
getOwnerResourceSummariesin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
getSupervisorAssignments
public SupervisorAssignments getSupervisorAssignments(String node) throws AuthorizationException, org.apache.storm.thrift.TException Description copied from interface:Nimbus.IfaceGet assigned assignments for a specific supervisor- Specified by:
getSupervisorAssignmentsin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
sendSupervisorWorkerHeartbeats
public void sendSupervisorWorkerHeartbeats(SupervisorWorkerHeartbeats heartbeats) throws AuthorizationException, org.apache.storm.thrift.TException Description copied from interface:Nimbus.IfaceSend supervisor worker heartbeats for a specific supervisor- Specified by:
sendSupervisorWorkerHeartbeatsin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
sendSupervisorWorkerHeartbeat
public void sendSupervisorWorkerHeartbeat(SupervisorWorkerHeartbeat heatbeat) throws AuthorizationException, org.apache.storm.thrift.TException Description copied from interface:Nimbus.IfaceSend supervisor local worker heartbeat when a supervisor is unreachable- Specified by:
sendSupervisorWorkerHeartbeatin interfaceNimbus.Iface- Throws:
AuthorizationExceptionorg.apache.storm.thrift.TException
-
processWorkerMetrics
- Specified by:
processWorkerMetricsin interfaceNimbus.Iface- Throws:
org.apache.storm.thrift.TException
-