mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 12:15:52 +00:00
Update heketi vendor dependencies.
Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
This commit is contained in:
parent
5ca03d674e
commit
777789ac93
12
Godeps/Godeps.json
generated
12
Godeps/Godeps.json
generated
@ -1687,18 +1687,18 @@
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/heketi/heketi/client/api/go-client",
|
||||
"Comment": "v4.0.0-22-g7a54b6f",
|
||||
"Rev": "7a54b6fc903feab1e7cb6573177ca09b544eb1e2"
|
||||
"Comment": "2017-06-21T10:47:05Z",
|
||||
"Rev": "aaf40619d85fda757e7a1c1ea1b5118cea65594b"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/heketi/heketi/pkg/glusterfs/api",
|
||||
"Comment": "v4.0.0-22-g7a54b6f",
|
||||
"Rev": "7a54b6fc903feab1e7cb6573177ca09b544eb1e2"
|
||||
"Comment": "2017-06-21T10:47:05Z",
|
||||
"Rev": "aaf40619d85fda757e7a1c1ea1b5118cea65594b"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/heketi/heketi/pkg/utils",
|
||||
"Comment": "v4.0.0-22-g7a54b6f",
|
||||
"Rev": "7a54b6fc903feab1e7cb6573177ca09b544eb1e2"
|
||||
"Comment": "2017-06-21T10:47:05Z",
|
||||
"Rev": "aaf40619d85fda757e7a1c1ea1b5118cea65594b"
|
||||
},
|
||||
{
|
||||
"ImportPath": "github.com/howeyc/gopass",
|
||||
|
3
vendor/github.com/heketi/heketi/client/api/go-client/cluster.go
generated
vendored
3
vendor/github.com/heketi/heketi/client/api/go-client/cluster.go
generated
vendored
@ -14,9 +14,10 @@ package client
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"net/http"
|
||||
|
||||
"github.com/heketi/heketi/pkg/glusterfs/api"
|
||||
"github.com/heketi/heketi/pkg/utils"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) ClusterCreate() (*api.ClusterInfoResponse, error) {
|
||||
|
53
vendor/github.com/heketi/heketi/client/api/go-client/device.go
generated
vendored
53
vendor/github.com/heketi/heketi/client/api/go-client/device.go
generated
vendored
@ -15,10 +15,11 @@ package client
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"github.com/heketi/heketi/pkg/glusterfs/api"
|
||||
"github.com/heketi/heketi/pkg/utils"
|
||||
"net/http"
|
||||
"time"
|
||||
|
||||
"github.com/heketi/heketi/pkg/glusterfs/api"
|
||||
"github.com/heketi/heketi/pkg/utils"
|
||||
)
|
||||
|
||||
func (c *Client) DeviceAdd(request *api.DeviceAddRequest) error {
|
||||
@ -131,42 +132,6 @@ func (c *Client) DeviceDelete(id string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (c *Client) DeviceRemove(id string) error {
|
||||
|
||||
// Create a request
|
||||
req, err := http.NewRequest("POST",
|
||||
c.host+"/devices/"+id+"/remove",
|
||||
nil)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
// Set token
|
||||
err = c.setToken(req)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
// Send request
|
||||
r, err := c.do(req)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if r.StatusCode != http.StatusAccepted {
|
||||
return utils.GetErrorFromResponse(r)
|
||||
}
|
||||
|
||||
// Wait for response
|
||||
r, err = c.waitForResponseWithTimer(r, time.Second)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if r.StatusCode != http.StatusNoContent {
|
||||
return utils.GetErrorFromResponse(r)
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
func (c *Client) DeviceState(id string,
|
||||
request *api.StateRequest) error {
|
||||
|
||||
@ -196,8 +161,18 @@ func (c *Client) DeviceState(id string,
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if r.StatusCode != http.StatusOK {
|
||||
if r.StatusCode != http.StatusAccepted {
|
||||
return utils.GetErrorFromResponse(r)
|
||||
}
|
||||
|
||||
// Wait for response
|
||||
r, err = c.waitForResponseWithTimer(r, time.Second)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if r.StatusCode != http.StatusNoContent {
|
||||
return utils.GetErrorFromResponse(r)
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
17
vendor/github.com/heketi/heketi/client/api/go-client/node.go
generated
vendored
17
vendor/github.com/heketi/heketi/client/api/go-client/node.go
generated
vendored
@ -15,10 +15,11 @@ package client
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"github.com/heketi/heketi/pkg/glusterfs/api"
|
||||
"github.com/heketi/heketi/pkg/utils"
|
||||
"net/http"
|
||||
"time"
|
||||
|
||||
"github.com/heketi/heketi/pkg/glusterfs/api"
|
||||
"github.com/heketi/heketi/pkg/utils"
|
||||
)
|
||||
|
||||
func (c *Client) NodeAdd(request *api.NodeAddRequest) (*api.NodeInfoResponse, error) {
|
||||
@ -167,8 +168,18 @@ func (c *Client) NodeState(id string, request *api.StateRequest) error {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if r.StatusCode != http.StatusOK {
|
||||
if r.StatusCode != http.StatusAccepted {
|
||||
return utils.GetErrorFromResponse(r)
|
||||
}
|
||||
|
||||
// Wait for response
|
||||
r, err = c.waitForResponseWithTimer(r, time.Second)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if r.StatusCode != http.StatusNoContent {
|
||||
return utils.GetErrorFromResponse(r)
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
13
vendor/github.com/heketi/heketi/pkg/glusterfs/api/types.go
generated
vendored
13
vendor/github.com/heketi/heketi/pkg/glusterfs/api/types.go
generated
vendored
@ -148,12 +148,13 @@ type VolumeDurabilityInfo struct {
|
||||
|
||||
type VolumeCreateRequest struct {
|
||||
// Size in GB
|
||||
Size int `json:"size"`
|
||||
Clusters []string `json:"clusters,omitempty"`
|
||||
Name string `json:"name"`
|
||||
Durability VolumeDurabilityInfo `json:"durability,omitempty"`
|
||||
Gid int64 `json:"gid,omitempty"`
|
||||
Snapshot struct {
|
||||
Size int `json:"size"`
|
||||
Clusters []string `json:"clusters,omitempty"`
|
||||
Name string `json:"name"`
|
||||
Durability VolumeDurabilityInfo `json:"durability,omitempty"`
|
||||
Gid int64 `json:"gid,omitempty"`
|
||||
GlusterVolumeOptions []string `json:"glustervolumeoptions,omitempty"`
|
||||
Snapshot struct {
|
||||
Enable bool `json:"enable"`
|
||||
Factor float32 `json:"factor"`
|
||||
} `json:"snapshot"`
|
||||
|
Loading…
Reference in New Issue
Block a user