Skip to content

Remove network stats & info #12054

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 7, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.http.HttpInfo;
import org.elasticsearch.monitor.jvm.JvmInfo;
import org.elasticsearch.monitor.network.NetworkInfo;
import org.elasticsearch.monitor.os.OsInfo;
import org.elasticsearch.monitor.process.ProcessInfo;
import org.elasticsearch.threadpool.ThreadPoolInfo;
Expand Down Expand Up @@ -65,9 +64,6 @@ public class NodeInfo extends BaseNodeResponse {
@Nullable
private ThreadPoolInfo threadPool;

@Nullable
private NetworkInfo network;

@Nullable
private TransportInfo transport;

Expand All @@ -81,7 +77,7 @@ public class NodeInfo extends BaseNodeResponse {
}

public NodeInfo(Version version, Build build, DiscoveryNode node, @Nullable ImmutableMap<String, String> serviceAttributes, @Nullable Settings settings,
@Nullable OsInfo os, @Nullable ProcessInfo process, @Nullable JvmInfo jvm, @Nullable ThreadPoolInfo threadPool, @Nullable NetworkInfo network,
@Nullable OsInfo os, @Nullable ProcessInfo process, @Nullable JvmInfo jvm, @Nullable ThreadPoolInfo threadPool,
@Nullable TransportInfo transport, @Nullable HttpInfo http, @Nullable PluginsInfo plugins) {
super(node);
this.version = version;
Expand All @@ -92,7 +88,6 @@ public NodeInfo(Version version, Build build, DiscoveryNode node, @Nullable Immu
this.process = process;
this.jvm = jvm;
this.threadPool = threadPool;
this.network = network;
this.transport = transport;
this.http = http;
this.plugins = plugins;
Expand Down Expand Up @@ -165,14 +160,6 @@ public ThreadPoolInfo getThreadPool() {
return this.threadPool;
}

/**
* Network level information.
*/
@Nullable
public NetworkInfo getNetwork() {
return network;
}

@Nullable
public TransportInfo getTransport() {
return transport;
Expand Down Expand Up @@ -222,9 +209,6 @@ public void readFrom(StreamInput in) throws IOException {
if (in.readBoolean()) {
threadPool = ThreadPoolInfo.readThreadPoolInfo(in);
}
if (in.readBoolean()) {
network = NetworkInfo.readNetworkInfo(in);
}
if (in.readBoolean()) {
transport = TransportInfo.readTransportInfo(in);
}
Expand Down Expand Up @@ -281,12 +265,6 @@ public void writeTo(StreamOutput out) throws IOException {
out.writeBoolean(true);
threadPool.writeTo(out);
}
if (network == null) {
out.writeBoolean(false);
} else {
out.writeBoolean(true);
network.writeTo(out);
}
if (transport == null) {
out.writeBoolean(false);
} else {
Expand All @@ -306,5 +284,4 @@ public void writeTo(StreamOutput out) throws IOException {
plugins.writeTo(out);
}
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -111,9 +111,6 @@ public XContentBuilder toXContent(XContentBuilder builder, Params params) throws
if (nodeInfo.getThreadPool() != null) {
nodeInfo.getThreadPool().toXContent(builder, params);
}
if (nodeInfo.getNetwork() != null) {
nodeInfo.getNetwork().toXContent(builder, params);
}
if (nodeInfo.getTransport() != null) {
nodeInfo.getTransport().toXContent(builder, params);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
import org.elasticsearch.indices.breaker.AllCircuitBreakerStats;
import org.elasticsearch.monitor.fs.FsStats;
import org.elasticsearch.monitor.jvm.JvmStats;
import org.elasticsearch.monitor.network.NetworkStats;
import org.elasticsearch.monitor.os.OsStats;
import org.elasticsearch.monitor.process.ProcessStats;
import org.elasticsearch.threadpool.ThreadPoolStats;
Expand Down Expand Up @@ -62,9 +61,6 @@ public class NodeStats extends BaseNodeResponse implements ToXContent {
@Nullable
private ThreadPoolStats threadPool;

@Nullable
private NetworkStats network;

@Nullable
private FsStats fs;

Expand All @@ -82,7 +78,7 @@ public class NodeStats extends BaseNodeResponse implements ToXContent {

public NodeStats(DiscoveryNode node, long timestamp, @Nullable NodeIndicesStats indices,
@Nullable OsStats os, @Nullable ProcessStats process, @Nullable JvmStats jvm, @Nullable ThreadPoolStats threadPool,
@Nullable NetworkStats network, @Nullable FsStats fs, @Nullable TransportStats transport, @Nullable HttpStats http,
@Nullable FsStats fs, @Nullable TransportStats transport, @Nullable HttpStats http,
@Nullable AllCircuitBreakerStats breaker) {
super(node);
this.timestamp = timestamp;
Expand All @@ -91,7 +87,6 @@ public NodeStats(DiscoveryNode node, long timestamp, @Nullable NodeIndicesStats
this.process = process;
this.jvm = jvm;
this.threadPool = threadPool;
this.network = network;
this.fs = fs;
this.transport = transport;
this.http = http;
Expand Down Expand Up @@ -147,14 +142,6 @@ public ThreadPoolStats getThreadPool() {
return this.threadPool;
}

/**
* Network level statistics.
*/
@Nullable
public NetworkStats getNetwork() {
return network;
}

/**
* File system level stats.
*/
Expand Down Expand Up @@ -203,9 +190,6 @@ public void readFrom(StreamInput in) throws IOException {
if (in.readBoolean()) {
threadPool = ThreadPoolStats.readThreadPoolStats(in);
}
if (in.readBoolean()) {
network = NetworkStats.readNetworkStats(in);
}
if (in.readBoolean()) {
fs = FsStats.readFsStats(in);
}
Expand Down Expand Up @@ -253,12 +237,6 @@ public void writeTo(StreamOutput out) throws IOException {
out.writeBoolean(true);
threadPool.writeTo(out);
}
if (network == null) {
out.writeBoolean(false);
} else {
out.writeBoolean(true);
network.writeTo(out);
}
if (fs == null) {
out.writeBoolean(false);
} else {
Expand Down Expand Up @@ -313,9 +291,6 @@ public XContentBuilder toXContent(XContentBuilder builder, Params params) throws
if (getThreadPool() != null) {
getThreadPool().toXContent(builder, params);
}
if (getNetwork() != null) {
getNetwork().toXContent(builder, params);
}
if (getFs() != null) {
getFs().toXContent(builder, params);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,6 @@
import org.elasticsearch.monitor.fs.JmxFsProbe;
import org.elasticsearch.monitor.jvm.JvmMonitorService;
import org.elasticsearch.monitor.jvm.JvmService;
import org.elasticsearch.monitor.network.JmxNetworkProbe;
import org.elasticsearch.monitor.network.NetworkProbe;
import org.elasticsearch.monitor.network.NetworkService;
import org.elasticsearch.monitor.os.JmxOsProbe;
import org.elasticsearch.monitor.os.OsProbe;
import org.elasticsearch.monitor.os.OsService;
Expand Down Expand Up @@ -56,13 +53,11 @@ protected void configure() {
// bind default implementations
bind(ProcessProbe.class).to(JmxProcessProbe.class).asEagerSingleton();
bind(OsProbe.class).to(JmxOsProbe.class).asEagerSingleton();
bind(NetworkProbe.class).to(JmxNetworkProbe.class).asEagerSingleton();
bind(FsProbe.class).to(JmxFsProbe.class).asEagerSingleton();

// bind other services
bind(ProcessService.class).asEagerSingleton();
bind(OsService.class).asEagerSingleton();
bind(NetworkService.class).asEagerSingleton();
bind(JvmService.class).asEagerSingleton();
bind(FsService.class).asEagerSingleton();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
import org.elasticsearch.monitor.fs.FsService;
import org.elasticsearch.monitor.jvm.JvmMonitorService;
import org.elasticsearch.monitor.jvm.JvmService;
import org.elasticsearch.monitor.network.NetworkService;
import org.elasticsearch.monitor.os.OsService;
import org.elasticsearch.monitor.process.ProcessService;

Expand All @@ -42,20 +41,17 @@ public class MonitorService extends AbstractLifecycleComponent<MonitorService> {

private final JvmService jvmService;

private final NetworkService networkService;

private final FsService fsService;

@Inject
public MonitorService(Settings settings, JvmMonitorService jvmMonitorService,
OsService osService, ProcessService processService, JvmService jvmService, NetworkService networkService,
OsService osService, ProcessService processService, JvmService jvmService,
FsService fsService) {
super(settings);
this.jvmMonitorService = jvmMonitorService;
this.osService = osService;
this.processService = processService;
this.jvmService = jvmService;
this.networkService = networkService;
this.fsService = fsService;
}

Expand All @@ -71,10 +67,6 @@ public JvmService jvmService() {
return this.jvmService;
}

public NetworkService networkService() {
return this.networkService;
}

public FsService fsService() {
return this.fsService;
}
Expand Down

This file was deleted.

Loading