sample

package
v1.1.6 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2020 License: BSD-3-Clause Imports: 4 Imported by: 0

README

Log

This activity allows you to write log messages.

Installation

Flogo CLI
flogo install qingcloud-flow/plugin/activity/log

Configuration

Input:
Name Type Description
head map The message to log
body bytes body

Examples

The below example logs a message 'test message':

{
  "id": "log_message",
  "name": "Log Message",
  "activity": {
    "ref": "qingcloud-flow/plugin/activity/log",
    "input": {
      "head": "test message",
      "body": "false"
    }
  }
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

New optional factory method, should be used if one activity instance per configuration is desired

Types

type Activity

type Activity struct {
	// contains filtered or unexported fields
}

Activity is an sample Activity that can be used as a base to create a custom activity

func (*Activity) Eval

func (a *Activity) Eval(ctx activity.Context) (done bool, err error)

Eval implements api.Activity.Eval - Logs the Message

func (*Activity) Metadata

func (a *Activity) Metadata() *activity.Metadata

Metadata returns the activity's metadata

type Input

type Input struct {
	AnInput string `md:"anInput,required"`
}

func (*Input) FromMap

func (r *Input) FromMap(values map[string]interface{}) error

func (*Input) ToMap

func (r *Input) ToMap() map[string]interface{}

type Output

type Output struct {
	AnOutput string `md:"anOutput"`
}

func (*Output) FromMap

func (o *Output) FromMap(values map[string]interface{}) error

func (*Output) ToMap

func (o *Output) ToMap() map[string]interface{}

type Settings

type Settings struct {
	ASetting string `md:"aSetting,required"`
}

Jump to

Keyboard shortcuts

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