You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@brooklyn.apache.org by dr...@apache.org on 2017/05/08 11:58:30 UTC
[1/2] brooklyn-client git commit: Delete catalog.xml support
(including /v1/catalog/reset)
Repository: brooklyn-client
Updated Branches:
refs/heads/master 6d5574af6 -> 0243386ce
Delete catalog.xml support (including /v1/catalog/reset)
Project: http://git-wip-us.apache.org/repos/asf/brooklyn-client/repo
Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-client/commit/72c98aa6
Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-client/tree/72c98aa6
Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-client/diff/72c98aa6
Branch: refs/heads/master
Commit: 72c98aa6ce076118894113abba3ae23a65d567a3
Parents: 95d1fb0
Author: Aled Sage <al...@gmail.com>
Authored: Wed May 3 11:19:39 2017 +0100
Committer: Aled Sage <al...@gmail.com>
Committed: Wed May 3 11:19:39 2017 +0100
----------------------------------------------------------------------
cli/api/catalog/catalog.go | 9 ---------
cli/commands/reset-catalog.go | 33 ---------------------------------
2 files changed, 42 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/brooklyn-client/blob/72c98aa6/cli/api/catalog/catalog.go
----------------------------------------------------------------------
diff --git a/cli/api/catalog/catalog.go b/cli/api/catalog/catalog.go
index 2ff3a88..765c752 100644
--- a/cli/api/catalog/catalog.go
+++ b/cli/api/catalog/catalog.go
@@ -181,15 +181,6 @@ func AddCatalog(network *net.Network, resource string) (map[string]models.Catalo
return entities, nil
}
-func Reset(network *net.Network) (string, error) {
- url := "/v1/catalog/reset"
- body, err := network.SendEmptyPostRequest(url)
- if err != nil {
- return "", err
- }
- return string(body), nil
-}
-
func GetLocation(network *net.Network, locationId string) (models.CatalogItemSummary, error) {
url := fmt.Sprintf("/v1/catalog/locations/%s", locationId)
var catalogLocation models.CatalogItemSummary
http://git-wip-us.apache.org/repos/asf/brooklyn-client/blob/72c98aa6/cli/commands/reset-catalog.go
----------------------------------------------------------------------
diff --git a/cli/commands/reset-catalog.go b/cli/commands/reset-catalog.go
deleted file mode 100644
index d7dfcae..0000000
--- a/cli/commands/reset-catalog.go
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package commands
-
-import (
- "github.com/apache/brooklyn-client/cli/net"
-)
-
-type ResetCatalog struct {
- network *net.Network
-}
-
-func NewResetCatalog(network *net.Network) (cmd *ResetCatalog) {
- cmd = new(ResetCatalog)
- cmd.network = network
- return
-}
[2/2] brooklyn-client git commit: This closes #50
Posted by dr...@apache.org.
This closes #50
Project: http://git-wip-us.apache.org/repos/asf/brooklyn-client/repo
Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-client/commit/0243386c
Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-client/tree/0243386c
Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-client/diff/0243386c
Branch: refs/heads/master
Commit: 0243386ce7ec5bfb20796afb39ee0e53e3858c88
Parents: 6d5574a 72c98aa
Author: Duncan Godwin <dr...@googlemail.com>
Authored: Mon May 8 12:58:24 2017 +0100
Committer: Duncan Godwin <dr...@googlemail.com>
Committed: Mon May 8 12:58:24 2017 +0100
----------------------------------------------------------------------
cli/api/catalog/catalog.go | 9 ---------
cli/commands/reset-catalog.go | 33 ---------------------------------
2 files changed, 42 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/brooklyn-client/blob/0243386c/cli/api/catalog/catalog.go
----------------------------------------------------------------------
diff --cc cli/api/catalog/catalog.go
index 7a422e2,765c752..108cf4b
--- a/cli/api/catalog/catalog.go
+++ b/cli/api/catalog/catalog.go
@@@ -278,19 -178,9 +278,10 @@@ func AddCatalog(network *net.Network, r
return nil, err
}
err = json.Unmarshal(body, &entities)
- return entities, nil
+
+ return entities, err
}
- func Reset(network *net.Network) (string, error) {
- url := "/v1/catalog/reset"
- body, err := network.SendEmptyPostRequest(url)
- if err != nil {
- return "", err
- }
- return string(body), nil
- }
-
func GetLocation(network *net.Network, locationId string) (models.CatalogItemSummary, error) {
url := fmt.Sprintf("/v1/catalog/locations/%s", locationId)
var catalogLocation models.CatalogItemSummary