sumologic

package
v1.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 23, 2019 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var SumoMutexKV = mutexkv.NewMutexKV()

Functions

func Provider

func Provider() terraform.ResourceProvider

Types

type BeginDeletionJobResponse added in v1.1.0

type BeginDeletionJobResponse struct {
	ID string `json:"id"`
}

type Children added in v1.1.0

type Children struct {
	Name        string   `json:"name"`
	Description string   `json:"description"`
	ParentId    string   `json:"parentId"`
	ItemType    string   `json:"itemType"`
	Permissions []string `json:"permissions"`
	CreatedAt   string   `json:"createdAt"`
	CreatedBy   string   `json:"createdBy"`
	ModifiedAt  string   `json:"modifiedAt"`
	ModifiedBy  string   `json:"modifiedBy"`
	ID          string   `json:"id"`
}

type Client

type Client struct {
	AccessID    string
	AccessKey   string
	Environment string
	BaseURL     *url.URL
	// contains filtered or unexported fields
}

func NewClient

func NewClient(accessID, accessKey, environment, base_url string) (*Client, error)

func (*Client) AssignCollectorToIngestBudget added in v0.4.0

func (s *Client) AssignCollectorToIngestBudget(ingestBudgetId string, collectorId int) error

func (*Client) CollectorAssignedToIngestBudget added in v0.4.0

func (s *Client) CollectorAssignedToIngestBudget(ingestBudgetId string, collectorId int) (bool, error)

func (*Client) CreateCloudsyslogSource

func (s *Client) CreateCloudsyslogSource(cloudSyslogSource CloudSyslogSource, collectorID int) (int, error)

func (*Client) CreateCollector

func (s *Client) CreateCollector(collector Collector) (int, error)

func (*Client) CreateFolder added in v1.1.0

func (s *Client) CreateFolder(folder FolderCreate) (Folder, error)

func (*Client) CreateHTTPSource

func (s *Client) CreateHTTPSource(httpSource HTTPSource, collectorID int) (int, error)

func (*Client) CreateIngestBudget added in v0.4.0

func (s *Client) CreateIngestBudget(budget IngestBudget) (string, error)

func (*Client) CreatePartition added in v1.3.0

func (s *Client) CreatePartition(spartition Partition) (*Partition, error)

func (*Client) CreatePollingSource

func (s *Client) CreatePollingSource(source PollingSource, collectorID int) (int, error)

func (*Client) CreateRole added in v0.3.0

func (s *Client) CreateRole(role Role) (string, error)

func (*Client) CreateScheduledView added in v1.1.0

func (s *Client) CreateScheduledView(sview ScheduledView) (*ScheduledView, error)

func (*Client) CreateUser added in v0.4.0

func (s *Client) CreateUser(user User) (string, error)

func (*Client) Delete

func (s *Client) Delete(urlPath string) ([]byte, error)

func (*Client) DeleteCollector

func (s *Client) DeleteCollector(id int) error

func (*Client) DeleteFolderStatus added in v1.1.0

func (s *Client) DeleteFolderStatus(id string, job_id string) (string, error)

func (*Client) DeleteIngestBudget added in v0.4.0

func (s *Client) DeleteIngestBudget(id string) error

func (*Client) DeletePartition added in v1.3.0

func (s *Client) DeletePartition(id string) error

func (*Client) DeleteRole added in v0.3.0

func (s *Client) DeleteRole(id string) error

func (*Client) DeleteScheduledView added in v1.1.0

func (s *Client) DeleteScheduledView(id string) error

func (*Client) DeleteUser added in v0.4.0

func (s *Client) DeleteUser(id string) error

func (*Client) DestroySource

func (s *Client) DestroySource(sourceID int, collectorID int) error

func (*Client) FindIngestBudget added in v0.4.0

func (s *Client) FindIngestBudget(name string) (*IngestBudget, error)

func (*Client) Get

func (s *Client) Get(urlPath string) ([]byte, string, error)

func (*Client) GetCloudSyslogSource

func (s *Client) GetCloudSyslogSource(collectorID, sourceID int) (*CloudSyslogSource, error)

func (*Client) GetCollector

func (s *Client) GetCollector(id int) (*Collector, error)

func (*Client) GetCollectorName

func (s *Client) GetCollectorName(name string) (*Collector, error)

func (*Client) GetFolder added in v1.1.0

func (s *Client) GetFolder(id string) (Folder, error)

func (*Client) GetHTTPSource

func (s *Client) GetHTTPSource(collectorID, sourceID int) (*HTTPSource, error)

func (*Client) GetIngestBudget added in v0.4.0

func (s *Client) GetIngestBudget(id string) (*IngestBudget, error)

func (*Client) GetPartition added in v1.3.0

func (s *Client) GetPartition(id string) (*Partition, error)

func (*Client) GetPollingSource

func (s *Client) GetPollingSource(collectorID, sourceID int) (*PollingSource, error)

func (*Client) GetRole added in v0.3.0

func (s *Client) GetRole(id string) (*Role, error)

