serialbench 0.1.2 → 0.1.3

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.
Files changed (58) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/benchmark.yml +273 -228
  3. data/.github/workflows/rake.yml +11 -0
  4. data/.github/workflows/windows-debug.yml +171 -0
  5. data/.gitignore +32 -0
  6. data/.rubocop.yml +1 -0
  7. data/.rubocop_todo.yml +274 -0
  8. data/Gemfile +13 -1
  9. data/README.adoc +36 -0
  10. data/data/schemas/result.yml +29 -0
  11. data/docs/PLATFORM_VALIDATION_FIX.md +79 -0
  12. data/docs/SYCK_YAML_FIX.md +91 -0
  13. data/docs/WEBSITE_COMPLETION_PLAN.md +440 -0
  14. data/docs/WINDOWS_LIBXML_FIX.md +136 -0
  15. data/docs/WINDOWS_SETUP.md +122 -0
  16. data/lib/serialbench/benchmark_runner.rb +3 -3
  17. data/lib/serialbench/cli/benchmark_cli.rb +74 -1
  18. data/lib/serialbench/cli/environment_cli.rb +3 -3
  19. data/lib/serialbench/cli/resultset_cli.rb +72 -26
  20. data/lib/serialbench/cli/ruby_build_cli.rb +75 -88
  21. data/lib/serialbench/cli/validate_cli.rb +88 -0
  22. data/lib/serialbench/cli.rb +6 -2
  23. data/lib/serialbench/config_manager.rb +15 -26
  24. data/lib/serialbench/models/benchmark_config.rb +12 -0
  25. data/lib/serialbench/models/benchmark_result.rb +39 -3
  26. data/lib/serialbench/models/environment_config.rb +3 -2
  27. data/lib/serialbench/models/platform.rb +56 -4
  28. data/lib/serialbench/models/result.rb +28 -1
  29. data/lib/serialbench/models/result_set.rb +8 -0
  30. data/lib/serialbench/ruby_build_manager.rb +19 -23
  31. data/lib/serialbench/runners/asdf_runner.rb +1 -1
  32. data/lib/serialbench/runners/docker_runner.rb +2 -4
  33. data/lib/serialbench/runners/local_runner.rb +71 -0
  34. data/lib/serialbench/serializers/base_serializer.rb +1 -1
  35. data/lib/serialbench/serializers/json/rapidjson_serializer.rb +1 -1
  36. data/lib/serialbench/serializers/toml/base_toml_serializer.rb +0 -2
  37. data/lib/serialbench/serializers/toml/toml_rb_serializer.rb +1 -1
  38. data/lib/serialbench/serializers/toml/tomlib_serializer.rb +1 -1
  39. data/lib/serialbench/serializers/xml/libxml_serializer.rb +4 -8
  40. data/lib/serialbench/serializers/xml/nokogiri_serializer.rb +2 -2
  41. data/lib/serialbench/serializers/xml/oga_serializer.rb +4 -8
  42. data/lib/serialbench/serializers/xml/ox_serializer.rb +2 -2
  43. data/lib/serialbench/serializers/xml/rexml_serializer.rb +3 -3
  44. data/lib/serialbench/serializers/yaml/psych_serializer.rb +1 -1
  45. data/lib/serialbench/serializers/yaml/syck_serializer.rb +1 -1
  46. data/lib/serialbench/serializers.rb +2 -2
  47. data/lib/serialbench/site_generator.rb +180 -2
  48. data/lib/serialbench/templates/assets/css/format_based.css +1 -53
  49. data/lib/serialbench/templates/assets/css/themes.css +5 -4
  50. data/lib/serialbench/templates/assets/js/chart_helpers.js +44 -14
  51. data/lib/serialbench/templates/assets/js/dashboard.js +14 -15
  52. data/lib/serialbench/templates/format_based.liquid +480 -252
  53. data/lib/serialbench/version.rb +1 -1
  54. data/lib/serialbench/yaml_validator.rb +36 -0
  55. data/serialbench.gemspec +11 -2
  56. metadata +34 -23
  57. data/.github/workflows/ci.yml +0 -74
  58. data/.github/workflows/docker.yml +0 -272
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4bd127a1fb810ad2b4a95377dd7bf7e75297ec4b989b44844131b5ac01b0ab83
4
- data.tar.gz: f594315660bf94c7c97d8a0b0f9d9aadf6b756f675cc8e1671535840840c26bd
3
+ metadata.gz: c24dcb07a68058a2ff622be5f16e6c7225cd266bf29c3fcd06a0ecd597b9b8d3
4
+ data.tar.gz: 95833392ca0fe8cab20d7d0300cd86f11948a2e0d766885e6dff0de2b75189b1
5
5
  SHA512:
