nikitsenka / bank-go Goto Github PK
View Code? Open in Web Editor NEWSample bank application written on Go
Sample bank application written on Go
The java version has a limit for the connection pool at https://github.com/nikitsenka/bank-java/blob/master/src/main/java/com/nikitsenka/bankjava/BankJavaApplication.java#L21
I would like to see revised tests with a limit added to the Go version.
I wonder if you could run the test on the latest GoLang release?
123
When load testing I noticed this error.
I've found using github.com/jackc/pgx/v4/pgxpool fixes the problem for me as well as make the whole Golang app faster than Java.
#2 might be related.
I am using go version go1.11.4 darwin/amd64 with export GO111MODULE=on
i$ go test ./bank
bank/main_test.go:13:2: undefined: Init
bank/main_test.go:20:22: not enough arguments in call to NewClient
have (number)
want (*sql.DB, int)
bank/main_test.go:32:16: not enough arguments in call to NewTransaction
have (int, int, number)
want (*sql.DB, int, int, int)
bank/main_test.go:34:26: not enough arguments in call to CheckBalance
have (int)
want (*sql.DB, int)
bank/main_test.go:39:26: not enough arguments in call to CheckBalance
have (int)
want (*sql.DB, int)
bank/main_test.go:49:24: not enough arguments in call to CreateClient
have (Client)
want (*sql.DB, Client)
bank/main_test.go:58:29: not enough arguments in call to CreateTransaction
have (Transaction)
want (*sql.DB, Transaction)
FAIL github.com/nikitsenka/bank-go/bank [build failed]
$ find . -name "*go"|xargs grep NewClient
./bank/bank.go:func NewClient(p *sql.DB, balance int) Client {
./bank/main_test.go: client1 := NewClient(1000)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.