Documentation ¶
Index ¶
- func BigFloatToInt64(input *big.Float) int64
- func CalculateHash(s, salt string) (string, error)
- func CalculateHashFromGlobalSalt(s string) (string, error)
- func CreateFlowpipeSalt(filename string, length int) (string, error)
- func EnsureDir(dir string) error
- func ExtendInputs(executionId, pipelineExecutionId, stepExecutionId, stepName string, ...) modconfig.Input
- func GetBaseUrl() string
- func GetGlobalSalt() (string, error)
- func GetHost() string
- func GetHttpFormUrl(executionId string, pipelineExecutionId string, stepExecutionId string) (string, error)
- func GetModSaltOrDefault() (string, error)
- func NewExecutionID() string
- func NewPipelineExecutionID() string
- func NewProcessID() string
- func NewSessionID() string
- func NewStepExecutionID() string
- func NewUniqueID() string
- func SafeDeref[T any](ptr *T) T
- func ValidateEmailInput(ctx context.Context, i modconfig.Input) error
- type CommandBusMock
- type HclExpressionMock
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BigFloatToInt64 ¶ added in v0.2.0
func CalculateHash ¶
func CalculateHashFromGlobalSalt ¶ added in v0.4.0
func CreateFlowpipeSalt ¶ added in v0.3.0
Assumes that the dir exists
The function creates the salt if it does not exist, or it returns the existing salt if it's already there
func ExtendInputs ¶ added in v0.4.3
func ExtendInputs(executionId, pipelineExecutionId, stepExecutionId, stepName string, input modconfig.Input) modconfig.Input
TODO: refactor/tidy extendInputs is only relevant for the "input step". This is the best location we can find right now.
We have tried to encapsulate this in the: 1) Step Definition's getInput() in pipe-fittings, but it needs the salt and we believe that it's not appropriate to use the salt in pipe-fittings. 2) In the primitive itself, but it's too late. We need this information in the Event for the remote CLI use case.
func GetBaseUrl ¶ added in v0.3.0
func GetBaseUrl() string
func GetGlobalSalt ¶ added in v0.3.0
func GetHttpFormUrl ¶ added in v0.3.0
func GetModSaltOrDefault ¶ added in v0.3.0
Global vs Mod salt behaviour:
- We should only create the salt *automatically* in the "global" location: `~/.flowpipe/internal/salt ` - A user may create a "mod salt" file in the mod manually (`./.flowpipe/internal/salt`)
- If there is a mod salt, it is used for triggers, otherwise use the global salt. *Integrations* always use the global salt - this implies that:
- any new installs will only have global salt (unless a user manually creates one)
- existing installs work and continue to use the same salt as they currently do (unless the user manually deletes the salt)
- the user may decide to use their own custom per-mod salt, but this is an advanced operation
func NewExecutionID ¶
func NewExecutionID() string
func NewPipelineExecutionID ¶
func NewPipelineExecutionID() string
func NewProcessID ¶
func NewProcessID() string
func NewSessionID ¶
func NewSessionID() string
func NewStepExecutionID ¶
func NewStepExecutionID() string
func NewUniqueID ¶
func NewUniqueID() string
Types ¶
type CommandBusMock ¶ added in v0.2.0
type CommandBusMock struct { SendFunc func(ctx context.Context, command interface{}) error SendWithLockFunc func(ctx context.Context, command interface{}, lock *sync.Mutex) error }
func (*CommandBusMock) Send ¶ added in v0.2.0
func (c *CommandBusMock) Send(ctx context.Context, command interface{}) error
func (*CommandBusMock) SendWithLock ¶ added in v0.2.0
type HclExpressionMock ¶ added in v0.2.0
type HclExpressionMock struct {
ValueFunc func(evalCtx *hcl.EvalContext) (cty.Value, hcl.Diagnostics)
}
func (*HclExpressionMock) Range ¶ added in v0.2.0
func (*HclExpressionMock) Range() hcl.Range
func (*HclExpressionMock) StartRange ¶ added in v0.2.0
func (*HclExpressionMock) StartRange() hcl.Range
func (*HclExpressionMock) Value ¶ added in v0.2.0
func (h *HclExpressionMock) Value(evalCtx *hcl.EvalContext) (cty.Value, hcl.Diagnostics)
func (*HclExpressionMock) Variables ¶ added in v0.2.0
func (*HclExpressionMock) Variables() []hcl.Traversal