6
- metadata.gz: 607d47dee25a4815518e7246b44830cc78d08e9852c79f06803ba073a0af71946066f287ce174f130ce5553bbe3707e76d12c5318eb5db9966a97cb69de976e2
7
- data.tar.gz: 808cc1fdd677a2b6ee5603305fa9a2da913ee2c2feae3b6ea0e648b39c99c15a01a3f89b067be9ac45b634ab330f3fb1dc2f1e02606482af2faef3118c04a484
6
+ metadata.gz: 8e1b7c78643b32cf34251220cd9dac61db43fa16cf104669b2882b139faad9bb1051a3a552d5caf37fc8018014c0dda6bcbe35870688e3ea229c64c5c8064d5e
7
+ data.tar.gz: d5c0727a5d5d24d82107837b996f8a31013bcf75a66a737ce6087767858c7b54b59ad9ed9014cf84d0ef3f4c07d5954bcfa3aa0698d3f745bb984477f18b880f
@@ -1,10 +1,13 @@
1
- name: benchmark
1
+ name: benchmark-weekly
2
2
 
3
3
  on:
4
4
  push:
5
- branches: [ main, master ]
5
+ branches: [main]
6
+ paths-ignore:
7
+ - '.github/workflows/windows-debug.yml'
6
8
  pull_request:
7
- branches: [ main, master ]
9
+ paths-ignore:
10
+ - '.github/workflows/windows-debug.yml'
8
11
  schedule:
9
12
  # Run benchmarks weekly on Sundays at 2 AM UTC
10
13
  - cron: '0 2 * * 0'
@@ -27,250 +30,292 @@ jobs:
27
30
  ruby-versions: ${{ steps.set-matrix.outputs.ruby-versions }}
28
31
  platforms: ${{ steps.set-matrix.outputs.platforms }}
29
32
  steps:
30
- - name: Set matrix configurations
31
- id: set-matrix
32
- run: |
33
- echo 'ruby-versions=["3.1", "3.2", "3.3", "3.4"]' >> $GITHUB_OUTPUT
34
- echo 'platforms=["ubuntu-latest", "macos-latest", "windows-latest"]' >> $GITHUB_OUTPUT
33
+ - name: Set matrix configurations
34
+ id: set-matrix
35
+ run: |
36
+ echo 'ruby-versions=["3.1", "3.2", "3.3", "3.4"]' >> $GITHUB_OUTPUT
37
+ echo 'platforms=["ubuntu-24.04", "ubuntu-24.04-arm", "ubuntu-22.04", "ubuntu-22.04-arm", "macos-13", "macos-15-intel", "macos-14", "macos-15", "macos-26", "windows-2022", "windows-2025", "windows-11-arm"]' >> $GITHUB_OUTPUT
35
38
 
36
39
  # Cross-platform native benchmarks
37
40
  benchmark:
38
41
  runs-on: ${{ matrix.platform }}
39
42
  needs: setup
40
43
  strategy:
44
+ fail-fast: false
41
45
  matrix:
42
46
  platform: ${{ fromJson(needs.setup.outputs.platforms) }}
43
47
  ruby-version: ${{ fromJson(needs.setup.outputs.ruby-versions) }}
44
- fail-fast: false
48
+ exclude:
49
+ # windows-11-arm only supports Ruby 3.4.x
50
+ - platform: windows-11-arm
51
+ ruby-version: "3.1"
52
+ - platform: windows-11-arm
53
+ ruby-version: "3.2"
54
+ - platform: windows-11-arm
55
+ ruby-version: "3.3"
45
56
 
