/uuid-server

uuid-server generates a UUID upon a HTTP request.

Primary LanguageGoMIT LicenseMIT

uuid-server

Generates Version 4 UUIDs upon an HTTP request

StatusInstallConfigurationUsageBenchmarkContributingLicense

[GitHub release] [Build Status] GitHub go.mod Go version [Go Report Card] [License]

Status

UUID Server is currently on API v1, and is available for general usage!

Install

Native

Either download a release from the releases page, or clone and run make install, and execute:

uuid-server

Docker

Either pull lpulles/uuid-server:latest, or clone and run make docker-build, and execute:

docker run -p 8080:8080 lpulles/uuid-server:latest

Configuration

You can set the following environment variables:

  • PORT: What port to run the server on. Defaults to 8080
  • LOGLEVEL: What level to log at. Valid levels: [INFO, ERROR]. Defaults to INFO.

Usage

Once the app is running (see Install):

curl http://127.0.0.1:8080/

(Or an equivalent way of sending a GET on /)

Should yield a response similar to:

bb290e59-8139-41ad-8f4a-b22002725583

Benchmark

Result of uuid-server 2>/dev/null & siege -t30s http://127.0.0.1:8080

** SIEGE 4.0.4
** Preparing 25 concurrent users for battle.
The server is now under siege...
Lifting the server siege...
Transactions:                 635630 hits
Availability:                 100.00 %
Elapsed time:                  29.52 secs
Data transferred:              21.82 MB
Response time:                  0.00 secs
Transaction rate:           21532.18 trans/sec
Throughput:                     0.74 MB/sec
Concurrency:                   23.27
Successful transactions:      635631
Failed transactions:               0
Longest transaction:            0.04
Shortest transaction:           0.00

Contributing

Please submit an issue with your proposal.

License

See LICENSE