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

fix(mongodb): hide batch_size for mongodb resource #10998

Merged
merged 1 commit into from Jun 11, 2023

Conversation

zmstone
Copy link
Member

@zmstone zmstone commented Jun 9, 2023

MongoDB connector currently does not support batching so the batch_size option has no effect.
However we cannot remove the field, so we choose to hide it from schema

Fixes EMQX-10220

Summary

🤖 Generated by Copilot at bbf2993

Added resource_opts field to MongoDB bridge schema and modified create_opts function in emqx_resource_schema module. These changes make the MongoDB bridge consistent with other resource schemas and disable batching for MongoDB. Updated internationalization file for the batch_size field.

PR Checklist

Please convert it to a draft if any of the following conditions are not met. Reviewers may skip over until all the items are checked:

  • Added tests for the changes
  • Changed lines covered in coverage report
  • Change log has been added to changes/{ce,ee}/(feat|perf|fix)-<PR-id>.en.md files
  • For internal contributor: there is a jira ticket to track this change
  • If there should be document changes, a PR to emqx-docs.git is sent, or a jira ticket is created to follow up
  • Schema changes are backward compatible

Checklist for CI (.github/workflows) changes

  • If changed package build workflow, pass this action (manual trigger)
  • Change log has been added to changes/ dir for user-facing artifacts update

@zmstone zmstone requested a review from a team as a code owner June 9, 2023 14:36
ieQu1
ieQu1 previously approved these changes Jun 9, 2023
savonarola
savonarola previously approved these changes Jun 9, 2023
@zmstone zmstone force-pushed the 0609-no-batch-for-mongodb branch from bbf2993 to 2fb6e50 Compare June 9, 2023 16:26
MongoDB connector currently does not support batching
so the batch_size option has no effect.
However we cannot remove the field, so we choose to hide it from
schema
@zmstone zmstone changed the base branch from release-51 to master June 11, 2023 09:11
@zmstone zmstone dismissed stale reviews from thalesmg, savonarola, and ieQu1 June 11, 2023 09:11

The base branch was changed.

@zmstone zmstone merged commit e8ccdb8 into emqx:master Jun 11, 2023
107 of 108 checks passed
@zmstone zmstone deleted the 0609-no-batch-for-mongodb branch June 11, 2023 19:26
@yanzhiemq
Copy link
Collaborator

yanzhiemq commented Jun 13, 2023

Bug Fixes

  • Do not allow batch_size option for MongoDB bridge resource. MongoDB connector currently does not support batching, the bath_size config value is forced to be 1 if provided.

@yanzhiemq
Copy link
Collaborator

yanzhiemq commented Jun 13, 2023

修复

  • 不允许为 MongoDB 桥接资源设置 batch_size 选项。当前的 MongoDB 连接器不支持批量处理,如果提供了 batch_size 配置值,它将被强制设置为1。

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

Successfully merging this pull request may close these issues.

None yet

6 participants