46
57
  steps:
47
- - name: Checkout repository
48
- uses: actions/checkout@v4
49
-
50
- - name: Set up Ruby ${{ matrix.ruby-version }}
51
- uses: ruby/setup-ruby@v1
52
- with:
53
- ruby-version: ${{ matrix.ruby-version }}
54
- bundler-cache: true
55
-
56
- - name: Install system dependencies (Ubuntu)
57
- if: matrix.platform == 'ubuntu-latest'
58
- run: |
59
- sudo apt-get update
60
- sudo apt-get install -y libxml2-dev libxslt1-dev build-essential
61
-
62
- - name: Install system dependencies (macOS)
63
- if: matrix.platform == 'macos-latest'
64
- run: |
65
- brew install libxml2 libxslt
66
-
67
- - name: Install system dependencies (Windows)
68
- if: matrix.platform == 'windows-latest'
69
- run: |
70
- # Windows dependencies are typically handled by gem installations
71
- echo "Windows dependencies handled by gems"
72
-
73
- - name: Install gems
74
- run: |
75
- bundle install
76
-
77
- - name: List available serializers
78
- run: bundle exec serialbench list
79
-
80
- - name: Run benchmarks
81
- run: |
82
- if [ "${{ matrix.platform }}" = "macos-latest" ]; then
83
- # macOS can handle full benchmarks
84
- bundle exec serialbench benchmark \
85
- --formats xml json yaml toml \
86
- --iterations 5 \
87
- --warmup 2
88
- else
89
- # Windows and Ubuntu use short configuration for memory efficiency
90
- bundle exec serialbench benchmark \
91
- --config config/short.yml
92
- fi
93
- shell: bash
94
-
95
- - name: Run tests to verify functionality
96
- run: bundle exec rspec --format documentation
97
-
98
- - name: Upload benchmark results
99
- uses: actions/upload-artifact@v4
100
- with:
101
- name: benchmark-results-${{ matrix.platform }}-ruby-${{ matrix.ruby-version }}
102
- path: results/
103
- retention-days: 30
104
-
105
- # Merge results and deploy to GitHub Pages
106
- merge-and-deploy:
107
- if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master'
108
- runs-on: ubuntu-latest
109
- needs: [setup, benchmark]
58
+ - name: Checkout repository
59
+ uses: actions/checkout@v4
60
+
61
+ - name: Detect Windows architecture
62
+ id: windows-arch
63
+ if: startsWith(matrix.platform, 'windows-')
64
+ run: |
65
+ if [[ "${{ matrix.platform }}" == *"-arm" ]]; then
66
+ echo "arch=arm64-windows" >> $GITHUB_OUTPUT
67
+ else
68
+ echo "arch=x64-windows" >> $GITHUB_OUTPUT
69
+ fi
70
+ shell: bash
71
+
72
+ - name: Install vcpkg dependencies (Windows)
73
+ if: startsWith(matrix.platform, 'windows-')
74
+ run: |
75
+ vcpkg install libxml2:${{ steps.windows-arch.outputs.arch }} 2>&1 || true
76
+ vcpkg integrate install 2>&1 || true
77
+ shell: bash
78
+
79
+ - name: Configure bundler for libxml2 (Windows)
80
+ if: startsWith(matrix.platform, 'windows-')
81
+ run: |
82
+ mkdir -p .bundle 2>&1 || true
83
+ echo "---" > .bundle/config 2>&1 || true
84
+ echo 'BUNDLE_BUILD__LIBXML___RUBY: "--with-xml2-dir=C:/vcpkg/installed/${{ steps.windows-arch.outputs.arch }} --with-xml2-include=C:/vcpkg/installed/${{ steps.windows-arch.outputs.arch }}/include/libxml2 --with-xml2-lib=C:/vcpkg/installed/${{ steps.windows-arch.outputs.arch }}/lib"' >> .bundle/config 2>&1 || true
85
+ shell: bash
86
+
87
+ - name: Set up Ruby ${{ matrix.ruby-version }}
88
+ uses: ruby/setup-ruby@v1
89
+ with:
90
+ ruby-version: ${{ matrix.ruby-version }}
91
+ bundler-cache: true
92
+
93
+ - name: Install system dependencies (Ubuntu)
94
+ if: startsWith(matrix.platform, 'ubuntu-')
95
+ run: |
96
+ sudo apt-get update
97
+ sudo apt-get install -y libxml2-dev libxslt1-dev build-essential
98
+
99
+ - name: Install system dependencies (macOS)
100
+ if: startsWith(matrix.platform, 'macos-')
101
+ run: |
102
+ brew install libxml2 libxslt
103
+
104
+ - name: Debug Ruby platform (Windows only)
105
+ if: startsWith(matrix.platform, 'windows-')
106
+ shell: ruby {0}
107
+ run: |
108
+ puts "=== Ruby Platform Debug Info ==="
109
+ puts "RUBY_PLATFORM: #{RUBY_PLATFORM}"
110
+ puts "Gem.win_platform?: #{Gem.win_platform?}"
111
+ puts "RbConfig::CONFIG['host_os']: #{RbConfig::CONFIG['host_os']}"
112
+ puts "RbConfig::CONFIG['host_cpu']: #{RbConfig::CONFIG['host_cpu']}"
113
+ puts "RbConfig::CONFIG['arch']: #{RbConfig::CONFIG['arch']}"
114
+ puts "================================"
115
+
116
+ - name: Install gems
117
+ run: bundle install
118
+
119
+ - name: Update Ruby-Build cache
120
+ run: bundle exec serialbench ruby-build update
121
+ env:
122
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
123
+
124
+ - name: Create environment config
125
+ run: |
126
+ mkdir -p config/environments
127
+ cat > config/environments/ci-ruby-${{ matrix.ruby-version }}.yml << EOF
128
+ ---
129
+ name: ci-ruby-${{ matrix.ruby-version }}-${{ matrix.platform }}
130
+ kind: local
131
+ created_at: '$(date -u +"%Y-%m-%dT%H:%M:%SZ")'
132
+ ruby_build_tag: "${{ matrix.ruby-version }}"
133
+ description: CI environment for Ruby ${{ matrix.ruby-version }} on ${{ matrix.platform }}
134
+ EOF
135
+ shell: bash
136
+
137
+ - name: Run benchmarks
138
+ env:
139
+ GITHUB_RUNNER_PLATFORM: ${{ matrix.platform }}
140
+ run: |
141
+ bundle exec serialbench environment execute config/environments/ci-ruby-${{ matrix.ruby-version }}.yml config/benchmarks/short.yml results/runs/ci-ruby-${{ matrix.ruby-version }}-${{ matrix.platform }}
142
+
143
+ - name: Verify benchmark results before upload
144
+ run: |
145
+ echo "=== Verifying benchmark results ==="
146
+ RESULTS_FILE="results/runs/ci-ruby-${{ matrix.ruby-version }}-${{ matrix.platform }}/results.yaml"
147
+
148
+ echo "📁 Checking file exists..."
149
+ if [ ! -f "$RESULTS_FILE" ]; then
150
+ echo "❌ ERROR: results.yaml not found at $RESULTS_FILE"
151
+ exit 1
152
+ fi
110
153
 
