spark_plugin.py
def read(self):
        """
        Makes API calls for cluster level metrics
        related to master and worker nodes
        and posts them to SignalFx
        """
        if self.master_port:
            master = self.metric_address + ":" + self.master_port
            master_resp = self.spark_agent.request_metrics(master, MASTER_PATH)
            master_metrics = self.get_metrics(master_resp, "master")
            self.post_metrics(master_metrics)

        if self.worker_ports:
            for worker_port in self.worker_ports:
                worker = self.metric_address + ":" + worker_port
                worker_resp = self.spark_agent.request_metrics(worker, WORKER_PATH)
                worker_metrics = self.get_metrics(worker_resp, "worker", worker_port)
                self.post_metrics(worker_metrics)

        Makes API calls for cluster level metrics
        related to master and worker nodes
        and posts them to SignalFx
        
Makes API calls for cluster level metrics
related to master and worker nodes
and posts them to SignalFx
Makes API calls for cluster level metrics related to master and worker nodes and posts them to SignalFx
def read(self):
        if self.master_port:
            master = self.metric_address + ":" + self.master_port
            master_resp = self.spark_agent.request_metrics(master, MASTER_PATH)
            master_metrics = self.get_metrics(master_resp, "master")
            self.post_metrics(master_metrics)
        if self.worker_ports:
            for worker_port in self.worker_ports:
                worker = self.metric_address + ":" + worker_port
                worker_resp = self.spark_agent.request_metrics(worker, WORKER_PATH)
                worker_metrics = self.get_metrics(worker_resp, "worker", worker_port)
                self.post_metrics(worker_metrics)
def read ( self ) : if self . master_port : master = self . metric_address + ":" + self . master_port master_resp = self . spark_agent . request_metrics ( master , MASTER_PATH ) master_metrics = self . get_metrics ( master_resp , "master" ) self . post_metrics ( master_metrics ) if self . worker_ports : for worker_port in self . worker_ports : worker = self . metric_address + ":" + worker_port worker_resp = self . spark_agent . request_metrics ( worker , WORKER_PATH ) worker_metrics = self . get_metrics ( worker_resp , "worker" , worker_port ) self . post_metrics ( worker_metrics )
Makes API calls for cluster level metrics
related to master and worker nodes
and posts them to SignalFx
Makes API calls for cluster level metrics related to master and worker nodes and posts them to SignalFx
"""
        Makes API calls for cluster level metrics
        related to master and worker nodes
        and posts them to SignalFx
        """
self