manager

package
v0.0.0-...-e1c1db1 Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2022 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Overview

© 2022 OSINT Fingerprint Project Contributors

© 2022 OSINT Fingerprint Project Contributors

© 2022 OSINT Fingerprint Project Contributors

Index

Constants

View Source
const MEMCACHED_EXPIRATION = (86400 * 1)

7 days cache expiration

View Source
const POSTGRES_EXPIRATION = time.Duration(1) * time.Hour * 24 * 7

7 days cache expiration

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

type Cache struct {
	gorm.Model
	CacheTime time.Time
	Category  string `gorm:"index:idx_cache_category_source_key"`
	Collector string `gorm:"index:idx_cache_category_source_key"`
	Key       string `gorm:"index:idx_cache_category_source_key"`
	Json      datatypes.JSON
}

type HybridCache

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

func NewHybridCache

func NewHybridCache() *HybridCache

func (*HybridCache) Get

func (x *HybridCache) Get(category string, collector string, key string) (json.RawMessage, error)

func (*HybridCache) Set

func (x *HybridCache) Set(category string, collector string, key string, json json.RawMessage) error

type Memcached

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

func NewMemcached

func NewMemcached() *Memcached

func (*Memcached) Clear

func (x *Memcached) Clear(collector string)

func (*Memcached) Get

func (x *Memcached) Get(category string, collector string, key string) (json.RawMessage, error)

func (*Memcached) GetKey

func (x *Memcached) GetKey(category string, collector string, key string) string

func (*Memcached) Name

func (x *Memcached) Name() string

func (*Memcached) Set

func (x *Memcached) Set(category string, collector string, key string, json json.RawMessage) error

type PostgresCache

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

func NewPostgresCache

func NewPostgresCache() *PostgresCache

func (*PostgresCache) Get

func (x *PostgresCache) Get(category string, collector string, key string) (json.RawMessage, error)

func (*PostgresCache) Set

func (x *PostgresCache) Set(category string, collector string, key string, json json.RawMessage) error

type SignalCollectors

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

func NewSignalCollectors

func NewSignalCollectors() *SignalCollectors

func (*SignalCollectors) GetCollectorJSON

func (x *SignalCollectors) GetCollectorJSON(
	category string, collector string, name string,
	key string) (*json.RawMessage, error)

func (*SignalCollectors) GetSignalCollector

func (x *SignalCollectors) GetSignalCollector(name string) osint.SignalCollector

func (*SignalCollectors) GetSignalValue

func (x *SignalCollectors) GetSignalValue(
	category string, collector string, name string,
	key string) (*gjson.Result, error)

func (*SignalCollectors) Init

func (*SignalCollectors) NewCollector

func (x *SignalCollectors) NewCollector(name string) osint.SignalCollector

TODO: add new signal collectors here

func (*SignalCollectors) RefreshAll

func (x *SignalCollectors) RefreshAll(w io.Writer)

func (*SignalCollectors) RefreshOnSchedule

func (x *SignalCollectors) RefreshOnSchedule()

Jump to

Keyboard shortcuts

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