111
- steps:
112
- - name: Checkout repository
113
- uses: actions/checkout@v4
114
-
115
- - name: Set up Ruby (for report generation)
116
- uses: ruby/setup-ruby@v1
117
- with:
118
- ruby-version: '3.3'
119
- bundler-cache: true
120
-
121
- - name: Install system dependencies
122
- run: |
123
- sudo apt-get update
124
- sudo apt-get install -y libxml2-dev libxslt1-dev build-essential
125
-
126
- - name: Install gems
127
- run: bundle install
128
-
129
- - name: Download all benchmark artifacts
130
- uses: actions/download-artifact@v4
131
- with:
132
- pattern: benchmark-results-*
133
- path: artifacts/
134
-
135
- - name: List downloaded artifacts
136
- run: |
137
- echo "Downloaded artifacts:"
138
- find artifacts/ -type f -name "*.json" -o -name "*.html" | head -20
139
-
140
- - name: Generate comprehensive GitHub Pages
141
- run: |
142
- mkdir -p docs
143
-
144
- # Find all result directories
145
- RESULT_DIRS=""
146
- for dir in artifacts/benchmark-results-*/; do
147
- if [ -d "$dir" ]; then
148
- RESULT_DIRS="$RESULT_DIRS $dir"
154
+ echo "📊 Checking file size..."
155
+ SIZE=$(wc -c < "$RESULTS_FILE" | tr -d ' ')
156
+ echo " File size: $SIZE bytes"
157
+
158
+ if [ "$SIZE" -lt 1000 ]; then
159
+ echo "❌ ERROR: results.yaml is suspiciously small ($SIZE bytes)"
160
+ echo " Expected at least 1000 bytes for valid benchmark results"
161
+ echo "=== File contents ==="
162
+ cat "$RESULTS_FILE"
163
+ exit 1
149
164
  fi
