bench

package
v3.2.15 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2023 License: Apache-2.0 Imports: 4 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

Results:

Results after just adding the benchmark test on commit: 5f8bf8a3fec64e2df6d1032381a6084028fd7867 (Base line no changes)

BenchmarkClientServerRoundTripSmallMsg-12 11257 105941 ns/op 17392 B/op 290 allocs/op BenchmarkClientServerRoundTripBigStrMsg-12 9408 127801 ns/op 71079 B/op 293 allocs/op BenchmarkClientServerRoundTripBigMapBigStrMsg-12 3555 309087 ns/op 187275 B/op 2725 allocs/op

BenchmarkClientServerRoundTripSmallMsg-12 10671 107704 ns/op 17393 B/op 290 allocs/op BenchmarkClientServerRoundTripBigStrMsg-12 8620 132313 ns/op 71168 B/op 293 allocs/op BenchmarkClientServerRoundTripBigMapBigStrMsg-12 3576 315491 ns/op 187284 B/op 2725 allocs/op

BenchmarkClientServerRoundTripSmallMsg-12 11174 110227 ns/op 17395 B/op 290 allocs/op BenchmarkClientServerRoundTripBigStrMsg-12 8658 139203 ns/op 71103 B/op 293 allocs/op BenchmarkClientServerRoundTripBigMapBigStrMsg-12 3556 315230 ns/op 187242 B/op 2725 allocs/op

Results after just adding the benchmark test on commit: dad755d6cb11f4daab738eec8133554a7c3c48e7 (pre-compiled names regex)

Just focusing on optimizing Allocations per Operation for this set of changes

BenchmarkClientServerRoundTripSmallMsg-12 11971 94264 ns/op 11850 B/op 208 allocs/op BenchmarkClientServerRoundTripBigStrMsg-12 9106 114902 ns/op 65520 B/op 211 allocs/op BenchmarkClientServerRoundTripBigMapBigStrMsg-12 3831 298895 ns/op 181501 B/op 2642 allocs/op

BenchmarkClientServerRoundTripSmallMsg-12 12870 92300 ns/op 11848 B/op 208 allocs/op BenchmarkClientServerRoundTripBigStrMsg-12 9277 114179 ns/op 65505 B/op 211 allocs/op BenchmarkClientServerRoundTripBigMapBigStrMsg-12 3537 293994 ns/op 181645 B/op 2642 allocs/op

BenchmarkClientServerRoundTripSmallMsg-12 12685 92157 ns/op 11848 B/op 208 allocs/op BenchmarkClientServerRoundTripBigStrMsg-12 9462 115722 ns/op 65519 B/op 211 allocs/op BenchmarkClientServerRoundTripBigMapBigStrMsg-12 3644 295176 ns/op 181563 B/op 2642 allocs/op

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type Event

type Event struct {
	Timestamp string            `protobuf:"bytes,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	User      string            `protobuf:"bytes,2,opt,name=user,proto3" json:"user,omitempty"`
	Type      int32             `protobuf:"varint,3,opt,name=type,proto3" json:"type,omitempty"`
	Strdata   string            `protobuf:"bytes,4,opt,name=strdata,proto3" json:"strdata,omitempty"`
	Data      map[string]string `` /* 149-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*Event) Descriptor deprecated

func (*Event) Descriptor() ([]byte, []int)

Deprecated: Use Event.ProtoReflect.Descriptor instead.

func (*Event) GetData

func (x *Event) GetData() map[string]string

func (*Event) GetStrdata

func (x *Event) GetStrdata() string

func (*Event) GetTimestamp

func (x *Event) GetTimestamp() string

func (*Event) GetType

func (x *Event) GetType() int32

func (*Event) GetUser

func (x *Event) GetUser() string

func (*Event) ProtoMessage

func (*Event) ProtoMessage()

func (*Event) ProtoReflect added in v3.2.14

func (x *Event) ProtoReflect() protoreflect.Message

func (*Event) Reset

func (x *Event) Reset()

func (*Event) String

func (x *Event) String() string

type EventResponse

type EventResponse struct {
	Timestamp string            `protobuf:"bytes,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	Id        string            `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"`
	Strdata   string            `protobuf:"bytes,3,opt,name=strdata,proto3" json:"strdata,omitempty"`
	UserID    int32             `protobuf:"varint,4,opt,name=userID,proto3" json:"userID,omitempty"`
	Data      map[string]string `` /* 149-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*EventResponse) Descriptor deprecated

func (*EventResponse) Descriptor() ([]byte, []int)

Deprecated: Use EventResponse.ProtoReflect.Descriptor instead.

func (*EventResponse) GetData

func (x *EventResponse) GetData() map[string]string

func (*EventResponse) GetId

func (x *EventResponse) GetId() string

func (*EventResponse) GetStrdata

func (x *EventResponse) GetStrdata() string

func (*EventResponse) GetTimestamp

func (x *EventResponse) GetTimestamp() string

func (*EventResponse) GetUserID

func (x *EventResponse) GetUserID() int32

func (*EventResponse) ProtoMessage

func (*EventResponse) ProtoMessage()

func (*EventResponse) ProtoReflect added in v3.2.14

func (x *EventResponse) ProtoReflect() protoreflect.Message

func (*EventResponse) Reset

func (x *EventResponse) Reset()

func (*EventResponse) String

func (x *EventResponse) String() string

Jump to

Keyboard shortcuts

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