Skip to content
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

[ES|QL] Generate docs for unregistered esql functions from annotations #108749

Conversation

fang-xing-esql
Copy link
Member

This is a subtask of #104247 , covers operators that are unregistered functions.

@fang-xing-esql fang-xing-esql added >docs General docs changes :Analytics/ES|QL AKA ESQL ES|QL-ui Impacts ES|QL UI v8.15.0 labels May 17, 2024
Copy link
Contributor

Documentation preview:

@fang-xing-esql fang-xing-esql marked this pull request as ready for review May 21, 2024 21:30
@elasticsearchmachine elasticsearchmachine added Team:Docs Meta label for docs team Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo) labels May 21, 2024
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-docs (Team:Docs)

@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-analytical-engine (Team:Analytics)

@nik9000
Copy link
Member

nik9000 commented May 24, 2024

The docs don't quite look right:
image
It has both the "equality (==)" bit and the EQUALS bit. I'm not sure what's up there.

@nik9000
Copy link
Member

nik9000 commented May 24, 2024

This is heroic work, btw. Thanks so much for it.

@fang-xing-esql
Copy link
Member Author

The docs don't quite look right: image It has both the "equality (==)" bit and the EQUALS bit. I'm not sure what's up there.

I'll remove one of them.

@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/kibana-esql (ES|QL-ui)

Copy link
Member

@nik9000 nik9000 left a comment

Choose a reason for hiding this comment

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

Awesome!

I left a question about IN being registered in the function registry.

I haven't double checked that the rendered docs are good, but I assume you have so that's probably fine.

def(Split.class, Split::new, "split") } };
def(Split.class, Split::new, "split") },
// Operators
new FunctionDefinition[] { def(In.class, In::new, "in") } };
Copy link
Member

Choose a reason for hiding this comment

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

Does this mean you can use it like WHERE IN(blah, "foo", "bar", "baz") now? Do we want that?

Copy link
Member Author

Choose a reason for hiding this comment

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

Does this mean you can use it like WHERE IN(blah, "foo", "bar", "baz") now? Do we want that?

I don't think we want this syntax, it is just for doc generation.

Copy link
Member

Choose a reason for hiding this comment

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

Probably best to zap this from EsqlFunctionRegistry then.

@nik9000
Copy link
Member

nik9000 commented Jul 22, 2024

Rendered docs look great!

@fang-xing-esql
Copy link
Member Author

Rendered docs look great!

Thank you for reviewing @nik9000 !

@fang-xing-esql fang-xing-esql merged commit 66dd268 into elastic:main Jul 22, 2024
15 checks passed
@fang-xing-esql fang-xing-esql deleted the generate-docs-for-unregistered-esql-functions branch July 22, 2024 18:58
salvatore-campagna pushed a commit to salvatore-campagna/elasticsearch that referenced this pull request Jul 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Analytics/ES|QL AKA ESQL >docs General docs changes ES|QL-ui Impacts ES|QL UI Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo) Team:Docs Meta label for docs team v8.16.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants