Skip to content

Commit

Permalink
Release 0.3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
fatkodima committed Nov 3, 2024
1 parent bb206b4 commit 99ea6a1
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 2 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
## master (unreleased)

## 0.3.0 (2024-11-03)

- Support plucking custom Arel columns

```ruby
User.pluck_in_batches(:id, Arel.sql("json_extract(users.metadata, '$.rank')"))
```

## 0.2.0 (2023-07-24)

- Support specifying per cursor column ordering when batching
Expand Down
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
pluck_in_batches (0.2.0)
pluck_in_batches (0.3.0)
activerecord (>= 6.0)

GEM
Expand Down
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,11 @@ User.pluck_in_batches(:name, :email).with_index do |group, index|
jobs = group.map { |name, email| PartyReminderJob.new(name, email) }
ActiveJob.perform_all_later(jobs)
end

# Custom arel column
User.pluck_in_batches(:id, Arel.sql("json_extract(users.metadata, '$.rank')")).with_index do |group, index|
# ...
end
```

Both methods support the following configuration options:
Expand Down
2 changes: 1 addition & 1 deletion lib/pluck_in_batches/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module PluckInBatches
VERSION = "0.2.0"
VERSION = "0.3.0"
end

0 comments on commit 99ea6a1

Please sign in to comment.