Documentation
¶
Overview ¶
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Licensed 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.
Index ¶
- Constants
- Variables
- func AddDefaultProfiles() error
- func AddDefaultUser() error
- func AddStorageNodeToDB(hostname string, node_state models.NodeState, node_status models.NodeStatus, ...) error
- func AverageAndUpdateDb(ctxt string, mValue float64, count int, time_stamp_str string, ...) float64
- func Check_status(hostname string, ctxt string)
- func ClusterUnmanaged(cluster_id uuid.UUID) (bool, error)
- func ComputeClusterSummary(cluster models.Cluster, ctxt string)
- func ComputeSystemSummary(p map[string]interface{})
- func DeleteClusterSchedule(clusterId uuid.UUID)
- func FailStillCreatingClusters(ctxt string)
- func FetchAggregatedStatsFromGraphite(ctxt string, hostname string, resourceName string, counter *int, ...) (value float64)
- func FetchStatFromGraphite(ctxt string, hostname string, resourceName string, counter *int) (value float64)
- func FetchStatFromGraphiteWithErrorIndicate(ctxt string, hostname string, resourceName string) (value float64, isSuccess bool)
- func GetAuthProvider() authprovider.AuthInterface
- func GetCluster(cluster_id *uuid.UUID) (cluster models.Cluster, err error)
- func GetClusterByName(clusterName string) (cluster models.Cluster, err error)
- func GetClusterNameById(clusterId *uuid.UUID) (string, error)
- func GetClusters() (models.Clusters, error)
- func GetContext(r *http.Request) (string, error)
- func GetCoreNodeManager() nodemanager.NodeManagerInterface
- func GetDbProvider() dbprovider.DbInterface
- func GetDetails(m map[string]interface{}) (models.MailNotifier, error)
- func GetEventById(w http.ResponseWriter, r *http.Request)
- func GetEvents(rw http.ResponseWriter, req *http.Request)
- func GetMonitoringManager() monitoring.MonitoringManagerInterface
- func GetNode(node_id uuid.UUID) (node models.Node, err error)
- func GetSLU(cluster_id *uuid.UUID, slu_id uuid.UUID) (slu models.StorageLogicalUnit, err error)
- func GetSluIds(storage_profile string, clusterid uuid.UUID, ctxt string) ([]uuid.UUID, error)
- func HandleHttpError(rw http.ResponseWriter, err error)
- func HttpResponse(w http.ResponseWriter, status_code int, msg string, args ...string)
- func InitMonitoringSchedules()
- func Initialize(node string, ctxt string) error
- func LockCluster(ctxt string, cluster models.Cluster, operation string) (*lock.AppLock, error)
- func LockNodes(ctxt string, nodes models.Nodes, operation string) (*lock.AppLock, error)
- func Paginate(pageNo int, pageSize int, apiLimit int) (startIndex int, endIndex int)
- func ParseStatFromCollectd(mValue string) (float64, error)
- func PatchEvent(w http.ResponseWriter, r *http.Request)
- func RefreshDBSession(params map[string]interface{})
- func ScheduleCluster(clusterId uuid.UUID, intervalInSecs int)
- func SyncNodeUtilization(ctxt string, node models.Node, time_stamp_str string)
- func SyncNodeUtilizations(params map[string]interface{})
- func SynchroniseScheduleMaintainers(clusterId uuid.UUID) (schedule.Scheduler, error)
- func UpdateMetricToTimeSeriesDb(ctxt string, mValue float64, time_stamp_str string, tableName string)
- func UpdateStorageNodeToDB(hostname string, node_state models.NodeState, node_status models.NodeStatus, ...) error
- type APIError
- type App
- func (a *App) About(w http.ResponseWriter, r *http.Request)
- func (a *App) AddMailNotifier(rw http.ResponseWriter, req *http.Request)
- func (a *App) DELETE_BlockDevice(w http.ResponseWriter, r *http.Request)
- func (a *App) DELETE_Node(w http.ResponseWriter, r *http.Request)
- func (a *App) DELETE_Nodes(w http.ResponseWriter, r *http.Request)
- func (a *App) DELETE_StorageProfile(w http.ResponseWriter, r *http.Request)
- func (a *App) DEL_Storage(w http.ResponseWriter, r *http.Request)
- func (a *App) DiskHierarchy(w http.ResponseWriter, r *http.Request)
- func (a *App) Expand_Cluster(w http.ResponseWriter, r *http.Request)
- func (a *App) FetchClusterDetailsFromProvider(ctxt string, clusterId uuid.UUID) (retVal map[string]map[string]interface{}, err error)
- func (a *App) FetchMonitoringDetailsFromProviders(ctxt string) (retVal map[string]map[string]interface{}, err error)
- func (a *App) Forget_Cluster(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_AllStorages(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_BlockDevice(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_BlockDevices(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_Cluster(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_ClusterBlockDevices(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_ClusterConfig(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_ClusterNode(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_ClusterNodes(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_ClusterNodesForImport(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_ClusterSlu(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_ClusterSlus(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_ClusterStorageBlockDevices(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_Clusters(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_Disk(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_Disks(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_LookupNode(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_MonitoringPlugins(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_Node(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_NodeSlus(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_NodeSummary(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_Nodes(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_Slus(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_SshFingerprint(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_Storage(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_StorageProfile(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_StorageProfiles(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_Storages(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_UnmanagedNodes(w http.ResponseWriter, r *http.Request)
- func (a *App) GET_Utilization(w http.ResponseWriter, r *http.Request)
- func (a *App) GetLockManager() lock.LockManager
- func (a *App) GetMailNotifier(rw http.ResponseWriter, req *http.Request)
- func (a *App) GetProviderFromClusterId(ctxt string, cluster_id uuid.UUID) *Provider
- func (a *App) GetTaskManager() *task.Manager
- func (a *App) Get_ClusterSummary(w http.ResponseWriter, r *http.Request)
- func (a *App) Get_Summary(w http.ResponseWriter, r *http.Request)
- func (a *App) Get_SystemUtilization(w http.ResponseWriter, r *http.Request)
- func (a *App) ImportCluster(w http.ResponseWriter, r *http.Request)
- func (a *App) InitializeApplication(sysConfig conf.SkyringCollection, configDir string) error
- func (a *App) LoadEventTypes(configDir string, configFile string) error
- func (a *App) LoadRoutes()
- func (a *App) LoggingContext(w http.ResponseWriter, r *http.Request, next http.HandlerFunc)
- func (a *App) LoginRequired(w http.ResponseWriter, r *http.Request, next http.HandlerFunc)
- func (a *App) Manage_Cluster(w http.ResponseWriter, r *http.Request)
- func (a *App) MonitorCluster(params map[string]interface{})
- func (a *App) PATCH_ClusterSlu(w http.ResponseWriter, r *http.Request)
- func (a *App) PATCH_Clusters(w http.ResponseWriter, r *http.Request)
- func (a *App) PATCH_Disk(w http.ResponseWriter, r *http.Request)
- func (a *App) PATCH_ResizeBlockDevice(w http.ResponseWriter, r *http.Request)
- func (a *App) PATCH_Storage(w http.ResponseWriter, r *http.Request)
- func (a *App) PATCH_StorageProfile(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_AcceptUnamangedNode(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_Actions(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_AddMonitoringPlugin(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_BlockDevices(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_Clusters(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_MonitoringPluginDisable(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_MonitoringPluginEnable(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_Nodes(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_ReSyncClusterSummary(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_ReSyncNodeSummary(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_ReSyncNodesSummary(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_ReSyncSystemSummary(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_StorageProfiles(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_Storages(w http.ResponseWriter, r *http.Request)
- func (a *App) POST_froceUpdateMonitoringConfiguration(w http.ResponseWriter, r *http.Request)
- func (a *App) PUT_Thresholds(w http.ResponseWriter, r *http.Request)
- func (a *App) PatchMailNotifier(rw http.ResponseWriter, req *http.Request)
- func (a *App) PostInitApplication(sysConfig conf.SkyringCollection) error
- func (a *App) ProviderHandler(w http.ResponseWriter, r *http.Request)
- func (a *App) REMOVE_MonitoringPlugin(w http.ResponseWriter, r *http.Request)
- func (a *App) RouteProviderBasedMonitoring(ctxt string, cluster_id uuid.UUID)
- func (a *App) RouteProviderEvents(ctxt string, event models.AppEvent) error
- func (a *App) SetRoutes(router *mux.Router) error
- func (a *App) StartProviders(configDir string, binDir string) error
- func (a *App) SyncClusterDetails(params map[string]interface{})
- func (a *App) TestMailNotifier(rw http.ResponseWriter, req *http.Request)
- func (a *App) Unmanage_Cluster(w http.ResponseWriter, r *http.Request)
- type ContextKey
- type CoreRoute
- type Provider
Constants ¶
const ( DefaultUserName = "admin" DefaultPassword = "admin" DefaultEmail = "admin@localhost" DefaultRole = "admin" )
const ( //DefaultMaxAge set to a week DefaultMaxAge = 86400 * 7 DEFAULT_API_PREFIX = "/api" LoggingCtxt ContextKey = 0 Timeout = 30 )
Variables ¶
var ( //Routes that require Auth to be added here CORE_ROUTES []CoreRoute //Routes that doesnot require Auth to be added here CORE_ROUTES_NOAUTH []CoreRoute )
var ( CoreNodeManager nodemanager.NodeManagerInterface MonitoringManager monitoring.MonitoringManagerInterface AuthProviderInstance authprovider.AuthInterface TaskManager task.Manager Store *mongostore.MongoStore DbManager dbprovider.DbInterface EventTypes map[string]string )
var ( STORAGE_STATUS_UP = "up" STORAGE_STATUS_DOWN = "down" )
var ClusterMonitoringSchedules map[uuid.UUID]uuid.UUID
In memory ClusterId to ScheduleId map
var ClusterStatus = map[string]models.AlarmStatus{ "ok": models.CLUSTER_STATUS_OK, "warning": models.CLUSTER_STATUS_WARN, "error": models.CLUSTER_STATUS_ERROR, "unknown": models.CLUSTER_STATUS_UNKNOWN, }
var Event_severity = map[string]models.AlarmStatus{ "indeterminate": models.ALARM_STATUS_INDETERMINATE, "critical": models.ALARM_STATUS_CRITICAL, "major": models.ALARM_STATUS_MAJOR, "minor": models.ALARM_STATUS_MINOR, "warning": models.ALARM_STATUS_WARNING, "cleared": models.ALARM_STATUS_CLEARED, }
Functions ¶
func AddDefaultProfiles ¶
func AddDefaultProfiles() error
func AddDefaultUser ¶
func AddDefaultUser() error
func AddStorageNodeToDB ¶
func AddStorageNodeToDB(hostname string, node_state models.NodeState, node_status models.NodeStatus, alm_status models.AlarmStatus, ctxt string) error
func AverageAndUpdateDb ¶
func Check_status ¶
func ComputeClusterSummary ¶ added in v0.0.20
func ComputeSystemSummary ¶
func ComputeSystemSummary(p map[string]interface{})
func DeleteClusterSchedule ¶
func FailStillCreatingClusters ¶
func FailStillCreatingClusters(ctxt string)
func FetchStatFromGraphite ¶
func FetchStatFromGraphiteWithErrorIndicate ¶ added in v0.0.25
func GetAuthProvider ¶
func GetAuthProvider() authprovider.AuthInterface
func GetClusterByName ¶
func GetClusters ¶
func GetCoreNodeManager ¶
func GetCoreNodeManager() nodemanager.NodeManagerInterface
func GetDbProvider ¶
func GetDbProvider() dbprovider.DbInterface
func GetDetails ¶
func GetDetails(m map[string]interface{}) (models.MailNotifier, error)
func GetEventById ¶
func GetEventById(w http.ResponseWriter, r *http.Request)
func GetMonitoringManager ¶
func GetMonitoringManager() monitoring.MonitoringManagerInterface
func HandleHttpError ¶
func HandleHttpError(rw http.ResponseWriter, err error)
func HttpResponse ¶
func HttpResponse(w http.ResponseWriter, status_code int, msg string, args ...string)
func InitMonitoringSchedules ¶
func InitMonitoringSchedules()
func Initialize ¶
func LockCluster ¶
func ParseStatFromCollectd ¶
func PatchEvent ¶
func PatchEvent(w http.ResponseWriter, r *http.Request)
func RefreshDBSession ¶
func RefreshDBSession(params map[string]interface{})
func ScheduleCluster ¶
func SyncNodeUtilization ¶ added in v0.0.25
func SyncNodeUtilizations ¶
func SyncNodeUtilizations(params map[string]interface{})
func UpdateStorageNodeToDB ¶
func UpdateStorageNodeToDB(hostname string, node_state models.NodeState, node_status models.NodeStatus, alm_status models.AlarmStatus, ctxt string) error
Types ¶
type App ¶
type App struct {
// contains filtered or unexported fields
}
func (*App) AddMailNotifier ¶
func (a *App) AddMailNotifier(rw http.ResponseWriter, req *http.Request)
func (*App) DELETE_BlockDevice ¶
func (a *App) DELETE_BlockDevice(w http.ResponseWriter, r *http.Request)
func (*App) DELETE_Node ¶
func (a *App) DELETE_Node(w http.ResponseWriter, r *http.Request)
func (*App) DELETE_Nodes ¶
func (a *App) DELETE_Nodes(w http.ResponseWriter, r *http.Request)
func (*App) DELETE_StorageProfile ¶
func (a *App) DELETE_StorageProfile(w http.ResponseWriter, r *http.Request)
func (*App) DEL_Storage ¶
func (a *App) DEL_Storage(w http.ResponseWriter, r *http.Request)
func (*App) DiskHierarchy ¶ added in v0.0.22
func (a *App) DiskHierarchy(w http.ResponseWriter, r *http.Request)
func (*App) Expand_Cluster ¶
func (a *App) Expand_Cluster(w http.ResponseWriter, r *http.Request)
func (*App) FetchClusterDetailsFromProvider ¶
func (*App) FetchMonitoringDetailsFromProviders ¶
func (*App) Forget_Cluster ¶
func (a *App) Forget_Cluster(w http.ResponseWriter, r *http.Request)
func (*App) GET_AllStorages ¶
func (a *App) GET_AllStorages(w http.ResponseWriter, r *http.Request)
func (*App) GET_BlockDevice ¶
func (a *App) GET_BlockDevice(w http.ResponseWriter, r *http.Request)
func (*App) GET_BlockDevices ¶
func (a *App) GET_BlockDevices(w http.ResponseWriter, r *http.Request)
func (*App) GET_Cluster ¶
func (a *App) GET_Cluster(w http.ResponseWriter, r *http.Request)
func (*App) GET_ClusterBlockDevices ¶
func (a *App) GET_ClusterBlockDevices(w http.ResponseWriter, r *http.Request)
func (*App) GET_ClusterConfig ¶
func (a *App) GET_ClusterConfig(w http.ResponseWriter, r *http.Request)
func (*App) GET_ClusterNode ¶
func (a *App) GET_ClusterNode(w http.ResponseWriter, r *http.Request)
func (*App) GET_ClusterNodes ¶
func (a *App) GET_ClusterNodes(w http.ResponseWriter, r *http.Request)
func (*App) GET_ClusterNodesForImport ¶
func (a *App) GET_ClusterNodesForImport(w http.ResponseWriter, r *http.Request)
func (*App) GET_ClusterSlu ¶
func (a *App) GET_ClusterSlu(w http.ResponseWriter, r *http.Request)
func (*App) GET_ClusterSlus ¶
func (a *App) GET_ClusterSlus(w http.ResponseWriter, r *http.Request)
func (*App) GET_ClusterStorageBlockDevices ¶
func (a *App) GET_ClusterStorageBlockDevices(w http.ResponseWriter, r *http.Request)
func (*App) GET_Clusters ¶
func (a *App) GET_Clusters(w http.ResponseWriter, r *http.Request)
func (*App) GET_LookupNode ¶
func (a *App) GET_LookupNode(w http.ResponseWriter, r *http.Request)
func (*App) GET_MonitoringPlugins ¶
func (a *App) GET_MonitoringPlugins(w http.ResponseWriter, r *http.Request)
func (*App) GET_NodeSlus ¶
func (a *App) GET_NodeSlus(w http.ResponseWriter, r *http.Request)
func (*App) GET_NodeSummary ¶
func (a *App) GET_NodeSummary(w http.ResponseWriter, r *http.Request)
func (*App) GET_Slus ¶ added in v0.0.20
func (a *App) GET_Slus(w http.ResponseWriter, r *http.Request)
func (*App) GET_SshFingerprint ¶
func (a *App) GET_SshFingerprint(w http.ResponseWriter, r *http.Request)
func (*App) GET_Storage ¶
func (a *App) GET_Storage(w http.ResponseWriter, r *http.Request)
func (*App) GET_StorageProfile ¶
func (a *App) GET_StorageProfile(w http.ResponseWriter, r *http.Request)
func (*App) GET_StorageProfiles ¶
func (a *App) GET_StorageProfiles(w http.ResponseWriter, r *http.Request)
func (*App) GET_Storages ¶
func (a *App) GET_Storages(w http.ResponseWriter, r *http.Request)
func (*App) GET_UnmanagedNodes ¶
func (a *App) GET_UnmanagedNodes(w http.ResponseWriter, r *http.Request)
func (*App) GET_Utilization ¶
func (a *App) GET_Utilization(w http.ResponseWriter, r *http.Request)
func (*App) GetLockManager ¶
func (a *App) GetLockManager() lock.LockManager
func (*App) GetMailNotifier ¶
func (a *App) GetMailNotifier(rw http.ResponseWriter, req *http.Request)
func (*App) GetProviderFromClusterId ¶
func (*App) GetTaskManager ¶
func (*App) Get_ClusterSummary ¶
func (a *App) Get_ClusterSummary(w http.ResponseWriter, r *http.Request)
func (*App) Get_Summary ¶
func (a *App) Get_Summary(w http.ResponseWriter, r *http.Request)
func (*App) Get_SystemUtilization ¶
func (a *App) Get_SystemUtilization(w http.ResponseWriter, r *http.Request)
func (*App) ImportCluster ¶
func (a *App) ImportCluster(w http.ResponseWriter, r *http.Request)
func (*App) InitializeApplication ¶
func (a *App) InitializeApplication(sysConfig conf.SkyringCollection, configDir string) error
Initialize the application
func (*App) LoadEventTypes ¶
func (*App) LoadRoutes ¶
func (a *App) LoadRoutes()
func (*App) LoggingContext ¶
func (a *App) LoggingContext(w http.ResponseWriter, r *http.Request, next http.HandlerFunc)
Middleware to create the logging context
func (*App) LoginRequired ¶
func (a *App) LoginRequired(w http.ResponseWriter, r *http.Request, next http.HandlerFunc)
Middleware to check the request is authenticated
func (*App) Manage_Cluster ¶
func (a *App) Manage_Cluster(w http.ResponseWriter, r *http.Request)
func (*App) MonitorCluster ¶
func (*App) PATCH_ClusterSlu ¶
func (a *App) PATCH_ClusterSlu(w http.ResponseWriter, r *http.Request)
func (*App) PATCH_Clusters ¶
func (a *App) PATCH_Clusters(w http.ResponseWriter, r *http.Request)
func (*App) PATCH_Disk ¶
func (a *App) PATCH_Disk(w http.ResponseWriter, r *http.Request)
func (*App) PATCH_ResizeBlockDevice ¶
func (a *App) PATCH_ResizeBlockDevice(w http.ResponseWriter, r *http.Request)
func (*App) PATCH_Storage ¶
func (a *App) PATCH_Storage(w http.ResponseWriter, r *http.Request)
func (*App) PATCH_StorageProfile ¶
func (a *App) PATCH_StorageProfile(w http.ResponseWriter, r *http.Request)
func (*App) POST_AcceptUnamangedNode ¶
func (a *App) POST_AcceptUnamangedNode(w http.ResponseWriter, r *http.Request)
func (*App) POST_Actions ¶
func (a *App) POST_Actions(w http.ResponseWriter, r *http.Request)
func (*App) POST_AddMonitoringPlugin ¶
func (a *App) POST_AddMonitoringPlugin(w http.ResponseWriter, r *http.Request)
func (*App) POST_BlockDevices ¶
func (a *App) POST_BlockDevices(w http.ResponseWriter, r *http.Request)
func (*App) POST_Clusters ¶
func (a *App) POST_Clusters(w http.ResponseWriter, r *http.Request)
func (*App) POST_MonitoringPluginDisable ¶
func (a *App) POST_MonitoringPluginDisable(w http.ResponseWriter, r *http.Request)
func (*App) POST_MonitoringPluginEnable ¶
func (a *App) POST_MonitoringPluginEnable(w http.ResponseWriter, r *http.Request)
func (*App) POST_Nodes ¶
func (a *App) POST_Nodes(w http.ResponseWriter, r *http.Request)
func (*App) POST_ReSyncClusterSummary ¶ added in v0.0.25
func (a *App) POST_ReSyncClusterSummary(w http.ResponseWriter, r *http.Request)
func (*App) POST_ReSyncNodeSummary ¶ added in v0.0.25
func (a *App) POST_ReSyncNodeSummary(w http.ResponseWriter, r *http.Request)
func (*App) POST_ReSyncNodesSummary ¶ added in v0.0.25
func (a *App) POST_ReSyncNodesSummary(w http.ResponseWriter, r *http.Request)
func (*App) POST_ReSyncSystemSummary ¶ added in v0.0.25
func (a *App) POST_ReSyncSystemSummary(w http.ResponseWriter, r *http.Request)
func (*App) POST_StorageProfiles ¶
func (a *App) POST_StorageProfiles(w http.ResponseWriter, r *http.Request)
func (*App) POST_Storages ¶
func (a *App) POST_Storages(w http.ResponseWriter, r *http.Request)
func (*App) POST_froceUpdateMonitoringConfiguration ¶
func (a *App) POST_froceUpdateMonitoringConfiguration(w http.ResponseWriter, r *http.Request)
func (*App) PUT_Thresholds ¶
func (a *App) PUT_Thresholds(w http.ResponseWriter, r *http.Request)
func (*App) PatchMailNotifier ¶
func (a *App) PatchMailNotifier(rw http.ResponseWriter, req *http.Request)
func (*App) PostInitApplication ¶
func (a *App) PostInitApplication(sysConfig conf.SkyringCollection) error
func (*App) ProviderHandler ¶
func (a *App) ProviderHandler(w http.ResponseWriter, r *http.Request)
This is the handler where all the requests to providers will land in. Here the parameters are extracted and passed to the providers along with the requestbody if any using RPC. Result will be parsed to see if a specific status code needs to be set for http response. Arguments to Provider function -
- type RpcRequest struct { RpcRequestVars map[string]string RpcRequestData []byte }
Each provider should expect this structure as the first argument. RpcRequestVars is a map of parameters passed in request URL. RpcRequestData is the payload(body) of the http request.
2.Result - *[]byte Pointer to a byte array. In response, the byte array should contain
{ "status": {"statuscode": <Code>, "statusmessage": "<msg>"}, "data": {"requestid": "<id>", "result": []byte} }
where result is response payload from the provider, RequestId is populated if the request is asynchronously executed and statuscode and statusmessage to be set in the status field. The statuscode field should be valid http status code
func (*App) REMOVE_MonitoringPlugin ¶
func (a *App) REMOVE_MonitoringPlugin(w http.ResponseWriter, r *http.Request)
func (*App) RouteProviderBasedMonitoring ¶
func (*App) RouteProviderEvents ¶
func (*App) SyncClusterDetails ¶
func (*App) TestMailNotifier ¶
func (a *App) TestMailNotifier(rw http.ResponseWriter, req *http.Request)
func (*App) Unmanage_Cluster ¶
func (a *App) Unmanage_Cluster(w http.ResponseWriter, r *http.Request)
type ContextKey ¶
type ContextKey int
type Provider ¶
type Provider struct { Name string Client *rpc.Client ProvisionerName provisioner.Provisioner }