func (*Client) GetRoleName added in v0.3.0

func (s *Client) GetRoleName(name string) (*Role, error)

func (*Client) GetScheduledView added in v1.1.0

func (s *Client) GetScheduledView(id string) (*ScheduledView, error)

func (*Client) GetSourceName

func (s *Client) GetSourceName(collectorID int, sourceName string) (*Source, error)

func (*Client) GetUser added in v0.4.0

func (s *Client) GetUser(id string) (*User, error)

func (*Client) GetWithCookies

func (s *Client) GetWithCookies(urlPath string, cookies []*http.Cookie) ([]byte, string, error)

func (*Client) Post

func (s *Client) Post(urlPath string, payload interface{}) ([]byte, error)

func (*Client) PostWithCookies

func (s *Client) PostWithCookies(urlPath string, payload interface{}) ([]byte, []*http.Cookie, error)

func (*Client) Put

func (s *Client) Put(urlPath string, payload interface{}) ([]byte, error)

func (*Client) StartDeleteFolder added in v1.1.0

func (s *Client) StartDeleteFolder(id string) (string, error)

func (*Client) UnAssignCollectorToIngestBudget added in v0.4.0

func (s *Client) UnAssignCollectorToIngestBudget(ingestBudgetId string, collectorId int) error

func (*Client) UpdateCloudSyslogSource

func (s *Client) UpdateCloudSyslogSource(source CloudSyslogSource, collectorID int) error

func (*Client) UpdateCollector

func (s *Client) UpdateCollector(collector Collector) error

func (*Client) UpdateFolder added in v1.1.0

func (s *Client) UpdateFolder(id string, folder FolderUpdate) (Folder, error)

func (*Client) UpdateHTTPSource

func (s *Client) UpdateHTTPSource(source HTTPSource, collectorID int) error

func (*Client) UpdateIngestBudget added in v0.4.0

func (s *Client) UpdateIngestBudget(budget IngestBudget) error

func (*Client) UpdatePartition added in v1.3.0

func (s *Client) UpdatePartition(spartition Partition) error

func (*Client) UpdatePollingSource

func (s *Client) UpdatePollingSource(source PollingSource, collectorID int) error

func (*Client) UpdateRole added in v0.3.0

func (s *Client) UpdateRole(role Role) error

func (*Client) UpdateScheduledView added in v1.1.0

func (s *Client) UpdateScheduledView(sview ScheduledView) error

func (*Client) UpdateUser added in v0.4.0

func (s *Client) UpdateUser(user User) error

type CloudSyslogSource

type CloudSyslogSource struct {
	Source
	Token string `json:"token,omitempty"`
}

type Collector

type Collector struct {
	ID               int                    `json:"id,omitempty"`
	CollectorType    string                 `json:"collectorType,omitempty"`
	Name             string                 `json:"name"`
	Description      string                 `json:"description,omitempty"`
	Category         string                 `json:"category,omitempty"`
	TimeZone         string                 `json:"timeZone,omitempty"`
	Fields           map[string]interface{} `json:"fields,omitempty"`
	Links            []CollectorLink        `json:"links,omitempty"`
	CollectorVersion string                 `json:"collectorVersion,omitempty"`
	LastSeenAlive    int                    `json:"lastSeenAlive,omitempty"`
	Alive            bool                   `json:"alive,omitempty"`
}
type CollectorLink struct {
	Rel  string `json:"rel,omitempty"`
	Href string `json:"href,omitempty"`
}

type CollectorList

type CollectorList struct {
	Collectors []Collector `json:"collectors"`
}

type CollectorRequest

type CollectorRequest struct {
	Collector Collector `json:"collector"`
}

type CollectorResponse

type CollectorResponse struct {
	Collector Collector `json:"collector"`
}

type DefaultDateFormat

type DefaultDateFormat struct {
	Format  string `json:"format"`
	Locator string `json:"locator"`
}

type DeletionJobStatus added in v1.1.0

type DeletionJobStatus struct {
	Status        string           `json:"status"`
	StatusMessage string           `json:"statusMessage"`
	Error         ErrorDescription `json:"error"`
}

type ErrorDescription added in v1.1.0

type ErrorDescription struct {
	Code    string `json:"code"`
	Message string `json:"message"`
	Detail  string `json:"detail"`
}

type Filter

type Filter struct {
	Name       string `json:"name"`
	FilterType string `json:"filterType"`
	Regexp     string `json:"regexp"`
	Mask       string `json:"mask"`
}

type Folder added in v1.1.0

type Folder struct {
	Name        string     `json:"name"`
	Description string     `json:"description"`
	ParentId    string     `json:"parentId"`
	ItemType    string     `json:"itemType"`
	Permissions []string   `json:"permissions"`
	CreatedAt   string     `json:"createdAt"`
	CreatedBy   string     `json:"createdBy"`
	ModifiedAt  string     `json:"modifiedAt"`
	ModifiedBy  string     `json:"modifiedBy"`
	ID          string     `json:"id"`
	Children    []Children `json:"children"`
}

type FolderCreate added in v1.1.0