150
- done
151
-
152
- echo "Processing result directories: $RESULT_DIRS"
153
-
154
- # Generate GitHub Pages from all results
155
- if [ -n "$RESULT_DIRS" ]; then
156
- bundle exec serialbench github_pages $RESULT_DIRS docs/
157
- else
158
- echo "No result directories found, creating placeholder page"
159
- echo "<html><body><h1>No benchmark results available</h1></body></html>" > docs/index.html
160
- fi
161
-
162
- - name: Create platform comparison summary
163
- run: |
164
- # Create a summary of cross-platform results
165
- cat > docs/platform-summary.md << 'EOF'
166
- # Cross-Platform Benchmark Summary
167
-
168
- This page contains benchmark results from multiple platforms and Ruby versions:
169
-
170
- ## Platforms Tested
171
- - **Ubuntu Latest**: Linux x86_64 environment
172
- - **macOS Latest**: Apple Silicon and Intel Mac environment
173
- - **Windows Latest**: Windows Server environment
174
-
175
- ## Ruby Versions
176
- - Ruby 3.1, 3.2, 3.3, 3.4
177
-
178
- ## Serialization Libraries
179
- - **XML**: REXML, Ox, Nokogiri, Oga, LibXML
180
- - **JSON**: JSON, Oj, RapidJSON, YAJL
181
- - **YAML**: Psych, Syck
182
- - **TOML**: TOML-RB, Tomlib
183
-
184
- Results show performance variations across different operating systems and architectures.
185
- EOF
186
-
187
- - name: Setup Pages
188
- uses: actions/configure-pages@v4
189
-
190
- - name: Upload to GitHub Pages
191
- uses: actions/upload-pages-artifact@v3
192
- with:
193
- path: docs
194
-
195
- - name: Deploy to GitHub Pages
196
- id: deployment
197
- uses: actions/deploy-pages@v4
198
-
199
- # Performance comparison analysis
200
- performance-analysis:
201
- if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master'
165
+
166
+ echo "✅ File size OK: $SIZE bytes"
167
+ shell: bash
168
+
169
+ - name: Validate YAML schema
170
+ run: |
171
+ bundle exec serialbench validate result results/runs/ci-ruby-${{ matrix.ruby-version }}-${{ matrix.platform }}/results.yaml
172
+
173
+ - name: Upload benchmark results
174
+ uses: actions/upload-artifact@v4
175
+ with:
176
+ name: benchmark-results-${{ matrix.platform }}-ruby-${{ matrix.ruby-version }}
177
+ path: results/runs/ci-ruby-${{ matrix.ruby-version }}-${{ matrix.platform }}
178
+ retention-days: 30
179
+
180
+ # Aggregate results and deploy to GitHub Pages
181
+ deploy-pages:
182
+ if: github.ref == 'refs/heads/main'
202
183
  runs-on: ubuntu-latest
