panko_serializer 0.7.4 → 0.7.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1cbaf86b0b95041f6f3387c8d82cc8ef1fa272549e50b5d3fdac2d13989f1a29
4
- data.tar.gz: 41496c877bee39fa9fe7f136469ea260c1c60feeb25c6f95930b8c13a9055b3c
3
+ metadata.gz: a55772372c4ae9e4d147a131c5dd59090b7dc928adc5e6830403246918fdb90b
4
+ data.tar.gz: e6ee39b058b87b81d19385d4ae03fb938e2c04859641499454ca7debe99aceb9
5
5
  SHA512:
6
- metadata.gz: 2c30cbbde27a0ff4cead7b0763c1a76d0d179053e7d913ac81594eedb50defee858792d0893e19a42bd5b5ea71e6c5e4ed2cc3371a2d48d1dce4d53737a4d584
7
- data.tar.gz: 0dd1443b07977c1eea6457016f4db43d88fcf857ea607bf9064b72485e4f7d78e0ffcf39fe1f9b83456c0477da3988ee6a392730bfe84565d266816484e01589
6
+ metadata.gz: eac9a9cad9ca9b99146527c25a935347b51a110ab36b0bc58165c961780415068c9899ebbe15ec3eb594a112d18665c54b5d5afd77ebd2449b078faa85e37981
7
+ data.tar.gz: 87081d7cc24b5a69b3c409232abedb79daab75c263aea45b405d24ef71570df0c10f8821a741f88bb4e690d38b802bd6f43a82c0cee4a5e24d0ebba04849318a
@@ -19,14 +19,14 @@ jobs:
19
19
  - name: Use Node.js ${{ matrix.node-version }}
20
20
  uses: actions/setup-node@v1
21
21
  with:
22
- node-version: '12.x'
22
+ node-version: '16.x'
23
23
 
24
24
  - name: Install Dependencies
25
25
  working-directory: ${{ env.working_directory }}
26
26
  run: npm install
27
27
 
28
28
  - name: Install SSH Client 🔑
29
- uses: webfactory/ssh-agent@v0.2.0
29
+ uses: webfactory/ssh-agent@v0.4.1
30
30
  with:
31
31
  ssh-private-key: ${{ secrets.DEPLOY_KEY }}
32
32
 
@@ -9,21 +9,24 @@ jobs:
9
9
  strategy:
10
10
  fail-fast: false
11
11
  matrix:
12
- ruby: [ '2.5', '2.6', '2.7']
13
- rails: ['5.2.0', '6.0.0', '6.1.0rc1']
12
+ ruby: ['2.6', '2.7', '3.0', '3.1.0']
13
+ rails: ['6.0.0', '6.1.0', '7.0.0']
14
+ exclude:
15
+ - ruby: '2.6'
16
+ rails: '7.0.0'
14
17
 
15
18
  steps:
16
19
  - uses: actions/checkout@v2
17
20
  - name: Set up Ruby ${{ matrix.ruby }}
18
- uses: actions/setup-ruby@v1
21
+ uses: ruby/setup-ruby@v1
19
22
  with:
20
23
  ruby-version: ${{ matrix.ruby }}
21
-
24
+
22
25
  - name: Install deps
23
26
  run: |
24
27
  sudo apt update -y
25
28
  sudo apt install -y libsqlite3-dev
26
-
29
+
27
30
  - name: Gems Cache
28
31
  id: gem-cache
29
32
  uses: actions/cache@v1
@@ -32,7 +35,7 @@ jobs:
32
35
  key: ${{ runner.os }}-${{ matrix.ruby }}-${{ matrix.rails }}-gem
33
36
  restore-keys: |
34
37
  ${{ runner.os }}-${{ matrix.ruby }}-${{ matrix.rails }}-gem
35
-
38
+
36
39
  - name: Install gems
37
40
  env:
38
41
  RAILS_VERSION: ${{ matrix.rails }}
@@ -40,7 +43,7 @@ jobs:
40
43
  gem install bundler
41
44
  bundle config set path 'vendor/bundle'
42
45
  bundle check || bundle install --jobs 4 --retry 3
43
-
46
+
44
47
  - name: Compile & test
45
48
  env:
46
49
  RAILS_VERSION: ${{ matrix.rails }}
data/Gemfile CHANGED
@@ -3,7 +3,7 @@ source "https://rubygems.org"
3
3
 
4
4
  gemspec
5
5
 
6
- raw_rails_version = ENV.fetch("RAILS_VERSION", "5.2")
6
+ raw_rails_version = ENV.fetch("RAILS_VERSION", "6.1.0")
7
7
  rails_version = "~> #{raw_rails_version}"
8
8
 
9
9
  gem "activesupport", rails_version
@@ -12,17 +12,8 @@ gem "activerecord", rails_version, group: :test
12
12
 
13
13
 
14
14
  group :benchmarks do
15
- if raw_rails_version.include? "4.2"
16
- gem 'sqlite3', '~> 1.3.6'
17
- else
18
- gem "sqlite3", "~> 1.4"
19
- end
20
-
21
- if raw_rails_version.include? "4.2"
22
- gem "pg", "~> 0.15"
23
- else
24
- gem "pg", ">= 0.18", "< 2.0"
25
- end
15
+ gem "sqlite3", "~> 1.4"
16
+ gem "pg", ">= 0.18", "< 2.0"
26
17
 
27
18
  gem "memory_profiler"
28
19
  gem "ruby-prof", platforms: [:mri]
@@ -6,7 +6,7 @@ sidebar_label: Introduction
6
6
 
7
7
  Panko is library which is inspired by ActiveModelSerializers 0.9 for serializing ActiveRecord/Ruby objects to JSON strings, fast.
8
8
 
9
- To achieve it's [performance](https://panko-serializer.github.io/panko_serializer/performance.html):
9
+ To achieve it's [performance](https://panko.dev/docs/performance.html):
10
10
 
11
11
  * Oj - Panko relies Oj since it's fast and allow to to serialize incrementally using `Oj::StringWriter`
12
12
  * Serialization Descriptor - Panko computes most of the metadata ahead of time, to save time later in serialization.
@@ -8,15 +8,15 @@ The performance of Panko is measured using microbenchmarks and load testing.
8
8
 
9
9
  ## Microbenchmarks
10
10
 
11
- The following microbenchmarks are run on MacBook Pro (15-inch, 2018), Ruby 2.6.3 with Rails 6.0.2.1
12
- demonstrating the performance of ActiveModelSerializers 0.10.10 and Panko 0.7.2
11
+ The following microbenchmarks are run on MacBook Pro (16-inch, 2021, M1 Max), Ruby 3.1.1 with Rails 7.0.2.3
12
+ demonstrating the performance of ActiveModelSerializers 0.10.13 and Panko 0.7.6
13
13
 
14
14
  | Benchmark | AMS ip/s | Panko ip/s |
15
15
  | ----------------- | -------- | ---------- |
16
- | Simple_Posts_2300 | 5.4 | 190.48 |
17
- | Simple_Posts_50 | 261.28 | 9,347.4 |
18
- | HasOne_Posts_2300 | 2.54 | 90.71 |
19
- | HasOne_Posts_50 | 124.29 | 5,421.55 |
16
+ | Simple_Posts_2300 | 11.15 | 489.71 |
17
+ | Simple_Posts_50 | 517.85 | 21,366.93 |
18
+ | HasOne_Posts_2300 | 5.68 | 229.57 |
19
+ | HasOne_Posts_50 | 268.14 | 10,126.33 |
20
20
 
21
21
  ## Real-world benchmark
22
22