avro_schema_registry-client 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/lib/avro_schema_registry/client.rb +4 -2
- data/lib/avro_schema_registry/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d255f0720f3c11b231fe828a6bd731b0e605e8d9
|
4
|
+
data.tar.gz: c961d73efc7bd4994bfd1f046fe9e9294199c10c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 67114107c1fdea6397cedc6a7005eaae753485046c27c52d62f35431cf1a6856e531e4293d9824c674a1c55c777376ab43962df68214625aa2517ac3bafa27ea
|
7
|
+
data.tar.gz: 4fe9f755ec382129d59565d70ca89876a153f4cfc6a3622e89714ebf8bc3373f51f26eec14aaeb0b73819fcf3389de922444ba3e8e16148636d7ba42f9960a28
|
data/CHANGELOG.md
CHANGED
@@ -21,15 +21,17 @@ module AvroSchemaRegistry
|
|
21
21
|
# Override register to first check if a schema is registered by fingerprint
|
22
22
|
# Also, allow additional params to be passed to register.
|
23
23
|
def register(subject, schema, **params)
|
24
|
-
|
25
24
|
lookup_subject_schema(subject, schema)
|
26
25
|
rescue Excon::Errors::NotFound
|
26
|
+
register_without_lookup(subject, schema, params)
|
27
|
+
end
|
28
|
+
|
29
|
+
def register_without_lookup(subject, schema, **params)
|
27
30
|
data = post("/subjects/#{subject}/versions",
|
28
31
|
body: { schema: schema.to_s }.merge!(params).to_json)
|
29
32
|
id = data.fetch('id')
|
30
33
|
@logger.info("Registered schema for subject `#{subject}`; id = #{id}")
|
31
34
|
id
|
32
|
-
|
33
35
|
end
|
34
36
|
|
35
37
|
# Override to add support for additional params
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: avro_schema_registry-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Salsify, Inc
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-04-
|
11
|
+
date: 2017-04-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|