adapters

package
v0.0.0-...-0a9f55e Latest Latest
Warning

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

Go to latest
Published: May 28, 2017 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultHTTPAdapterConfig = &HTTPAdapterConfig{
	MaxConns:            50,
	MaxConnsPerHost:     10,
	MaxIdleConnsPerHost: 3,
	IdleConnTimeout:     60 * time.Second,
}

Functions

This section is empty.

Types

type Adapter

type Adapter interface {
	Name() string
	FamilyName() string
	GetUsersyncInfo() *pbs.UsersyncInfo
	Call(ctx context.Context, req *pbs.PBSRequest, bidder *pbs.PBSBidder) (pbs.PBSBidSlice, error)
}

type AppNexusAdapter

type AppNexusAdapter struct {
	URI string
	// contains filtered or unexported fields
}

func NewAppNexusAdapter

func NewAppNexusAdapter(config *HTTPAdapterConfig, externalURL string) *AppNexusAdapter

func (*AppNexusAdapter) Call

func (a *AppNexusAdapter) Call(ctx context.Context, req *pbs.PBSRequest, bidder *pbs.PBSBidder) (pbs.PBSBidSlice, error)

func (*AppNexusAdapter) FamilyName

func (a *AppNexusAdapter) FamilyName() string

used for cookies and such

func (*AppNexusAdapter) GetUsersyncInfo

func (a *AppNexusAdapter) GetUsersyncInfo() *pbs.UsersyncInfo

func (*AppNexusAdapter) Name

func (a *AppNexusAdapter) Name() string

Name - export adapter name

type FacebookAdapter

type FacebookAdapter struct {
	URI string
	// contains filtered or unexported fields
}

func NewFacebookAdapter

func NewFacebookAdapter(config *HTTPAdapterConfig, partnerID string, usersyncURL string) *FacebookAdapter

func (*FacebookAdapter) Call

func (a *FacebookAdapter) Call(ctx context.Context, req *pbs.PBSRequest, bidder *pbs.PBSBidder) (pbs.PBSBidSlice, error)

func (*FacebookAdapter) CallOne

func (a *FacebookAdapter) CallOne(ctx context.Context, req *pbs.PBSRequest, reqJSON bytes.Buffer) (result fbResult, err error)

func (*FacebookAdapter) FamilyName

func (a *FacebookAdapter) FamilyName() string

used for cookies and such

func (*FacebookAdapter) GetUsersyncInfo

func (a *FacebookAdapter) GetUsersyncInfo() *pbs.UsersyncInfo

func (*FacebookAdapter) Name

func (a *FacebookAdapter) Name() string

Name - export adapter name

func (*FacebookAdapter) SplitAdUnits

func (a *FacebookAdapter) SplitAdUnits() bool

Facebook likes to parallelize to minimize latency

type HTTPAdapter

type HTTPAdapter struct {
	Transport *http.Transport
	Client    *http.Client
}

func NewHTTPAdapter

func NewHTTPAdapter(c *HTTPAdapterConfig) *HTTPAdapter

type HTTPAdapterConfig

type HTTPAdapterConfig struct {
	IdleConnTimeout     time.Duration
	MaxConns            int
	MaxIdleConnsPerHost int
	MaxConnsPerHost     int
}

type IndexAdapter

type IndexAdapter struct {
	URI string
	// contains filtered or unexported fields
}

func NewIndexAdapter

func NewIndexAdapter(config *HTTPAdapterConfig, externalURL string) *IndexAdapter

func (*IndexAdapter) Call

func (a *IndexAdapter) Call(ctx context.Context, req *pbs.PBSRequest, bidder *pbs.PBSBidder) (pbs.PBSBidSlice, error)

func (*IndexAdapter) FamilyName

func (a *IndexAdapter) FamilyName() string

used for cookies and such

func (*IndexAdapter) GetUsersyncInfo

func (a *IndexAdapter) GetUsersyncInfo() *pbs.UsersyncInfo

func (*IndexAdapter) Name

func (a *IndexAdapter) Name() string

Name - export adapter name

type PubmaticAdapter

type PubmaticAdapter struct {
	URI string
	// contains filtered or unexported fields
}

func NewPubmaticAdapter

func NewPubmaticAdapter(config *HTTPAdapterConfig, uri string, externalURL string) *PubmaticAdapter

func (*PubmaticAdapter) Call

func (a *PubmaticAdapter) Call(ctx context.Context, req *pbs.PBSRequest, bidder *pbs.PBSBidder) (pbs.PBSBidSlice, error)

func (*PubmaticAdapter) FamilyName

func (a *PubmaticAdapter) FamilyName() string

used for cookies and such

func (*PubmaticAdapter) GetUsersyncInfo

func (a *PubmaticAdapter) GetUsersyncInfo() *pbs.UsersyncInfo

func (*PubmaticAdapter) Name

func (a *PubmaticAdapter) Name() string

Name - export adapter name

type PulsePointAdapter

type PulsePointAdapter struct {
	URI string
	// contains filtered or unexported fields
}

func NewPulsePointAdapter

func NewPulsePointAdapter(config *HTTPAdapterConfig, uri string, externalURL string) *PulsePointAdapter

func (*PulsePointAdapter) Call

func (*PulsePointAdapter) FamilyName

func (a *PulsePointAdapter) FamilyName() string

used for cookies and such

func (*PulsePointAdapter) GetUsersyncInfo

func (a *PulsePointAdapter) GetUsersyncInfo() *pbs.UsersyncInfo

func (*PulsePointAdapter) Name

func (a *PulsePointAdapter) Name() string

adapter name

type PulsepointParams

type PulsepointParams struct {
	PublisherId int    `json:"cp"`
	TagId       int    `json:"ct"`
	AdSize      string `json:"cf"`
}

parameters for pulsepoint adapter.

type RubiconAdapter

type RubiconAdapter struct {
	URI string

	XAPIUsername string
	XAPIPassword string
	// contains filtered or unexported fields
}

func NewRubiconAdapter

func NewRubiconAdapter(config *HTTPAdapterConfig, uri string, xuser string, xpass string, usersyncURL string) *RubiconAdapter

func (*RubiconAdapter) Call

func (a *RubiconAdapter) Call(ctx context.Context, req *pbs.PBSRequest, bidder *pbs.PBSBidder) (pbs.PBSBidSlice, error)

func (*RubiconAdapter) FamilyName

func (a *RubiconAdapter) FamilyName() string

used for cookies and such

func (*RubiconAdapter) GetUsersyncInfo

func (a *RubiconAdapter) GetUsersyncInfo() *pbs.UsersyncInfo

func (*RubiconAdapter) Name

func (a *RubiconAdapter) Name() string

Name - export adapter name

Jump to

Keyboard shortcuts

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