-
Notifications
You must be signed in to change notification settings - Fork 25.3k
Esql - Add planner information to the profile #124919
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
base: main
Are you sure you want to change the base?
Conversation
x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/plugin/CollectedProfiles.java
Outdated
Show resolved
Hide resolved
This is extremely work in progress at the moment. It's still littered with NOCOMMITs, I haven't written any tests yet, and I haven't even started on the actual profiling. I'm just pushing it up for some early feedback on how I plumbed the profile data through the query execution. |
…profile' into esql-planner-profile
Conflicts: server/src/main/java/org/elasticsearch/TransportVersions.java x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/plugin/ComputeResponse.java
@@ -346,18 +348,48 @@ public EsqlResponse responseInternal() { | |||
|
|||
public static class Profile implements Writeable, ChunkedToXContentObject { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NIT: I wonder if we could make this a record?
This way we could avoid custom equals/hashCode/toString.
Merge could be updated to return a new instance instead of mutating this one
* Stores profiling information about the query plan. This can be the top level planning on the coordinating node, or the local | ||
* planning on the data nodes. | ||
*/ | ||
public class PlannerProfile implements Writeable, ChunkedToXContentObject { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like this is still work in progress, but I would suggest we try to design it to be a record from the very beginning
Conflicts: server/src/main/java/org/elasticsearch/TransportVersions.java x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/execution/PlanExecutor.java x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/plugin/EsqlPlugin.java x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/plugin/TransportEsqlQueryAction.java x-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/telemetry/PlanExecutorMetricsTests.java
…profile' into esql-planner-profile
…profile' into esql-planner-profile Conflicts: x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/planner/PlannerProfile.java
This adds the ability to capture profile information about planning. It should cover both the initial coordinator level planning and the local replanning.