203
- needs: [benchmark]
184
+ needs: [setup, benchmark]
185
+ environment:
186
+ name: github-pages
187
+ url: ${{ steps.deployment.outputs.page_url }}
204
188
 
205
189
  steps:
206
- - name: Checkout repository
207
- uses: actions/checkout@v4
208
-
209
- - name: Download all benchmark results
210
- uses: actions/download-artifact@v4
211
- with:
212
- pattern: benchmark-results-*-ruby-*
213
- path: analysis/
214
-
215
- - name: Set up Ruby for analysis
216
- uses: ruby/setup-ruby@v1
217
- with:
218
- ruby-version: '3.3'
219
- bundler-cache: true
220
-
221
- - name: Install dependencies
222
- run: |
223
- sudo apt-get update
224
- sudo apt-get install -y libxml2-dev libxslt1-dev
225
- bundle install
226
-
227
- - name: Generate performance analysis
228
- run: |
229
- bundle exec serialbench analyze_performance analysis/benchmark-results-*/ performance_analysis.json
230
-
231
- - name: Generate platform comparison report
232
- run: |
233
- bundle exec serialbench platform_comparison performance_analysis.json platform_comparison.json
234
-
235
- - name: Upload performance analysis
236
- uses: actions/upload-artifact@v4
237
- with:
238
- name: performance-analysis
239
- path: |
240
- performance_analysis.json
241
- platform_comparison.json
242
- retention-days: 90
190
+ - name: Checkout repository
191
+ uses: actions/checkout@v4
192
+
193
+ - name: Set up Ruby
194
+ uses: ruby/setup-ruby@v1
195
+ with:
196
+ ruby-version: '3.3'
197
+ bundler-cache: true
198
+
199
+ - name: Install system dependencies
200
+ run: |
201
+ sudo apt-get update
202
+ sudo apt-get install -y libxml2-dev libxslt1-dev build-essential
203
+
204
+ - name: Install gems
205
+ run: bundle install
206
+
207
+ - name: Download all benchmark artifacts
208
+ uses: actions/download-artifact@v4
209
+ with:
210
+ pattern: benchmark-results-*
211
+ path: artifacts/
212
+
213
+ - name: List downloaded artifacts structure
214
+ run: |
215
+ echo "=== Artifacts directory structure ==="
216
+ ls -la artifacts/
217
+ echo ""
218
+ echo "=== Searching for results.yaml files ==="
219
+ find artifacts/ -name "results.yaml" -type f
220
+ echo ""
221
+ echo "=== Directory tree (first 3 levels) ==="
222
+ find artifacts/ -maxdepth 3 -type d | sort
223
+
224
+ - name: Create resultset
225
+ run: |
226
+ mkdir -p results/sets
227
+ bundle exec serialbench resultset create weekly-benchmark results/sets/weekly-benchmark
228
+
229
+ - name: Add all results to resultset
230
+ run: |
231
+ bundle exec serialbench resultset add-result results/sets/weekly-benchmark artifacts/benchmark-results-*/
232
+
233
+ - name: Generate GitHub Pages site
234
+ run: |
235
+ bundle exec serialbench resultset build-site results/sets/weekly-benchmark _site
236
+
237
+ - name: Create summary page
238
+ run: |
239
+ mkdir -p _site
240
+ cat > _site/README.md << 'EOF'
241
+ # Serialbench - Weekly Benchmark Results
242
+
243
+ This site contains automated benchmark results for Ruby serialization libraries.
244
+
245
+ ## Benchmarked Libraries
246
+
247
+ - **XML**: REXML, Ox, Nokogiri, Oga, LibXML
248
+ - **JSON**: JSON, Oj, RapidJSON, YAJL
249
+ - **YAML**: Psych
250
+ - **TOML**: TOML-RB, Tomlib, tomlrb
251
+
252
+ ## Platforms Tested
253
+
254
+ - Ubuntu Latest (Linux x86_64)
255
+ - Ubuntu 24.04 (Linux ARM64)
256
+ - Ubuntu 22.04 (Linux ARM64)
257
+ - macOS 13 (Intel x86_64)
258
+ - macOS 15 Intel (Intel x86_64)
259
+ - macOS 14 (Apple Silicon ARM64)
260
+ - macOS 15 (Apple Silicon ARM64)
261
+
262
+ ## Ruby Versions
263
+
264
+ - Ruby 3.1, 3.2, 3.3, 3.4
265
+
266
+ ## View Results
267
+
268
+ Open [index.html](./index.html) to view the interactive dashboard.
269
+
270
+ ---
271
+
272
+ *Last updated: $(date -u +"%Y-%m-%d %H:%M:%S UTC")*
273
+ EOF
274
+
275
+ - name: Setup Pages
276
+ uses: actions/configure-pages@v4
277
+
278
+ - name: Upload to GitHub Pages
279
+ uses: actions/upload-pages-artifact@v3
280
+ with:
281
+ path: _site
282
+
283
+ - name: Deploy to GitHub Pages
284
+ id: deployment
285
+ uses: actions/deploy-pages@v4
243
286
 
