crowbar-client 3.1.5 → 3.1.6
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/CHANGELOG.md +11 -0
- data/lib/crowbar/client/app/upgrade.rb +1 -1
- data/lib/crowbar/client/command/node/rename.rb +2 -0
- data/lib/crowbar/client/command/proposal/reset.rb +4 -1
- data/lib/crowbar/client/command/upgrade/cancel.rb +4 -2
- data/lib/crowbar/client/command/upgrade/database.rb +0 -1
- data/lib/crowbar/client/mixin.rb +3 -0
- data/lib/crowbar/client/mixin/simple_error.rb +38 -0
- data/lib/crowbar/client/request/upgrade/backup.rb +2 -2
- data/lib/crowbar/client/version.rb +1 -1
- data/spec/crowbar/client/request/upgrade/backup_spec.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: db7753c52a0bdc07da4e50d90b7b14db6b31c165
|
4
|
+
data.tar.gz: c7ba06a39fe3368164264435f6f98c5ee364c162
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 830a4bcb1d6276fc62d4c9d3f4a031ff4d59f64736befeaa626038f3fb4ef1efe34cbc7ed2e6bd792f427ec44af37f3ac52864dfd36ad2e7846e9c708c7c3194
|
7
|
+
data.tar.gz: 17811f67aeef2e2334e2388136eb0e2ad1d4e52dcc49fb0e429f5056504c00be3c6a1b7bbef25b6e38055458ed63b81a0a5602b26b77fb38686a86312cbd626c
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,16 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## [3.1.6](https://github.com/crowbar/crowbar-client/releases/tag/v3.1.6) - 2017-01-05
|
4
|
+
|
5
|
+
* BUGFIX
|
6
|
+
* Catch error 406 when node alias is not unique (bsc#1011581) (@MaximilianMeister)
|
7
|
+
* Use cancel not prepare (@MaximilianMeister)
|
8
|
+
* ENHANCEMENT
|
9
|
+
* Adapt http codes for upgrade cancel (@MaximilianMeister)
|
10
|
+
* Add SimpleError mixxin (@rsalevsky)
|
11
|
+
* Schema migration is included in the crowbar-init step now (@MaximilianMeister)
|
12
|
+
* Change endpoint of the openstack backup (@MaximilianMeister)
|
13
|
+
|
3
14
|
## [3.1.5](https://github.com/crowbar/crowbar-client/releases/tag/v3.1.5) - 2016-12-06
|
4
15
|
|
5
16
|
* BUGFIX
|
@@ -22,6 +22,7 @@ module Crowbar
|
|
22
22
|
# Implementation for the proposal reset command
|
23
23
|
#
|
24
24
|
class Reset < Base
|
25
|
+
include Mixin::SimpleError
|
25
26
|
include Mixin::Barclamp
|
26
27
|
|
27
28
|
def request
|
@@ -40,7 +41,9 @@ module Crowbar
|
|
40
41
|
when 404
|
41
42
|
say "Proposal does not exist"
|
42
43
|
else
|
43
|
-
err
|
44
|
+
err format_error(
|
45
|
+
request.parsed_response["error"]
|
46
|
+
)
|
44
47
|
end
|
45
48
|
end
|
46
49
|
end
|
@@ -33,8 +33,10 @@ module Crowbar
|
|
33
33
|
case request.code
|
34
34
|
when 200
|
35
35
|
say "Canceled the upgrade process"
|
36
|
-
when
|
37
|
-
err "
|
36
|
+
when 422
|
37
|
+
err "Failed to cancel the upgrade process"
|
38
|
+
when 423
|
39
|
+
err "Not possible to cancel the upgrade at this stage; Please refer to help output."
|
38
40
|
else
|
39
41
|
err request.parsed_response["error"]
|
40
42
|
end
|
data/lib/crowbar/client/mixin.rb
CHANGED
@@ -0,0 +1,38 @@
|
|
1
|
+
#
|
2
|
+
# Copyright 2016, SUSE Linux GmbH
|
3
|
+
#
|
4
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
+
# you may not use this file except in compliance with the License.
|
6
|
+
# You may obtain a copy of the License at
|
7
|
+
#
|
8
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
+
#
|
10
|
+
# Unless required by applicable law or agreed to in writing, software
|
11
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
+
# See the License for the specific language governing permissions and
|
14
|
+
# limitations under the License.
|
15
|
+
#
|
16
|
+
|
17
|
+
require "active_support/concern"
|
18
|
+
|
19
|
+
module Crowbar
|
20
|
+
module Client
|
21
|
+
module Mixin
|
22
|
+
#
|
23
|
+
# A mixin with error related helpers
|
24
|
+
#
|
25
|
+
module SimpleError
|
26
|
+
extend ActiveSupport::Concern
|
27
|
+
|
28
|
+
included do
|
29
|
+
def format_error(response)
|
30
|
+
JSON.parse(response.body)["error"]
|
31
|
+
rescue
|
32
|
+
"Unable to format error response"
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: crowbar-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.1.
|
4
|
+
version: 3.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Thomas Boerger
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2017-01-05 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: bundler
|
@@ -345,6 +345,7 @@ files:
|
|
345
345
|
- lib/crowbar/client/mixin/database.rb
|
346
346
|
- lib/crowbar/client/mixin/filter.rb
|
347
347
|
- lib/crowbar/client/mixin/format.rb
|
348
|
+
- lib/crowbar/client/mixin/simple_error.rb
|
348
349
|
- lib/crowbar/client/mixin/upgrade_error.rb
|
349
350
|
- lib/crowbar/client/request.rb
|
350
351
|
- lib/crowbar/client/request/backup.rb
|