Solution to the technical test
git clone https://github.com/omecodes/ditt
cd ditt
go get -v -t -d ./...
cd bin
make
chmod u+x ditt-api-server
Assuming you are in the bin
folder, run the following command:
./ditt-api-server start --port=8080
By default, the program target a mongo database running at localhost. If you want it to connect to another mongo database you can specify it this way:
./ditt-api-server start --port=8080 --db-uri=<target-db-uri>
The API is pretty well covered. Tests for implementations of UserDataStore
and Files
are the big absents but this is
due to lack of time.
Some part of the specification were not very clear to me. Maybe it'll be discussed during our next call
I spent time reading about routine/channels and Mongo. About Mongo, I tried up to 2 different go implementations.