uuid-generator

command module
v0.0.0-...-bdfe249 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2023 License: Unlicense Imports: 6 Imported by: 0

README

uuid-generator

Description

Develop an stateful application containing generated uuid hash in its memory.

Hash should be recreated every 5 minutes.

Application should contain two api servers: gRPC and http.

Each api should implement single endpoint to get actual hash string and hash generation datetime.

Cover code with unit tests where it’s needed.

This app should demonstrate coding quality, app design skills, golang best practices, etc.

It is preferable to upload the results of the work to github or some other public repo.

Notes

Generally, this app could be contained in just one small main.go file, especially if we're certain it won't expand. However, if it becomes part of a microservice architecture, we may want to move some packages into shared libraries and reuse it in another apps.

How to run

In project root create your own .env file (based on env.example)

To make clean production build and run it locally:

docker-compose up --build uuid-generator

To make and run build for debugging:

docker-compose up --build uuid-generator-debug

After running, you can connect to localhost:40000 to debug it

To run tests:

go test -v -coverprofile=coverage.out ./...

Use

For HTTP endpoint call http://localhost:8080

For GRPC call grpc://localhost:8090 rpc GetCurrentHash

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
Package mock_log is a generated GoMock package.
Package mock_log is a generated GoMock package.

Jump to

Keyboard shortcuts

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