|
21 | 21 |
|
22 | 22 | import org.elasticsearch.action.admin.cluster.node.info.NodeInfo;
|
23 | 23 | import org.elasticsearch.action.admin.cluster.node.stats.NodeStats;
|
| 24 | +import org.elasticsearch.action.admin.cluster.node.stats.NodeStatsTests; |
24 | 25 | import org.elasticsearch.cluster.node.DiscoveryNode;
|
25 | 26 | import org.elasticsearch.common.network.NetworkModule;
|
26 | 27 | import org.elasticsearch.common.settings.Settings;
|
|
37 | 38 |
|
38 | 39 | import static java.util.Collections.emptyList;
|
39 | 40 | import static java.util.Collections.singletonList;
|
40 |
| -import static org.elasticsearch.action.admin.cluster.node.stats.NodeStatsTests.createNodeStats; |
41 | 41 | import static org.elasticsearch.common.xcontent.XContentHelper.toXContent;
|
42 | 42 | import static org.hamcrest.Matchers.equalTo;
|
43 | 43 |
|
@@ -67,10 +67,8 @@ public void testNetworkTypesToXContent() throws Exception {
|
67 | 67 | + "}", toXContent(stats, XContentType.JSON, randomBoolean()).utf8ToString());
|
68 | 68 | }
|
69 | 69 |
|
70 |
| - @AwaitsFix(bugUrl = "https://github.com/elastic/elasticsearch/issues/48684") |
71 | 70 | public void testIngestStats() throws Exception {
|
72 |
| - NodeStats nodeStats = createNodeStats(); |
73 |
| - |
| 71 | + NodeStats nodeStats = randomValueOtherThanMany(n -> n.getIngestStats() == null, NodeStatsTests::createNodeStats); |
74 | 72 | SortedMap<String, long[]> processorStats = new TreeMap<>();
|
75 | 73 | nodeStats.getIngestStats().getProcessorStats().values().forEach(l -> l.forEach(s -> processorStats.put(s.getType(),
|
76 | 74 | new long[] { s.getStats().getIngestCount(), s.getStats().getIngestFailedCount(),
|
|
0 commit comments