Documentation ¶
Overview ¶
* Copyright 2018 Johannes Donath <johannesd@torchmind.com> * and other copyright owners as documented in the project's IP log. * * 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 ¶
const DefaultAddress = "0.0.0.0"
defines the default address to listen on when none is given
const DefaultPort = 36623
defines the default port to listen on when none is given
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { PluginDir *string `hcl:"plugin-dir"` BindAddress *string `hcl:"bind-address,attr"` UiEnabled *bool `hcl:"ui,attr"` LegacyApiEnabled *bool `hcl:"legacy-api,attr"` Storage *StorageConfig `hcl:"storage,block"` Ttl *TtlConfig `hcl:"ttl,block"` }
Represents a server configuration (typically parsed from one or more HCL files)
func DefaultConfig ¶
func DefaultConfig() *Config
func DevelopmentConfig ¶
func DevelopmentConfig() *Config
func LoadConfigDirectory ¶
Loads an entire directory of configuration files
func LoadConfigFile ¶
Loads a single configuration file
type StorageConfig ¶
Represents a storage backend configuration The "type" parameter will simply equal the executable name within the plugin directory while all parameters are passed on upon startup
func (*StorageConfig) Merge ¶
func (c *StorageConfig) Merge(other *StorageConfig) *StorageConfig
type TtlConfig ¶
type TtlConfig struct { Name time.Duration RawName string `hcl:"name,attr"` NameHistory time.Duration RawNameHistory string `hcl:"name-history,attr"` Profile time.Duration RawProfile string `hcl:"profile,attr"` Blacklist time.Duration RawBlacklist string `hcl:"blacklist,attr"` }
Represents the TTL (Time To Live) configuration (e.g. caching durations for various value types)
Directories ¶
Path | Synopsis |
---|---|
* Copyright 2018 Johannes Donath <johannesd@torchmind.com> * and other copyright owners as documented in the project's IP log.
|
* Copyright 2018 Johannes Donath <johannesd@torchmind.com> * and other copyright owners as documented in the project's IP log. |
* Copyright 2018 Johannes Donath <johannesd@torchmind.com> * and other copyright owners as documented in the project's IP log.
|
* Copyright 2018 Johannes Donath <johannesd@torchmind.com> * and other copyright owners as documented in the project's IP log. |
* Copyright 2018 Johannes Donath <johannesd@torchmind.com> * and other copyright owners as documented in the project's IP log.
|
* Copyright 2018 Johannes Donath <johannesd@torchmind.com> * and other copyright owners as documented in the project's IP log. |