Class: PurlFetcher::Client::LegacyPublish
- Inherits:
-
Object
- Object
- PurlFetcher::Client::LegacyPublish
- Defined in:
- lib/purl_fetcher/client/legacy_publish.rb
Overview
Publish (metadata-only). This will be replaced with a single publish operation
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(cocina:) ⇒ LegacyPublish
constructor
A new instance of LegacyPublish.
- #publish ⇒ Object
Constructor Details
#initialize(cocina:) ⇒ LegacyPublish
Returns a new instance of LegacyPublish.
13 14 15 |
# File 'lib/purl_fetcher/client/legacy_publish.rb', line 13 def initialize(cocina:) @cocina = cocina end |
Class Method Details
.publish(cocina:) ⇒ Object
8 9 10 |
# File 'lib/purl_fetcher/client/legacy_publish.rb', line 8 def self.publish(cocina:) new(cocina:).publish end |
Instance Method Details
#publish ⇒ Object
17 18 19 20 21 |
# File 'lib/purl_fetcher/client/legacy_publish.rb', line 17 def publish logger.debug("Starting a legacy publish request for: #{druid}") response = client.post(path:, body:) logger.debug("Legacy publish request complete") end |