jobs

package
v0.7.8 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2022 License: MIT Imports: 20 Imported by: 0

Documentation

Overview

Package jobs [contains all the attack types db1000n can simulate]

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Args

type Args = map[string]interface{}

Args comment for linter

type BasicJobConfig

type BasicJobConfig struct {
	IntervalMs int `mapstructure:"interval_ms,omitempty"`
	Count      int `mapstructure:"count,omitempty"`
	// contains filtered or unexported fields
}

BasicJobConfig comment for linter

func (*BasicJobConfig) Next

func (c *BasicJobConfig) Next(ctx context.Context) bool

Next comment for linter

type Config

type Config struct {
	Name   string `mapstructure:"name"`
	Type   string `mapstructure:"type"`
	Count  int    `mapstructure:"count"`
	Filter string `mapstructure:"filter"`
	Args   Args   `mapstructure:"args"`
}

Config comment for linter

type GlobalConfig

type GlobalConfig struct {
	ProxyURL    string
	ScaleFactor int
}

GlobalConfig is a struct meant to pass commandline arguments to every job

type Job

type Job = func(ctx context.Context, globalConfig GlobalConfig, args Args, debug bool) (data interface{}, err error)

Job comment for linter

func Get

func Get(t string) Job

Get job by type name

Jump to

Keyboard shortcuts

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