Skip to content

[FLINK-4784] Unique MetricQueryService actor names#2636

Closed
zentol wants to merge 4 commits into
apache:masterfrom
zentol:4784_metrics_actor_names
Closed

[FLINK-4784] Unique MetricQueryService actor names#2636
zentol wants to merge 4 commits into
apache:masterfrom
zentol:4784_metrics_actor_names

Conversation

@zentol
Copy link
Copy Markdown
Contributor

@zentol zentol commented Oct 14, 2016

This PR makes the MetricQueryService actor name unique by appending the TaskManagers resource id. For the jobmanager nothing is appended.

Copy link
Copy Markdown
Contributor

@rmetzger rmetzger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had one comment. Other than that, the PR is good to be merged.


String taskManagerPath = taskManager.getActorGateway().path();
String queryServicePath = taskManagerPath.substring(0, taskManagerPath.lastIndexOf('/') + 1) + "MetricQueryService";
String queryServicePath = taskManagerPath.substring(0, taskManagerPath.lastIndexOf('/') + 1) + "MetricQueryService_" + taskManager.getTaskManagerID().toString();
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You could use the MetricQueryService.METRIC_QUERY_SERVICE_NAME constant here

@rmetzger
Copy link
Copy Markdown
Contributor

I tested the change this morning, and its not working:

2016-10-20 11:08:28,216 WARN  org.apache.flink.runtime.metrics.MetricRegistry               - Could not start Metr
icDumpActor. No metrics will be submitted to the WebInterface.
akka.actor.InvalidActorNameException: illegal actor name [MetricQueryService_ResourceID{resourceId='e29f9e7d096c56
2054a1caa29be21a36'}], must conform to (?:[-\w:@&=+,.!~*'_;]|%\p{XDigit}{2})(?:[-\w:@&=+,.!~*'$_;]|%\p{XDigit}{2})
*
        at akka.actor.dungeon.Children$class.checkName(Children.scala:182)
        at akka.actor.dungeon.Children$class.attachChild(Children.scala:42)
        at akka.actor.ActorCell.attachChild(ActorCell.scala:369)
        at akka.actor.ActorSystemImpl.actorOf(ActorSystem.scala:553)

@zentol
Copy link
Copy Markdown
Contributor Author

zentol commented Oct 20, 2016

should be fixed now

@rmetzger
Copy link
Copy Markdown
Contributor

Thank you

The change is good to merge!

@asfgit asfgit closed this in 3ab97ae Oct 21, 2016
@zentol zentol deleted the 4784_metrics_actor_names branch October 21, 2016 10:07
liuyuzhong pushed a commit to liuyuzhong/flink that referenced this pull request Dec 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants