Documentation
¶
Overview ¶
******************************************************************************
- Copyright 2018 Dell Inc. *
- 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. ******************************************************************************
******************************************************************************
- Copyright 2017 Dell Inc. *
- 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. ******************************************************************************
******************************************************************************
- Copyright 2018 Dell Inc.
- Copyright (c) 2019 Intel Corporation *
- 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. ******************************************************************************
******************************************************************************
- Copyright 2018 Dell Inc. *
- 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. ******************************************************************************
******************************************************************************
- Copyright 2018 Dell Inc. *
- 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. ******************************************************************************
******************************************************************************
- Copyright 2018 Dell Inc. *
- 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. ******************************************************************************
Copyright (c) 2018 Tencent ¶
Copyright (c) 2018 Dell Inc.
SPDX-License-Identifier: Apache-2.0
******************************************************************************
- Copyright 2018 Dell Inc. *
- 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 Destruct()
- func Init(useRegistry bool) bool
- func LoadRestRoutes() *mux.Router
- func LoadScheduler() error
- func Retry(useRegistry bool, useProfile string, timeout int, wait *sync.WaitGroup, ...)
- func StartTicker()
- func StopTicker()
- type ConfigurationStruct
- type IntervalContext
- type QueueClient
- func (qc *QueueClient) AddIntervalActionToQueue(intervalAction contract.IntervalAction) error
- func (qc *QueueClient) AddIntervalToQueue(interval contract.Interval) error
- func (qc *QueueClient) Connect() (string, error)
- func (qc *QueueClient) QueryIntervalActionByID(intervalActionId string) (contract.IntervalAction, error)
- func (qc *QueueClient) QueryIntervalActionByName(intervalActionName string) (contract.IntervalAction, error)
- func (qc *QueueClient) QueryIntervalByID(intervalId string) (contract.Interval, error)
- func (qc *QueueClient) QueryIntervalByName(intervalName string) (contract.Interval, error)
- func (qc *QueueClient) RemoveIntervalActionQueue(intervalActionId string) error
- func (qc *QueueClient) RemoveIntervalInQueue(intervalId string) error
- func (qc *QueueClient) UpdateIntervalActionQueue(intervalAction contract.IntervalAction) error
- func (qc *QueueClient) UpdateIntervalInQueue(interval contract.Interval) error
- type WritableInfo
Constants ¶
const ( /* -------------- Constants for Scheduler -------------------- */ ID = "id" NAME = "name" TARGETNAME = "targetname" INTERVALACTION = "intervalaction" INTERVAL = "interval" LABEL = "label" YAML = "yaml" COMMAND = "command" KEY = "key" VALUE = "value" UNLOCKED = "UNLOCKED" ENABLED = "ENABLED" SCHEDULER_TIMELAYOUT = "20060102T150405" /** Scheduler **/ TIMELAYOUT = "20060102T150405" /** Scheduler **/ /* ---------------- URL PARAM NAMES -----------------------*/ ContentTypeKey = "Content-Type" ContentTypeJsonValue = "application/json; charset=utf-8" ContentLengthKey = "Content-Length" )
Variables ¶
var LoggingClient logger.LoggingClient
Functions ¶
func LoadRestRoutes ¶ added in v1.0.0
func LoadScheduler ¶
func LoadScheduler() error
Utility function for adding configured locally intervals and scheduled events
func StartTicker ¶
func StartTicker()
func StopTicker ¶
func StopTicker()
Types ¶
type ConfigurationStruct ¶ added in v1.0.0
type ConfigurationStruct struct { Writable WritableInfo Clients map[string]config.ClientInfo Databases map[string]config.DatabaseInfo Logging config.LoggingInfo Registry config.RegistryInfo Service config.ServiceInfo Intervals map[string]config.IntervalInfo IntervalActions map[string]config.IntervalActionInfo }
Configuration V2 for the Support Scheduler Service
var Configuration *ConfigurationStruct
type IntervalContext ¶
type IntervalContext struct { Interval models.Interval IntervalActionsMap map[string]models.IntervalAction StartTime time.Time EndTime time.Time NextTime time.Time Frequency time.Duration CurrentIterations int64 MaxIterations int64 MarkedDeleted bool }
func (*IntervalContext) GetInfo ¶
func (sc *IntervalContext) GetInfo() string
func (*IntervalContext) IsComplete ¶
func (sc *IntervalContext) IsComplete() bool
func (*IntervalContext) Reset ¶
func (sc *IntervalContext) Reset(interval models.Interval)
func (*IntervalContext) UpdateIterations ¶
func (sc *IntervalContext) UpdateIterations()
func (*IntervalContext) UpdateNextTime ¶
func (sc *IntervalContext) UpdateNextTime()
type QueueClient ¶
type QueueClient struct { }
func (*QueueClient) AddIntervalActionToQueue ¶
func (qc *QueueClient) AddIntervalActionToQueue(intervalAction contract.IntervalAction) error
func (*QueueClient) AddIntervalToQueue ¶
func (qc *QueueClient) AddIntervalToQueue(interval contract.Interval) error
func (*QueueClient) Connect ¶
func (qc *QueueClient) Connect() (string, error)
func (*QueueClient) QueryIntervalActionByID ¶
func (qc *QueueClient) QueryIntervalActionByID(intervalActionId string) (contract.IntervalAction, error)
func (*QueueClient) QueryIntervalActionByName ¶
func (qc *QueueClient) QueryIntervalActionByName(intervalActionName string) (contract.IntervalAction, error)
func (*QueueClient) QueryIntervalByID ¶
func (qc *QueueClient) QueryIntervalByID(intervalId string) (contract.Interval, error)
func (*QueueClient) QueryIntervalByName ¶
func (qc *QueueClient) QueryIntervalByName(intervalName string) (contract.Interval, error)
func (*QueueClient) RemoveIntervalActionQueue ¶
func (qc *QueueClient) RemoveIntervalActionQueue(intervalActionId string) error
func (*QueueClient) RemoveIntervalInQueue ¶
func (qc *QueueClient) RemoveIntervalInQueue(intervalId string) error
func (*QueueClient) UpdateIntervalActionQueue ¶
func (qc *QueueClient) UpdateIntervalActionQueue(intervalAction contract.IntervalAction) error
func (*QueueClient) UpdateIntervalInQueue ¶
func (qc *QueueClient) UpdateIntervalInQueue(interval contract.Interval) error
type WritableInfo ¶ added in v1.0.0
Source Files
¶
Directories
¶
Path | Synopsis |
---|---|
****************************************************************************** * Copyright 2018 Dell Inc.
|
****************************************************************************** * Copyright 2018 Dell Inc. |
****************************************************************************** * Copyright 2018 Dell Inc.
|
****************************************************************************** * Copyright 2018 Dell Inc. |