reshifter: github.com/mhausenblas/reshifter/app/handler Index | Files

package handler

import "github.com/mhausenblas/reshifter/app/handler"

Package handler implements the ReShifter HTTP handlers.

Index

Package Files

backup.go doc.go init.go other.go restore.go types.go

func BackupCreate Uses

func BackupCreate(w http.ResponseWriter, r *http.Request)

BackupCreate responds to HTTP POST requests such as:

http GET localhost:8080/v1/backup endpoint=http://localhost:2379

func BackupList Uses

func BackupList(w http.ResponseWriter, r *http.Request)

BackupList responds to HTTP GET requests at:

http GET localhost:8080/v1/backup/all?remote=play.minio.io:9000&bucket=test123

func BackupRetrieve Uses

func BackupRetrieve(w http.ResponseWriter, r *http.Request)

BackupRetrieve responds to HTTP GET requests such as:

http GET localhost:8080/v1/backup/1498230556

func EPstats Uses

func EPstats(w http.ResponseWriter, r *http.Request)

EPstats responds to HTTP GET requests such as:

http GET localhost:8080/v1/epstats?endpoint=http%3A%2F%2Flocalhost%3A2379

func Explorer Uses

func Explorer(w http.ResponseWriter, r *http.Request)

Explorer responds to HTTP GET requests such as:

http GET localhost:8080/v1/explorer?endpoint=http%3A%2F%2Flocalhost%3A2379

func Restore Uses

func Restore(w http.ResponseWriter, r *http.Request)

Restore responds to HTTP POST requests such as:

http POST localhost:8080/v1/restore endpoint=http://localhost:2379 backupid=1498230556

func RestoreUpload Uses

func RestoreUpload(w http.ResponseWriter, r *http.Request)

RestoreUpload responds to HTTP POST requests at:

http POST localhost:8080/v1/restore/upload

func Version Uses

func Version(w http.ResponseWriter, r *http.Request)

Version responds to HTTP GET requests of the form:

http GET localhost:8080/v1/version

type BackupRequest Uses

type BackupRequest struct {
    Endpoint   string `json:"endpoint"`
    Remote     string `json:"remote"`
    Bucket     string `json:"bucket"`
    Filter     string `json:"filter"`
    APIversion string `json:"apiversion"`
}

BackupRequest represents the request for a backup operation.

type BackupResult Uses

type BackupResult struct {
    Outcome  string `json:"outcome"`
    BackupID string `json:"backupid"`
}

BackupResult represents the results of a backup operation.

type RestoreRequest Uses

type RestoreRequest struct {
    Endpoint string `json:"endpoint"`
    BackupID string `json:"backupid"`
    Remote   string `json:"remote"`
    Bucket   string `json:"bucket"`
}

RestoreRequest represents the request for a restore operation.

type RestoreResult Uses

type RestoreResult struct {
    Outcome      string  `json:"outcome"`
    KeysRestored int     `json:"keysrestored"`
    ElapsedTime  float64 `json:"elapsedtimeinsec"`
}

RestoreResult represents the results of a restore operation.

Package handler imports 16 packages (graph) and is imported by 1 packages. Updated 2017-08-28. Refresh now. Tools for package owners.