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] Builder API #202113

Open
2 tasks
vadimkibana opened this issue Nov 28, 2024 · 1 comment
Open
2 tasks

[ES|QL] Builder API #202113

vadimkibana opened this issue Nov 28, 2024 · 1 comment
Labels
Feature:ES|QL ES|QL related features in Kibana Team:ESQL ES|QL related features in Kibana

Comments

@vadimkibana
Copy link
Contributor

vadimkibana commented Nov 28, 2024

The Builder API in @kbn/esql-ast allows to create raw AST nodes, finalize it:

  • Go through all nodes types, and make sure the Builder supports all nodes types.
  • In parser/ use Builder for all node construction.
@vadimkibana vadimkibana added Feature:ES|QL ES|QL related features in Kibana Team:ESQL ES|QL related features in Kibana labels Nov 28, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-esql (Team:ESQL)

vadimkibana added a commit that referenced this issue Dec 13, 2024
## Summary

Partially addresses #202113

- Makes sure it is possible to construct any AST using the `Builder`
class
- Fixes few bugs in pretty-printer
- No space is added before unary `-` or `+` expression, for example,
`-123`.
  - Source cluster is now printed `cluster:my_index` 


### Checklist

- [x]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
kibanamachine pushed a commit to kibanamachine/kibana that referenced this issue Dec 13, 2024
## Summary

Partially addresses elastic#202113

- Makes sure it is possible to construct any AST using the `Builder`
class
- Fixes few bugs in pretty-printer
- No space is added before unary `-` or `+` expression, for example,
`-123`.
  - Source cluster is now printed `cluster:my_index`

### Checklist

- [x]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

(cherry picked from commit 8904cb0)
CAWilson94 pushed a commit to CAWilson94/kibana that referenced this issue Jan 13, 2025
## Summary

Partially addresses elastic#202113

- Makes sure it is possible to construct any AST using the `Builder`
class
- Fixes few bugs in pretty-printer
- No space is added before unary `-` or `+` expression, for example,
`-123`.
  - Source cluster is now printed `cluster:my_index` 


### Checklist

- [x]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:ES|QL ES|QL related features in Kibana Team:ESQL ES|QL related features in Kibana
Projects
None yet
Development

No branches or pull requests

2 participants