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

[BUG] #977

Open
xavianaxw opened this issue Feb 14, 2025 · 3 comments
Open

[BUG] #977

xavianaxw opened this issue Feb 14, 2025 · 3 comments

Comments

@xavianaxw
Copy link

What is the bug?

Related to #956 , should aggs be supported in nested aggregations?

How can one reproduce the bug?

await client.search({
  index: 'news',
  body: {
    query: {
      bool: {
        filter: [
          { term: { 'locale.keyword': 'en' } },
        ],
      },
    },
    aggs: {
      spendAggregationsByCurrency: {
        terms: {
          field: 'currency.keyword',
        },
        aggs: { <-- throws error 'aggs' does not exist in type 'AggregationContainer'
          totalSpend: {
            sum: {
              field: 'adCost',
            },
          },
       }, 
    },
    size: 0,
  },
})

What is the expected behavior?

For aggs to be supported

Do you have any screenshots?

Image

Additional question

Considering the big release of opensearch-project v3 was revolved around the opensearch API specification generator, should it only support aggregations moving forward? or aggs is expected to continue working?

@dblock
Copy link
Member

dblock commented Feb 14, 2025

Considering the big release of opensearch-project v3 was revolved around the opensearch API specification generator, should it only support aggregations moving forward? or aggs is expected to continue working?

If the server still supports it then yes. Please do contribute!

@xavianaxw
Copy link
Author

Shall we close this issue @Xtansia ?

@Xtansia
Copy link
Contributor

Xtansia commented Feb 25, 2025

@xavianaxw Should likely leave the issue open until the changed spec actually gets pulled in via the next code generation run. (cc @nhtruong)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants