wikimon

package
v0.0.0-...-40e2e50 Latest Latest
Warning

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

Go to latest
Published: Sep 23, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AvroSchema = `` /* 1606-byte string literal not displayed */

Functions

This section is empty.

Types

type AvroCodec

type AvroCodec struct {
	*goavro.Codec
}

AvroCodec defines avro codec structure

func WikiAvroCodec

func WikiAvroCodec() (*AvroCodec, error)

func (*AvroCodec) Unmarshal

func (c *AvroCodec) Unmarshal(msg []byte, logger *zap.Logger) (*Wikimon, error)

type GeoIP

type GeoIP struct {
	City      string  `json:"city,omitempty"`
	Country   string  `json:"country_name,omitempty"`
	Latitude  float64 `json:"latitude,omitempty"`
	Longitude float64 `json:"longitude,omitempty"`
	Region    string  `json:"region_name,omitempty"`
}

GeoIP defines geo_ip structure

type Wikimon

type Wikimon struct {
	Action      string   `json:"action,omitempty"`
	Change      int64    `json:"change_size,omitempty"`
	Geo         GeoIP    `json:"geo_ip,omitempty"`
	Hastags     []string `json:"hastags,omitempty"`
	Anon        bool     `json:"is_anon,omitempty"`
	Bot         bool     `json:"is_bot,omitempty"`
	Minor       bool     `json:"is_minor,omitempty"`
	New         bool     `json:"is_new,omitempty"`
	Unpatrolled bool     `json:"is_unpatrolled,omitempty"`
	Mentions    []string `json:"mentions,omitempty"`
	Ns          string   `json:"ns,omitempty"`
	PageTitle   string   `json:"page_title,omitempty"`
	ParentRevID string   `json:"parent_rev_id,omitempty"`
	RevID       string   `json:"rev_id,omitempty"`
	Summary     string   `json:"summary,omitempty"`
	URL         string   `json:"url,omitempty"`
	User        string   `json:"user,omitempty"`
}

Wikimon defines wikimon structure

Jump to

Keyboard shortcuts

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