hiera-mysql-json-backend-jruby 2.1.1 → 2.2.0

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: d1f407315f467249accc57e337bf96dc3e67d84cd1bcd9bbcac779a39987459d
4
- data.tar.gz: 829109efedd6577c0edc1037aa4fb66d0ad2483d0529a72ee0723b2172611e33
3
+ metadata.gz: 01a7d166dec3c8d67fe54ebe2a6018a737b43ecd84609b543fd63abc4424c04b
4
+ data.tar.gz: 782ce2349c694d6e7321310aa2c203d45ce8c629e79a01dffac9a253754467a8
5
5
  SHA512:
6
- metadata.gz: 15230e01a61d8f960a3eabe9d25046a6925c42e5b36653dfb1b9432b63c5cced72e368e4b357230ec3ec797be6836dcd1d49ba9d44b2de236b8e073b855011a5
7
- data.tar.gz: 7ba0e9493de5dcedd0c3b9083857e470125bb0acca72a662a3f81ea395930136c9a27e25a28713390e688631051205c7ae305f23cb9b6f969c4ef134559ae677
6
+ metadata.gz: 175cc79fe9e26ce6716bb734bdad212668cd32ba652340f40a729268e5723e522de70c92e6e503ed0f1f473bbea0e031323daac5f65d178e67025070948f47fa
7
+ data.tar.gz: 8fe0f950d4687c10705e600e1b661d0c6fa46bf6ebfb75d3ccb3a8cafabfc079337f86bae4cd833cd8cef08a6efdbc53f53d405bfae4b2a8b9fa3fc98ceb4a46
data/CHANGELOG.md CHANGED
@@ -20,3 +20,11 @@
20
20
 
21
21
  - If we cannot parse JSON as json, do something nasty to try if the value is a
22
22
  boolean
23
+
24
+ ### 2.1.0
25
+
26
+ - Host/domain constraints can now be defined per hierarchy file instead of being global only
27
+
28
+ ### 2.2.0
29
+
30
+ - Proper connection closing and previous patches
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |gem|
4
4
  gem.name = "hiera-mysql-json-backend-jruby"
5
- gem.version = "2.1.1"
5
+ gem.version = "2.2.0"
6
6
  gem.authors = ["Hostnet"]
7
7
  gem.email = ["opensource@hostnet.nl"]
8
8
  gem.description = %q{Alternative MySQL backend with json support for hiera}
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |gem|
4
4
  gem.name = "hiera-mysql-json-backend"
5
- gem.version = "2.1.1"
5
+ gem.version = "2.2.0"
6
6
  gem.authors = ["Hostnet"]
7
7
  gem.email = ["opensource@hostnet.nl"]
8
8
  gem.description = %q{Alternative MySQL backend with json support for hiera}
@@ -66,6 +66,9 @@ class Hiera
66
66
  mysql_pass = mysql_config.fetch(:pass, nil) || Config[:mysql_json][:pass]
67
67
  mysql_port = mysql_config.fetch(:port, nil) || Config[:mysql_json][:port] || '3306'
68
68
  mysql_database = mysql_config.fetch(:database, nil) || Config[:mysql_json][:database]
69
+ lookup_constraints = data.fetch(:only_for, nil) || Config[:mysql_json][:only_for] || {}
70
+
71
+ next unless should_lookup?(lookup_constraints, scope)
69
72
 
70
73
  connection_hash = {
71
74
  host: mysql_host,
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hiera-mysql-json-backend-jruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.1
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hostnet
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-05-26 00:00:00.000000000 Z
11
+ date: 2025-03-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jdbc-mysql
@@ -59,7 +59,7 @@ homepage: https://github.com/hostnet/hiera-mysql-json-backend
59
59
  licenses:
60
60
  - MIT
61
61
  metadata: {}
62
- post_install_message:
62
+ post_install_message:
63
63
  rdoc_options: []
64
64
  require_paths:
65
65
  - lib
@@ -74,8 +74,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
74
74
  - !ruby/object:Gem::Version
75
75
  version: '0'
76
76
  requirements: []
77
- rubygems_version: 3.1.6
78
- signing_key:
77
+ rubygems_version: 3.3.27
78
+ signing_key:
79
79
  specification_version: 4
80
80
  summary: Alternative MySQL backend with json support for hiera
81
81
  test_files: []