dor-services 5.22.0 → 5.22.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: bde408e6b6c497dc4f8277d3add306ff5d48b7bd
4
- data.tar.gz: cfb7c3ed58070a318bd0a7b7b3a4fd2ab3173b0d
3
+ metadata.gz: c6dab8f7f2a56e8bfde680d4785508bad8ce7142
4
+ data.tar.gz: 565fe3f2bab1843247d24565b6a5e4109cc33f5d
5
5
  SHA512:
6
- metadata.gz: f2cd0466d2c7d1f956f833b196b38b4856538b0b9b9fd878d3a5ad34e4f7c360d964f9eecbaa4291f54451b77510716316237da7a6bfa988ce30f2f0d8991497
7
- data.tar.gz: ae929d047ad3be11175451913b8f4b08120a20dbaacbb25ade5014593701b3ab2e9cb100a01aaad019f0f1841bd3464347a94de71f19487d68748026a57f3a36
6
+ metadata.gz: 59ad5521ef58aa0ceaa66e5a75f55273f45041aec06f48587b2218bc4b9d2680fbb5e62844c11271025ba84d12f922515049c999eef2a11dc667a13593c956c4
7
+ data.tar.gz: 31198cf58c69a2c3ff6dd434ef5ba04485b28df11f82f317ddbf9470fa8b8399671e8143bb6aac64e0b661ab04b6daf657502b2872856c1817db6d48a71f5f54
@@ -0,0 +1,29 @@
1
+ -----BEGIN CERTIFICATE-----
2
+ MIIE3zCCAscCCQCcUJVDTu7rPzANBgkqhkiG9w0BAQUFADCBvzELMAkGA1UEBhMC
3
+ VVMxEzARBgNVBAgTCkNhbGlmb3JuaWExETAPBgNVBAcTCFN0YW5mb3JkMRwwGgYD
4
+ VQQKExNTdGFuZm9yZCBVbml2ZXJzaXR5MRIwEAYDVQQLEwlMaWJyYXJpZXMxJTAj
5
+ BgNVBAMTHFNVTCBET1IgKGRldi90ZXN0KSBhY2Nlc3MgQ0ExLzAtBgkqhkiG9w0B
6
+ CQEWIHN1bC13ZWJtYXN0ZXJAbGlzdHMuc3RhbmZvcmQuZWR1MB4XDTEyMDkyNjAw
7
+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m6DCrVA6zOx
18
+ 3iWd+rLNxIpN3fhskzclNnhn+WhGo7xktuIrVDHvAoGBAPLWVVLKTllQkWIFaRu2
19
+ GA08yMuP1DFX0JcOrqi+BuUeDkslEh8N8oMGld9hnSojzBg/Hkd/fmN6Q4RO5qQe
20
+ QqH90oUCk9Tzordx9EAxHEgt03dDYFwG0Eb+68lZc/23PNGZ2Vr8+F/lxCAVMtH3
21
+ Avnyw3Gx/pj54zcpiYin8DqNAoGBAKSqcdfSX9Id6ZvES0E83Zs4p486vkEaCB8H
22
+ j4y7veS1vDrdWmbfJYelw1/lSMiaMv8qVgj6DYwJGmdH4rrKPrFbY55PD1dmpdjC
23
+ YdYlkMk3XIopsc6pimkx3GTIYJSe5iU5O762ZYo58IGNOcr6W6eWV7D8UiTlESOy
24
+ 52yR5gGjAoGALfzgCSIAVlOli3a7m3aMWUtGhp+sVi7jGLE9NHTwFXnkYEoXmR+v
25
+ 5CIvK8IzwtATEomoAa2GKGek8MSE+H1/o+SrGL9PIATnzuEZeJOIMnGa5mO26a9/
26
+ eV2Qud4v/7qD2P2VnCVYaAMYqS6l0SxB11/UhuQiWdpITxy44CK1Jk8=
27
+ -----END RSA PRIVATE KEY-----
@@ -0,0 +1,66 @@
1
+ cert_dir = File.join(File.dirname(__FILE__), "certs")
2
+
3
+ Dor::Config.configure do
4
+
5
+ fedora do
6
+ url 'https://sul-dor-test.stanford.edu/fedora'
7
+ end
8
+
9
+ ssl do
10
+ cert_file File.join(cert_dir,"dlss-dev-petucket-dor-dev.crt")
11
+ key_file File.join(cert_dir,"dlss-dev-petucket-dor-dev.key")
12
+ key_pass ''
13
+ end
14
+
15
+ sdr do
16
+ url 'http://localhost'
17
+ local_workspace_root '/dor/workspace'
18
+ local_export_home '/dor/export'
19
+ end
20
+
21
+ suri do
22
+ mint_ids true
23
+ id_namespace 'druid'
24
+ url 'http://sul-lyberservices-test.stanford.edu'
25
+ user 'labware'
26
+ pass 'lyberteam'
27
+ end
28
+
29
+ solr.url 'https://sul-solr-tester.stanford.edu/argo_stage'
30
+ workflow.url 'https://sul-lyberservices-test.stanford.edu/workflow/'
31
+
32
+ purl do
33
+ base_url 'https://purl-test.stanford.edu/'
34
+ end
35
+
36
+ remediation do
37
+ check_for_versioning_required false # this MUST be true in production; can be false in development and test if you want to ignore workflow checks
38
+ check_for_in_accessioning false # this MUST be true in production; can be false in development and test if you want to ignore workflow checks
39
+ end
40
+
41
+ dor do
42
+ service_root 'https://dorAdmin:dorAdmin@sul-lyberservices-test.stanford.edu/dor/v1'
43
+ num_attempts 3 # the number of attempts to contact the dor web service before throwing an exception
44
+ sleep_time 2 # sleep time in seconds between attempts to contact the dor service
45
+ default_label 'Untitled' # the default label for an object that is registered when no label is provided in the manifest
46
+ end
47
+
48
+ content do
49
+ content_user 'lyberadmin'
50
+ content_base_dir '/dor/workspace/'
51
+ content_server 'lyberservices-test'
52
+ end
53
+ status do
54
+ indexer_url 'http://sulstats-raw.stanford.edu//render/?format=json&from=-1minute&until=now&target=stats.gauges.dor-prod.argo.reindexqueue.queue-size.count'
55
+ end
56
+ stacks do
57
+ document_cache_storage_root '/home/lyberadmin/document_cache'
58
+ document_cache_host 'purl-test.stanford.edu'
59
+ document_cache_user 'lyberadmin'
60
+ local_workspace_root '/dor/workspace'
61
+ storage_root '/stacks'
62
+ host 'stacks-test.stanford.edu'
63
+ user 'lyberadmin'
64
+ end
65
+
66
+ end
@@ -3,6 +3,10 @@ module Dor
3
3
  extend ActiveSupport::Concern
