forked from gluster/glusterd2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
command.go
24 lines (21 loc) · 800 Bytes
/
command.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// Package commands defines the command interfaces that need to be implemented by the GlusterD commands
package commands
import (
"github.com/gluster/glusterd2/commands/peers"
"github.com/gluster/glusterd2/commands/version"
"github.com/gluster/glusterd2/commands/volumes"
"github.com/gluster/glusterd2/rest"
)
// Command is the interface that needs to be implemented by the GlusterD commands
type Command interface {
// Routes should return a table of REST API endpoints and handlers for the command
Routes() rest.Routes
// SetTransactionHandlers will setup the transaction handlers for the command
//SetTransactionHandlers() error
}
// Commands is a list of commands available
var Commands = []Command{
&versioncommands.Command{},
&volumecommands.Command{},
&peercommands.Command{},
}