Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/puzpuzpuz/hazelcast-go-experiment
https://github.com/puzpuzpuz/hazelcast-go-experiment
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/puzpuzpuz/hazelcast-go-experiment
- Owner: puzpuzpuz
- License: mit
- Created: 2021-02-16T13:19:33.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2021-02-16T14:47:01.000Z (almost 4 years ago)
- Last Synced: 2024-05-02T06:05:32.576Z (8 months ago)
- Language: Go
- Size: 1.95 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Turbine Go Experiment
Simple experiment aimed towards understanding memory footprint of HTTP server in combination with Hazelcast Go client.
Requires Go v1.13.
## Start
First of all, you need to start Hazelcast IMDG cluster. The simplest way is to start a single member cluster with Docker:
```bash
docker run --net=host hazelcast/hazelcast:3.12.12
```With Go:
```bash
go get -d github.com/gorilla/mux
go get -d github.com/hazelcast/hazelcast-go-client
go run main.go
```## Test
```bash
curl -X POST -H "Content-Type: text/plain" -d '{"foo": "bar"}' http://127.0.0.1:8080/api/testmap/testkey
```## Load Test
The following command with be generating 1,000 RPS load for one minute:
```bash
npx autocannon -c 10 -d 60 -R 1000 -m POST -b "testvalue" -H "Content-Type: text/plain" http://localhost:8080/api/testmap/testkey
```