Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Script ¶
type Script struct { // URI which denotes where the data lives, where came from (streamed) or // where can be accessed in the future. The latter value is preferred since // it theoretically enables future access. Uri string `json:"uri,omitempty" bson:"uri,omitempty"` // The version of the script. This could be a timestamp, Git commit SHA, // tag version, etc. This useful when an issue is found with the script // and it can be assessed whether a transaction is affected. Version string `json:"version,omitempty" bson:"version,omitempty"` // The primary programming language the script is written in. If not // defined, this will be attempted to be inferred from filename specified // in uri. Language string `json:"language,omitempty" bson:"language,omitempty"` // The actual code as text or statement used during this transaction. // This is most useful for scripts that perform in-place operations that // never expose the data itself. For example, a SQL statement that selects // data from one table and inserts it into a new table. Code string `json:"code,omitempty" bson:"code,omitempty"` // Extra data from decoded JSON. This enables clients to store additional // metadata about the store. Extra map[string]interface{} `json:"-" bson",inline,omitempty"` }
func (*Script) MarshalJSON ¶
Satisfies the `json.Marshaler` interface
func (*Script) UnmarshalJSON ¶
Satisfies the `json.Unmarshaler` interface
type Transaction ¶
type Transaction struct { Id bson.ObjectId `json:"_id,omitempty" bson:"_id,omitempty"` // Timestamp of when the transaction occurred Timestamp time.Time `json:"timestamp,omitempty" bson:"timestamp,omitempty"` // The action that was performed on the target. This may not be // applicable or available depending on what operation the script is // performing. The value is generally target-specific; for example, // insert and delete for row-based operations, append for file-based // writing, pop for a Redis list, etc. Action string `json:"action,omitempty" bson:"action,omitempty"` // An object representing the script used that performed the ETL and // produced this transaction. Script Script `json:"script,omitempty" bson:"script,omitempty"` // An object or array of objects representing the sources of data being // used in the target output. Source stores.Store `json:"source,omitempty" bson:"source,omitempty"` // An object or array of objects representing the targets Target stores.Store `json:"target,omitempty" bson:"target,omitempty"` // Extra data from decoded JSON. This enables clients to store additional // metadata about the store. Extra map[string]interface{} `json:"-" bson:",inline,omitempty"` }
func (*Transaction) MarshalJSON ¶
func (t *Transaction) MarshalJSON() ([]byte, error)
Satisfies the `json.Marshaler` interface
func (*Transaction) UnmarshalJSON ¶
func (t *Transaction) UnmarshalJSON(b []byte) error
Satisfies the `json.Unmarshaler` interface
Click to show internal directories.
Click to hide internal directories.