cdmbl 0.2.2 → 0.2.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.
- checksums.yaml +4 -4
- data/lib/cdmbl/default_cdm_notification.rb +8 -0
- data/lib/cdmbl/{default_callback.rb → default_completed_callback.rb} +1 -1
- data/lib/cdmbl/default_oai_notification.rb +8 -0
- data/lib/cdmbl/etl_worker.rb +1 -1
- data/lib/cdmbl/extractor.rb +1 -1
- data/lib/cdmbl/formatters.rb +6 -0
- data/lib/cdmbl/hooks.rb +6 -2
- data/lib/cdmbl/oai_request.rb +1 -1
- data/lib/cdmbl/transformer.rb +1 -1
- data/lib/cdmbl/version.rb +1 -1
- data/lib/cdmbl.rb +3 -1
- metadata +5 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c1a2f19c0067241fa3a48fae51ef1037eaff9eae
|
4
|
+
data.tar.gz: 0d7976ba3295a2bd5a078f6ce82b332346f4e585
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 43df324f1b75b2d86ea15b170450cf57fc1a304968f0174716074749865f39d5f8c99a46a560b7842361abeb61053e76fdb2835b4600912284804d712a6d04bc
|
7
|
+
data.tar.gz: f7f1ecaf33619f6bdad8a50d5cef9f92a35c543f2758e2eb396214e04510268cf320141f22f0f2ec0761f38ef4912972d02e1698dfcf46d0b58d24a66be79f42
|
data/lib/cdmbl/etl_worker.rb
CHANGED
data/lib/cdmbl/extractor.rb
CHANGED
@@ -65,7 +65,7 @@ module CDMBL
|
|
65
65
|
end
|
66
66
|
|
67
67
|
def cdm_request(collection, id)
|
68
|
-
|
68
|
+
CDMBL::CdmNotification.call!(collection, id, cdm_endpoint)
|
69
69
|
cdm_item.new(base_url: cdm_endpoint, collection: collection, id: id).metadata
|
70
70
|
end
|
71
71
|
|
data/lib/cdmbl/formatters.rb
CHANGED
data/lib/cdmbl/hooks.rb
CHANGED
@@ -2,8 +2,12 @@ module CDMBL
|
|
2
2
|
def self.const_missing(name)
|
3
3
|
if name.to_s == 'Solr'
|
4
4
|
hook(pattern: name.to_s, default: DefaultSolr)
|
5
|
-
elsif name.to_s == '
|
6
|
-
hook(pattern: name.to_s, default:
|
5
|
+
elsif name.to_s == 'CompletedCallback'
|
6
|
+
hook(pattern: name.to_s, default: DefaultCompletedCallback)
|
7
|
+
elsif name.to_s == 'OaiNotification'
|
8
|
+
hook(pattern: name.to_s, default: DefaultOaiNotification)
|
9
|
+
elsif name.to_s == 'CdmNotification'
|
10
|
+
hook(pattern: name.to_s, default: DefaultCdmNotification)
|
7
11
|
end
|
8
12
|
end
|
9
13
|
|
data/lib/cdmbl/oai_request.rb
CHANGED
data/lib/cdmbl/transformer.rb
CHANGED
@@ -48,7 +48,7 @@ module CDMBL
|
|
48
48
|
def self.default_mappings
|
49
49
|
[
|
50
50
|
{dest_path: 'location_llsi', origin_path: '/', formatters: [LocationFormatter]},
|
51
|
-
{dest_path: 'id', origin_path: 'id', formatters: [StripFormatter]},
|
51
|
+
{dest_path: 'id', origin_path: 'id', formatters: [StripFormatter, IDFormatter]},
|
52
52
|
{dest_path: 'setspec_ssi', origin_path: '/', formatters: [AddSetSpecFormatter, SetSpecFormatter]},
|
53
53
|
{dest_path: 'collection_name_ssi', origin_path: '/', formatters: [AddSetSpecFormatter, CollectionNameFormatter]},
|
54
54
|
{dest_path: 'collection_name_tei', origin_path: '/', formatters: [AddSetSpecFormatter, CollectionNameFormatter]},
|
data/lib/cdmbl/version.rb
CHANGED
data/lib/cdmbl.rb
CHANGED
@@ -11,6 +11,8 @@ require 'cdmbl/default_solr'
|
|
11
11
|
require 'cdmbl/loader'
|
12
12
|
require 'cdmbl/etl_run'
|
13
13
|
require 'cdmbl/etl_worker'
|
14
|
-
require 'cdmbl/
|
14
|
+
require 'cdmbl/default_completed_callback'
|
15
|
+
require 'cdmbl/default_cdm_notification'
|
16
|
+
require 'cdmbl/default_oai_notification'
|
15
17
|
require 'cdmbl/hooks'
|
16
18
|
require 'cdmbl/oai_filter'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cdmbl
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- chadfennell
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-10-
|
11
|
+
date: 2016-10-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: hash_at_path
|
@@ -208,7 +208,9 @@ files:
|
|
208
208
|
- bin/setup
|
209
209
|
- cdmbl.gemspec
|
210
210
|
- lib/cdmbl.rb
|
211
|
-
- lib/cdmbl/
|
211
|
+
- lib/cdmbl/default_cdm_notification.rb
|
212
|
+
- lib/cdmbl/default_completed_callback.rb
|
213
|
+
- lib/cdmbl/default_oai_notification.rb
|
212
214
|
- lib/cdmbl/default_solr.rb
|
213
215
|
- lib/cdmbl/etl_run.rb
|
214
216
|
- lib/cdmbl/etl_worker.rb
|