duel-mysql 0.1.3 → 0.1.4
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 +4 -4
- data/CHANGELOG.md +13 -1
- data/lib/duel/mysql/version.rb +1 -1
- data/lib/duel/mysql.rb +12 -1
- data/sig/duel/mysql.rbs +3 -0
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 91886f800ed1496ebb3e8f59bafc62b9e29f618c91eaeb649358f0b9bee33d8f
|
|
4
|
+
data.tar.gz: c38d137dceb134ad0b83d05e4f0023959f96b96debf55879393163ba63d9eed4
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 49030c55392a4cd40b516126073c97d552423a597811b0b18993d874031c773452e9e6e2d0a1bd45cee3d73173150e1c166cb53ed2a3dedc45039e0d67777ec2
|
|
7
|
+
data.tar.gz: 9a2f56833e5408cf524dc7b0981c8fae1e00b0966b68460d82125423def7c2f3c09f08ea3583118e386665633d9d82a5ae352c1862304f809c123d53577636e8
|
data/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.1.4] - 2026-11-06
|
|
11
|
+
|
|
12
|
+
### Fixed
|
|
13
|
+
|
|
14
|
+
- In trilogy's own repository, every worker would measure the bundle's
|
|
15
|
+
release of trilogy, not its version's own, as the plugin required
|
|
16
|
+
trilogy as it loaded, in `.duel.rb`, before the worker loaded the
|
|
17
|
+
version. It now requires trilogy as it first connects: in the
|
|
18
|
+
runner, to the server it started, and in a worker, once the version
|
|
19
|
+
has loaded.
|
|
20
|
+
|
|
10
21
|
## [0.1.3] - 2026-11-04
|
|
11
22
|
|
|
12
23
|
No changes of its own: released in step with the other Duel gems.
|
|
@@ -78,7 +89,8 @@ or later (not MariaDB).
|
|
|
78
89
|
CI.
|
|
79
90
|
- RBS signatures in sig/, checked with Steep.
|
|
80
91
|
|
|
81
|
-
[Unreleased]: https://github.com/sferik/duel-ruby/compare/duel-mysql-v0.1.
|
|
92
|
+
[Unreleased]: https://github.com/sferik/duel-ruby/compare/duel-mysql-v0.1.4...HEAD
|
|
93
|
+
[0.1.4]: https://github.com/sferik/duel-ruby/compare/duel-mysql-v0.1.3...duel-mysql-v0.1.4
|
|
82
94
|
[0.1.3]: https://github.com/sferik/duel-ruby/compare/duel-mysql-v0.1.2...duel-mysql-v0.1.3
|
|
83
95
|
[0.1.2]: https://github.com/sferik/duel-ruby/compare/duel-mysql-v0.1.1...duel-mysql-v0.1.2
|
|
84
96
|
[0.1.1]: https://github.com/sferik/duel-ruby/compare/duel-mysql-v0.1.0...duel-mysql-v0.1.1
|
data/lib/duel/mysql/version.rb
CHANGED
data/lib/duel/mysql.rb
CHANGED
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
require "duel"
|
|
4
4
|
require "digest"
|
|
5
5
|
require "fileutils"
|
|
6
|
-
require "trilogy"
|
|
7
6
|
require_relative "mysql/version"
|
|
8
7
|
|
|
9
8
|
module Duel
|
|
@@ -82,6 +81,17 @@ module Duel
|
|
|
82
81
|
connection
|
|
83
82
|
end
|
|
84
83
|
|
|
84
|
+
# Loads Trilogy, as the first connection is made: not as the plugin
|
|
85
|
+
# loads, in .duel.rb, before a worker loads its version. In trilogy's
|
|
86
|
+
# own repository, trilogy is what's measured, and the worker would load
|
|
87
|
+
# whichever trilogy the load path led to first (the bundle's release,
|
|
88
|
+
# say), and keep it. (In the runner, which loads no version, the
|
|
89
|
+
# bundle's.)
|
|
90
|
+
# mutant:disable -- the tests' process has Trilogy loaded from the start,
|
|
91
|
+
# so a require changes nothing there: test_loads_trilogy_only_when_used
|
|
92
|
+
# checks it, in a process of its own
|
|
93
|
+
def self.require_trilogy = require("trilogy")
|
|
94
|
+
|
|
85
95
|
# Runs SQL on a connection of its own to the server on +socket+;
|
|
86
96
|
# returns the last statement's result.
|
|
87
97
|
def self.run(socket, sql)
|
|
@@ -386,6 +396,7 @@ module Duel
|
|
|
386
396
|
end
|
|
387
397
|
|
|
388
398
|
def initialize(socket)
|
|
399
|
+
MySQL.require_trilogy
|
|
389
400
|
# (As root: trilogy's user, unless it's given another.)
|
|
390
401
|
@client = Trilogy.new(socket: socket, database: DATABASE, multi_statement: true)
|
|
391
402
|
end
|
data/sig/duel/mysql.rbs
CHANGED
|
@@ -51,6 +51,9 @@ module Duel
|
|
|
51
51
|
|
|
52
52
|
# Runs SQL on a connection of its own to the server on +socket+;
|
|
53
53
|
# returns the last statement's result.
|
|
54
|
+
# Loads Trilogy, as the first connection is made.
|
|
55
|
+
def self.require_trilogy: () -> bool
|
|
56
|
+
|
|
54
57
|
def self.run: (String socket, String sql) -> ::Trilogy::Result
|
|
55
58
|
|
|
56
59
|
# What the worker's server has done so far, but for the plugin's own
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: duel-mysql
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.4
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Erik Berlin
|
|
@@ -74,7 +74,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
74
74
|
- !ruby/object:Gem::Version
|
|
75
75
|
version: '0'
|
|
76
76
|
requirements: []
|
|
77
|
-
rubygems_version: 4.0.
|
|
77
|
+
rubygems_version: 4.0.24
|
|
78
78
|
specification_version: 4
|
|
79
79
|
summary: A MySQL server for each Duel worker, and what it did for each benchmark
|
|
80
80
|
test_files: []
|