type FolderCreate struct {
	Name        string `json:"name"`
	Description string `json:"description"`
	ParentId    string `json:"parentId"`
}

type FolderUpdate added in v1.1.0

type FolderUpdate struct {
	Name        string `json:"name"`
	Description string `json:"description"`
}

type HTTPSource

type HTTPSource struct {
	Source
	MessagePerRequest bool   `json:"messagePerRequest"`
	URL               string `json:"url,omitempty"`
}

type HttpClient added in v0.2.1

type HttpClient interface {
	Do(req *http.Request) (*http.Response, error)
}

type IngestBudget added in v0.4.0

type IngestBudget struct {
	ID          string `json:"id,omitempty"`
	Name        string `json:"name"`
	FieldValue  string `json:"fieldValue"`
	Capacity    int    `json:"capacityBytes"`
	Timezone    string `json:"timezone"`
	ResetTime   string `json:"resetTime"`
	Description string `json:"description,omitempty"`
	Action      string `json:"action"`
}

type Partition added in v1.3.0

type Partition struct {
	ID                string `json:"id,omitempty"`
	Name              string `json:"name"`
	RoutingExpression string `json:"routingExpression"`
	AnalyticsTier     string `json:"analyticsTier"`
	RetentionPeriod   int    `json:"retentionPeriod"`
	IsCompliant       bool   `json:"isCompliant"`
	DataForwardingId  string `json:"dataForwardingId"`
}

type PollingAuthentication

type PollingAuthentication struct {
	Type    string `json:"type"`
	AwsID   string `json:"awsId"`
	AwsKey  string `json:"awsKey"`
	RoleARN string `json:"roleARN"`
}

type PollingPath

type PollingPath struct {
	Type           string `json:"type"`
	BucketName     string `json:"bucketName"`
	PathExpression string `json:"pathExpression"`
}

type PollingResource

type PollingResource struct {
	ServiceType    string                `json:"serviceType"`
	Authentication PollingAuthentication `json:"authentication"`
	Path           PollingPath           `json:"path"`
}

type PollingSource

type PollingSource struct {
	Source
	ContentType   string               `json:"contentType"`
	ScanInterval  int                  `json:"scanInterval"`
	Paused        bool                 `json:"paused"`
	URL           string               `json:"url"`
	ThirdPartyRef PollingThirdPartyRef `json:"thirdPartyRef,omitempty"`
}

type PollingThirdPartyRef

type PollingThirdPartyRef struct {
	Resources []PollingResource `json:"resources"`
}

type Role added in v0.3.0

type Role struct {
	ID              string   `json:"id,omitempty"`
	Name            string   `json:"name"`
	Description     string   `json:"description"`
	FilterPredicate string   `json:"filterPredicate"`
	Users           []string ` json:"users"`
	Capabilities    []string ` json:"capabilities"`
}

type RoleList added in v0.3.0

type RoleList struct {
	Roles []Role `json:"data"`
}

type ScheduledView added in v1.1.0

type ScheduledView struct {
	ID               string    `json:"id,omitempty"`
	Query            string    `json:"query"`
	IndexName        string    `json:"indexName"`
	StartTime        time.Time `json:"startTime"`
	RetentionPeriod  int       `json:"retentionPeriod"`
	DataForwardingId string    `json:"dataForwardingId"`
}

type Source

type Source struct {
	ID                         int                    `json:"id,omitempty"`
	Type                       string                 `json:"sourceType"`
	Name                       string                 `json:"name"`
	Description                string                 `json:"description,omitempty"`
	Category                   string                 `json:"category,omitempty"`
	HostName                   string                 `json:"hostName,omitempty"`
	TimeZone                   string                 `json:"timeZone,omitempty"`
	AutomaticDateParsing       bool                   `json:"automaticDateParsing"`
	MultilineProcessingEnabled bool                   `json:"multilineProcessingEnabled"`
	UseAutolineMatching        bool                   `json:"useAutolineMatching"`
	ManualPrefixRegexp         string                 `json:"manualPrefixRegexp,omitempty"`
	ForceTimeZone              bool                   `json:"forceTimeZone"`
	DefaultDateFormats         []DefaultDateFormat    `json:"defaultDateFormats,omitempty"`
	Filters                    []Filter               `json:"filters,omitempty"`
	CutoffTimestamp            int                    `json:"cutoffTimestamp,omitempty"`
	CutoffRelativeTime         string                 `json:"cutoffRelativeTime,omitempty"`
	Fields                     map[string]interface{} `json:"fields,omitempty"`
}

type SourceList

type SourceList struct {
	Sources []Source `json:"sources"`
}

type User added in v0.4.0

type User struct {
	ID        string   `json:"id,omitempty"`
	FirstName string   `json:"firstName"`
	LastName  string   `json:"lastName"`
	Email     string   `json:"email,omitempty"`
	Active    bool     `json:"isActive"`
	RoleIds   []string `json:"roleIds"`
}

type UserList added in v0.4.0

type UserList struct {
	Users []User `json:"data"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL