data_source

package
v0.10.2 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2022 License: Apache-2.0 Imports: 4 Imported by: 9

Documentation

Overview

Package data_source provides the tooling to build the Raito data source import file. Simply use the NewDataSourceFileCreator function by passing in the config coming from the CLI to create the necessary file(s). The returned DataSourceFileCreator can then be used (using the AddDataObjects function) to write DataObjects to the file. Make sure to call the Close function on the creator at the end (tip: use defer).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DataObject

type DataObject struct {
	ExternalId       string                 `json:"externalId"`
	Name             string                 `json:"name"`
	FullName         string                 `json:"fullName"`
	Type             string                 `json:"type"`
	Description      string                 `json:"description"`
	ParentExternalId string                 `json:"parentExternalId"`
	Tags             map[string]interface{} `json:"tags"`
}

DataObject represents a data object in the format that is suitable to be imported into a Raito data source.

type DataObjectReference added in v0.6.0

type DataObjectReference struct {
	FullName string `json:"fullName"`
	Type     string `json:"type"`
}

DataObjectReference represents the reference to a DataObject suitable for e.g. defining the What in Access Provider import

type DataSourceFileCreator

type DataSourceFileCreator interface {
	AddDataObjects(dataObjects []DataObject) error
	Close()
	GetDataObjectCount() int
}

DataSourceFileCreator describes the interface for easily creating the data object import files to be imported by the Raito CLI.

func NewDataSourceFileCreator

func NewDataSourceFileCreator(config *data_source.DataSourceSyncConfig) (DataSourceFileCreator, error)

NewDataSourceFileCreator creates a new DataSourceFileCreator based on the configuration coming from the Raito CLI.

Jump to

Keyboard shortcuts

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