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

Update the opensearch-rails gem (RM-2427). #4

Merged
merged 21 commits into from
Feb 9, 2024

Conversation

martijnbolhuis
Copy link

@martijnbolhuis martijnbolhuis commented Feb 1, 2024

  • Ruby 3.2 support
  • Remove CI / CD support for unsupported Ruby & Rails versions
  • Ensure compatibility with opensearch-ruby 3

- Fix tests in opensearch-model: rspec mocks expects keyword arguments when
  using the syntax `with(options: 'value')` but the real code uses a `options`
  hash. Fixed by explicitly defining a `Hash` as the argument: `with({ options:
  'value'})`
- Add support for Rails 7.1 (wip).
- Fix pagination tests by including the `OpenSearch::Model::Importing`
  manually. Not sure why this is necessary.
- Fix `searching_search_request_spec.rb`: explicitly expect a options hash
  instead of keyword arguments when stubbing.
- Fix
  `opensearch-model/spec/opensearch/model/adapters/active_record/import_spec.rb`
  tests.
- Fix activerecord & mongoid tests.
- Fix namespaced_model_spec test.
- Remove support for unsupported Rails versions. At the time of writing from
  Rails 6.1 upwards is still supported [1].
- Set minimum supported Ruby version to 2.5 since this is the minimum supported
  version by Rails 6 [1].

[1]: https://www.fastruby.io/blog/ruby/rails/versions/compatibility-table.html
- Update opensearch-ruby from version 2 to 3.
- Make logger formatter for opensearch-model nil safe. It seems that sometimes
  a message (`m`) is `nil`.
- Remove github workflows for Ruby < 2.7.
- Add github workflow for Ruby 3.2 and (hopefully) fix 2.7 (untested).
- Update status badges in the README.
- Make logger formatter for opensearch-rails nil safe. It seems that sometimes
  a message (`m`) is `nil`.
- Fix an error in the 6.1.gemfile.
- Remove full backtrace printing in tests.
- Bump version from 1.0.0 to 1.1.0.
- Loosen opensearch-ruby dependency.
- Make dependencies on rails & ruby version less strict on second thought.
- Revert required ruby version.
@martijnbolhuis martijnbolhuis marked this pull request as ready for review February 9, 2024 09:29
Copy link

@RubenSmit RubenSmit left a comment

Choose a reason for hiding this comment

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

Ik zie geen rare dingen verder!

@martijnbolhuis martijnbolhuis merged commit b0493f2 into main Feb 9, 2024
4 checks passed
@martijnbolhuis martijnbolhuis deleted the feature/upgrade-2427 branch February 9, 2024 15:04
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.

2 participants