Documentation
¶
Index ¶
- Constants
- func CertOption(tlsEnabled string) credentials.TransportCredentials
- func GenerateTestData()
- func GetCertPool() *x509.CertPool
- func GetDialOption(tlsEnabled string) grpc.DialOption
- func GetServerCerts() *tls.Certificate
- func RandomBookWithID(id string) *pb.Book
- func RandomInt(min int, max int) int
- func RandomName() string
Constants ¶
View Source
const ( // GRPCServerPort is the port used in the gRPC server GRPCServerPort = "8080" // ProxyPort is the port used in the proxy gateway server ProxyPort = "8000" // Network is the network type, which must be "tcp", "tcp4", "tcp6", "unix" or "unixpacket". Network = "tcp" )
Variables ¶
This section is empty.
Functions ¶
func CertOption ¶
func CertOption(tlsEnabled string) credentials.TransportCredentials
func GenerateTestData ¶
func GenerateTestData()
GenerateTestData generates json array & stores it to testdata/testdata.json file
func GetCertPool ¶
func GetDialOption ¶
func GetDialOption(tlsEnabled string) grpc.DialOption
func GetServerCerts ¶
func GetServerCerts() *tls.Certificate
func RandomBookWithID ¶
RandomBookWithID returns a random book item with the given ID
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.