zentol commented on a change in pull request #16742: URL: https://github.com/apache/flink/pull/16742#discussion_r685026086
##########
File path:
flink-runtime/src/test/java/org/apache/flink/runtime/operators/chaining/ChainedOperatorsMetricTest.java
##########
@@ -68,22 +70,26 @@
public void testOperatorIOMetricReuse() throws Exception {
// environment
initEnvironment(MEMORY_MANAGER_SIZE, NETWORK_BUFFER_SIZE);
+
this.mockEnv =
new MockEnvironmentBuilder()
.setTaskName(HEAD_OPERATOR_NAME)
.setManagedMemorySize(MEMORY_MANAGER_SIZE)
.setInputSplitProvider(this.inputSplitProvider)
.setBufferSize(NETWORK_BUFFER_SIZE)
.setMetricGroup(
- new TaskMetricGroup(
- NoOpMetricRegistry.INSTANCE,
- UnregisteredMetricGroups
-
.createUnregisteredTaskManagerJobMetricGroup(),
- new JobVertexID(),
- new ExecutionAttemptID(),
- "task",
- 0,
- 0))
+ new TaskManagerJobMetricGroup(
+ NoOpMetricRegistry.INSTANCE,
+ UnregisteredMetricGroups
+
.createUnregisteredTaskManagerMetricGroup(),
+ new JobID(0, 0),
+ "UnregisteredJob")
+ .addTask(
+ new JobVertexID(),
+ new ExecutionAttemptID(),
+ "task",
+ 0,
+ 0))
Review comment:
```suggestion
MetricUtils.createTaskManagerMetricGroup(
NoOpMetricRegistry.INSTANCE,
"host",
ResourceID.generate())
.addTaskForJob(
new JobID(),
"jobname",
new JobVertexID(),
new ExecutionAttemptID(),
"task",
0,
0))
```
lets do it like this.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