4
4
  include SolrDocHelper
5
5
 
6
+ # ids for previous and current catkeys
7
+ CATKEY_TYPE_ID = 'catkey'.freeze
8
+ PREVIOUS_CATKEY_TYPE_ID = 'previous_catkey'.freeze
9
+
6
10
  included do
7
11
  has_metadata :name => 'DC', :type => SimpleDublinCoreDs, :label => 'Dublin Core Record for self object'
8
12
  has_metadata :name => 'identityMetadata', :type => Dor::IdentityMetadataDS, :label => 'Identity Metadata'
@@ -87,6 +91,37 @@ module Dor
87
91
  alias_method :set_source_id, :source_id=
88
92
  deprecate set_source_id: 'Use source_id= instead'
89
93
 
94
+ # Convenience method to get the current catkey
95
+ # @return [String] current catkey value (or nil if none found)
96
+ def catkey
97
+ identityMetadata.otherId(CATKEY_TYPE_ID).first
98
+ end
99
+
100
+ # Convenience method to set the catkey
101
+ # @param [String] catkey the new source identifier
102
+ # @return [String] same value, as per Ruby assignment convention
103
+ def catkey=(val)
104
+
105
+ # try and grab the current and previous catkeys
106
+ current_catkey = catkey
107
+
108
+ # if there is no current catkey, then add it and we are done
109
+ if current_catkey.blank?
110
+ add_other_Id(CATKEY_TYPE_ID,val)
111
+ elsif val != current_catkey # if there is a current catkey, store that in the "previous" spot assuming there is no change
112
+ identityMetadata.add_otherId("#{PREVIOUS_CATKEY_TYPE_ID}:#{current_catkey}")
113
+ # and then update the current catkey to the new value
114
+ update_other_Id(CATKEY_TYPE_ID,val)
115
+ end
116
+ val
117
+ end
118
+
119
+ # Convenience method to get the previous catkeys (will be an array)
120
+ # @return [Array] previous catkey values (empty array if none found)
121
+ def previous_catkeys
122
+ identityMetadata.otherId(PREVIOUS_CATKEY_TYPE_ID)
123
+ end
124
+
90
125
  def add_other_Id(type, val)
91
126
  if identityMetadata.otherId(type).length > 0
92
127
  raise 'There is an existing entry for ' + type + ', consider using update_other_Id().'
@@ -204,7 +239,7 @@ module Dor
204
239
  # @return [String] the druid sans the druid: or if there was no druid: prefix, the entire string you passed
205
240
  def remove_druid_prefix(druid=id)
206
241
  result=druid.match(/#{pid_regex}/)
207
- result.nil? ? druid : result[0] # if no matches, return the string passed in, otherwise return the match
242
+ result.nil? ? druid : result[0] # if no matches, return the string passed in, otherwise return the match
208
243
  end
209
244
 
210
245
  # Override ActiveFedora::Core#adapt_to_cmodel (used with associations, among other places) to
@@ -1,3 +1,3 @@
1
1
  module Dor
2
- VERSION = '5.22.0'.freeze
2
+ VERSION = '5.22.1'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dor-services
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.22.0
4
+ version: 5.22.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Klein
@@ -14,7 +14,7 @@ authors:
14
14
  autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
- date: 2017-02-22 00:00:00.000000000 Z
17
+ date: 2017-02-28 00:00:00.000000000 Z
18
18
  dependencies:
19
19
  - !ruby/object:Gem::Dependency
20
20
  name: active-fedora
@@ -588,7 +588,13 @@ extensions: []
588
588
  extra_rdoc_files: []
589
589
  files:
590
590
  - config/certs/README
591
+ - config/certs/dlss-dev-petucket-dor-dev.crt
592
+ - config/certs/dlss-dev-petucket-dor-dev.csr
593
+ - config/certs/dlss-dev-petucket-dor-dev.key
594
+ - config/certs/dlss-dev-petucket-dor-prod.crt
595
+ - config/certs/dlss-dev-petucket-dor-prod.key
591
596
  - config/config_defaults.yml
597
+ - config/dev_console_env.rb
592
598
  - config/dev_console_env.rb.example
593
599
  - config/predicate_mappings.yml
594
600
  - lib/dor-services.rb
@@ -682,8 +688,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
682
688
  version: 1.3.6
683
689
  requirements: []
684
690
  rubyforge_project:
685
- rubygems_version: 2.6.8
691
+ rubygems_version: 2.6.10
686
692
  signing_key:
687
693
  specification_version: 4
688
694
  summary: Ruby implmentation of DOR services used by the SULAIR Digital Library
689
695
  test_files: []
696
+ has_rdoc: