gds-api-adapters 49.3.1 → 49.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/gds_api/asset_manager.rb +12 -2
- data/lib/gds_api/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: eeb45e805895d2c5ee34ee020e602ecc6125b8ca
|
4
|
+
data.tar.gz: c62ba6e528ae2d6ba93eefccd0932837e5446bb8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
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+.
|
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:
|
data/lib/gds_api/version.rb
CHANGED
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.
|
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-
|
11
|
+
date: 2017-10-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: plek
|