Documentation ¶
Overview ¶
Package tcp provides a Target subtype for a TCP Target. Importing this package will register it with the target package and allow the target.Repository to support tcp.Targets.
Index ¶
- Constants
- type Target
- func (t *Target) Clone() target.Target
- func (t *Target) GetType() subtypes.Subtype
- func (t *Target) Oplog(op oplog.OpType) oplog.Metadata
- func (t *Target) SetCreateTime(ts *timestamp.Timestamp)
- func (t *Target) SetDefaultPort(port uint32)
- func (t *Target) SetDescription(description string)
- func (t *Target) SetName(name string)
- func (t *Target) SetPublicId(ctx context.Context, publicId string) error
- func (t *Target) SetScopeId(scopeId string)
- func (t *Target) SetSessionConnectionLimit(limit int32)
- func (t *Target) SetSessionMaxSeconds(s uint32)
- func (t *Target) SetTableName(n string)
- func (t *Target) SetUpdateTime(ts *timestamp.Timestamp)
- func (t *Target) SetVersion(v uint32)
- func (t *Target) SetWorkerFilter(filter string)
- func (t *Target) TableName() string
- func (t *Target) VetForWrite(ctx context.Context, _ db.Reader, opType db.OpType, _ ...db.Option) error
Constants ¶
const (
Subtype = subtypes.Subtype("tcp")
)
const (
// TargetPrefix is the prefix for public ids of a tcp.Target.
TargetPrefix = "ttcp"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Target ¶
Target is a resources that represets a networked service that can be accessed via TCP. It is a subtype of target.Target.
func New ¶
New creates a new in memory tcp target. WithName, WithDescription and WithDefaultPort options are supported
func TestTarget ¶
TestTarget is used to create a Target that can be used by tests in other packages.
func (*Target) Oplog ¶
Oplog provides the oplog.Metadata for recording operations taken on a Target.
func (*Target) SetCreateTime ¶
func (*Target) SetDefaultPort ¶
func (*Target) SetDescription ¶
func (*Target) SetPublicId ¶
func (*Target) SetScopeId ¶
func (*Target) SetSessionConnectionLimit ¶
func (*Target) SetSessionMaxSeconds ¶
func (*Target) SetTableName ¶
SetTableName sets the tablename and satisfies the ReplayableMessage interface. If the caller attempts to set the name to "" the name will be reset to the default name.