flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [flink] azagrebin commented on a change in pull request #8320: [FLINK-12201][network, metrics] Introduce InputGateWithMetrics in Task to increment numBytesIn metric
Date Fri, 31 May 2019 09:51:01 GMT
azagrebin commented on a change in pull request #8320: [FLINK-12201][network,metrics] Introduce
InputGateWithMetrics in Task to increment numBytesIn metric
URL: https://github.com/apache/flink/pull/8320#discussion_r289326550
 
 

 ##########
 File path: flink-streaming-java/src/test/java/org/apache/flink/streaming/runtime/io/benchmark/StreamNetworkBenchmarkEnvironment.java
 ##########
 @@ -270,4 +266,18 @@ private InputGateDeploymentDescriptor createInputGateDeploymentDescriptor(
 			consumedSubpartitionIndex,
 			channelDescriptors);
 	}
+
+	private InputGate createInputGateWithMetrics(
+		SingleInputGateFactory gateFactory,
+		InputGateDeploymentDescriptor gateDescriptor,
+		int channelIndex) {
+
+		final SingleInputGate singleGate = gateFactory.create(
+			"receiving task[" + channelIndex + "]",
+			gateDescriptor,
+			SingleInputGateBuilder.NO_OP_PRODUCER_CHECKER,
+			InputChannelTestUtils.newUnregisteredInputChannelMetrics());
+
+		return new InputGateWithMetrics(singleGate, new SimpleCounter());
 
 Review comment:
   I agree that `InputGateWithMetrics` does not belong to Netty implementation of shuffle
service this is why we are doing it change to keep this notification concern outside.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message