gds-api-adapters 49.3.1 → 49.4.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
  SHA1:
3
- metadata.gz: 62fb1a303990d06bb0aa4c5839ae7a233626c461
4
- data.tar.gz: baba94202d20913a07a3053a4d47a504c9c3b2f8
3
+ metadata.gz: eeb45e805895d2c5ee34ee020e602ecc6125b8ca
4
+ data.tar.gz: c62ba6e528ae2d6ba93eefccd0932837e5446bb8
5
5
  SHA512:
6
- metadata.gz: f347372495223c6fc802472f12d772dc8f86685303b74b7b8db6cfaa3b4fd98325b64672c7b2787dd85a8024e9ce5dfcc4370c00eb6c98121e1b831976379cc3
7
- data.tar.gz: 2c4eaee67894ab3ac70d1ea25e546ef8a2e8ba95261ac88fe0f814a1e269e53e705fc4b918d704e020e3c9a009046306a646f1e8f3dc037964ba6794c9efa1d7
6
+ metadata.gz: 4e10db677108ef87cd67aa6c62bc4cb4a077eb00109d12adf68dcad9d0ae045ef8983e4c62d3fdd3634fa419aa1916deb005064b6957ddf10e9ce9b4e6baed12
7
+ data.tar.gz: dcfae2f18ff81404d21bc6823cd4df39fa7737a8d5cd53dc8d28ac1e6134502db88b35158a991ec298fd0450dadb518fd7688ebddd1298fd3381b98565d919c5
@@ -48,7 +48,7 @@ class GdsApi::AssetManager < GdsApi::Base
48
48
  end
49
49
 
50
50
  # Creates a Whitehall asset given a hash with +file+ & +legacy_url_path+
51
- # attributes
51
+ # (required) and +legacy_etag+ & +legacy_last_modified+ (optional) attributes
52
52
  #
53
53
  # Makes a +POST+ request to the asset manager api to create a Whitehall asset.
54
54
  #
@@ -73,12 +73,22 @@ class GdsApi::AssetManager < GdsApi::Base
73
73
  # supplied path is not valid, a `GdsApi::HTTPUnprocessableEntity` exception
74
74
  # will be raised.
75
75
  #
76
+ # The optional +legacy_etag+ & +legacy_last_modified+ attributes allow the
77
+ # client to specify the values that should be used in the `ETag` &
78
+ # `Last-Modified` response headers when the asset is requested via its public
79
+ # URL. They are only intended to be used for migrating existing Whitehall
80
+ # assets to Asset Manager so that we can avoid wholesale cache invalidation.
81
+ # New Whitehall assets should not specify values for these attributes; Asset
82
+ # Manager will generate suitable values.
83
+ #
76
84
  # Note: this endpoint should only be used by the Whitehall Admin app and not
77
85
  # by any other publishing apps.
78
86
  #
79
87
  # @param asset [Hash] The attributes for the asset to send to the api. Must
80
88
  # contain +file+, which behaves like a +File+, and +legacy_url_path+, a
81
- # +String+. All other attributes will be ignored.
89
+ # +String+. May contain +legacy_etag+, a +String+, and
90
+ # +legacy_last_modified+, a +Time+ object. All other attributes will be
91
+ # ignored.
82
92
  #
83
93
  # @return [GdsApi::Response] The wrapped http response from the api. Behaves
84
94
  # both as a +Hash+ and an +OpenStruct+, and responds to the following:
@@ -1,3 +1,3 @@
1
1
  module GdsApi
2
- VERSION = '49.3.1'.freeze
2
+ VERSION = '49.4.0'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gds-api-adapters
3
3
  version: !ruby/object:Gem::Version
4
- version: 49.3.1
4
+ version: 49.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Stewart
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-09-28 00:00:00.000000000 Z
11
+ date: 2017-10-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: plek