244
287
  # Summary job
245
288
  summary:
246
289
  runs-on: ubuntu-latest
247
- needs: [setup, benchmark, merge-and-deploy, performance-analysis]
290
+ needs: [setup, benchmark, deploy-pages]
248
291
  if: always()
249
292
  steps:
250
- - name: Generate workflow summary
251
- run: |
252
- echo "## Cross-Platform Benchmark Summary" >> $GITHUB_STEP_SUMMARY
253
- echo "" >> $GITHUB_STEP_SUMMARY
254
- echo "**Benchmark Status**: ${{ needs.benchmark.result }}" >> $GITHUB_STEP_SUMMARY
255
- echo "**Deploy Status**: ${{ needs.merge-and-deploy.result }}" >> $GITHUB_STEP_SUMMARY
256
- echo "**Analysis Status**: ${{ needs.performance-analysis.result }}" >> $GITHUB_STEP_SUMMARY
257
- echo "" >> $GITHUB_STEP_SUMMARY
258
- echo "### Platforms Tested" >> $GITHUB_STEP_SUMMARY
259
- echo "- Ubuntu Latest (Linux x86_64)" >> $GITHUB_STEP_SUMMARY
260
- echo "- macOS Latest (Apple Silicon/Intel)" >> $GITHUB_STEP_SUMMARY
261
- echo "- Windows Latest (Windows Server)" >> $GITHUB_STEP_SUMMARY
262
- echo "" >> $GITHUB_STEP_SUMMARY
263
- echo "### Ruby Versions" >> $GITHUB_STEP_SUMMARY
264
- echo "- Ruby 3.1, 3.2, 3.3, 3.4" >> $GITHUB_STEP_SUMMARY
265
- echo "" >> $GITHUB_STEP_SUMMARY
266
- echo "### Serialization Libraries" >> $GITHUB_STEP_SUMMARY
267
- echo "- **XML**: REXML, Ox, Nokogiri, Oga, LibXML" >> $GITHUB_STEP_SUMMARY
268
- echo "- **JSON**: JSON, Oj, RapidJSON, YAJL" >> $GITHUB_STEP_SUMMARY
269
- echo "- **YAML**: Psych, Syck" >> $GITHUB_STEP_SUMMARY
270
- echo "- **TOML**: TOML-RB, Tomlib" >> $GITHUB_STEP_SUMMARY
271
- echo "" >> $GITHUB_STEP_SUMMARY
272
- if [ "${{ github.ref }}" == "refs/heads/main" ] || [ "${{ github.ref }}" == "refs/heads/master" ]; then
273
- echo "### Results" >> $GITHUB_STEP_SUMMARY
274
- echo "📊 [View Interactive Results](https://metanorma.github.io/serialbench/)" >> $GITHUB_STEP_SUMMARY
275
- echo "📈 Performance analysis and platform comparison available in artifacts" >> $GITHUB_STEP_SUMMARY
276
- fi
293
+ - name: Generate workflow summary
294
+ run: |
295
+ echo "## Weekly Benchmark Summary" >> $GITHUB_STEP_SUMMARY
296
+ echo "" >> $GITHUB_STEP_SUMMARY
297
+ echo "**Benchmark Status**: ${{ needs.benchmark.result }}" >> $GITHUB_STEP_SUMMARY
298
+ echo "**Deploy Status**: ${{ needs.deploy-pages.result }}" >> $GITHUB_STEP_SUMMARY
299
+ echo "" >> $GITHUB_STEP_SUMMARY
300
+ echo "### Platforms Tested" >> $GITHUB_STEP_SUMMARY
301
+ echo "- Ubuntu Latest (Linux x86_64)" >> $GITHUB_STEP_SUMMARY
302
+ echo "- Ubuntu 24.04 (Linux ARM64)" >> $GITHUB_STEP_SUMMARY
303
+ echo "- Ubuntu 22.04 (Linux ARM64)" >> $GITHUB_STEP_SUMMARY
304
+ echo "- macOS 13 (Intel x86_64)" >> $GITHUB_STEP_SUMMARY
305
+ echo "- macOS 15 Intel (Intel x86_64)" >> $GITHUB_STEP_SUMMARY
306
+ echo "- macOS 14 (Apple Silicon ARM64)" >> $GITHUB_STEP_SUMMARY
307
+ echo "- macOS 15 (Apple Silicon ARM64)" >> $GITHUB_STEP_SUMMARY
308
+ echo "" >> $GITHUB_STEP_SUMMARY
309
+ echo "### Ruby Versions" >> $GITHUB_STEP_SUMMARY
310
+ echo "- Ruby 3.1, 3.2, 3.3, 3.4" >> $GITHUB_STEP_SUMMARY
311
+ echo "" >> $GITHUB_STEP_SUMMARY
312
+ echo "### Serialization Libraries" >> $GITHUB_STEP_SUMMARY
313
+ echo "- **XML**: REXML, Ox, Nokogiri, Oga, LibXML" >> $GITHUB_STEP_SUMMARY
314
+ echo "- **JSON**: JSON, Oj, RapidJSON, YAJL" >> $GITHUB_STEP_SUMMARY
315
+ echo "- **YAML**: Psych" >> $GITHUB_STEP_SUMMARY
316
+ echo "- **TOML**: TOML-RB, Tomlib, tomlrb" >> $GITHUB_STEP_SUMMARY
317
+ echo "" >> $GITHUB_STEP_SUMMARY
318
+ if [ "${{ github.ref }}" == "refs/heads/main" ]; then
319
+ echo "### Results" >> $GITHUB_STEP_SUMMARY
320
+ echo "📊 [View Interactive Dashboard](https://metanorma.github.io/serialbench/)" >> $GITHUB_STEP_SUMMARY
321
+ fi
@@ -6,10 +6,21 @@ on:
6
6
  push:
7
7
  branches: [ master, main ]
8
8
  tags: [ v* ]
9
+ paths-ignore:
10
+ - '.github/workflows/windows-debug.yml'
9
11
  pull_request:
12
+ paths-ignore:
13
+ - '.github/workflows/windows-debug.yml'
10
14
 
11
15
  jobs:
12
16
  rake:
13
17
  uses: metanorma/ci/.github/workflows/generic-rake.yml@main
18
+ with:
19
+ before-setup-ruby: |
20
+ vcpkg install libxml2:x64-windows 2>&1 || true
21
+ vcpkg integrate install 2>&1 || true
22
+ mkdir -p .bundle 2>&1 || true
23
+ echo "---" > .bundle/config 2>&1 || true
24
+ echo 'BUNDLE_BUILD__LIBXML___RUBY: "--with-xml2-dir=C:/vcpkg/installed/x64-windows --with-xml2-include=C:/vcpkg/installed/x64-windows/include/libxml2 --with-xml2-lib=C:/vcpkg/installed/x64-windows/lib"' >> .bundle/config 2>&1 || true
14
25
  secrets:
15
26
  pat_token: ${{ secrets.METANORMA_CI_PAT_TOKEN }}