A assignment for research Goroutines, Channel, MongoDB
- Read config file
- Connect with MongoDB Atlas
- Insert a number into a collection
- Insert large number into a collection
- Use go routine, channel and waitgroup to run 10 worker for insert data
- Add echo to expose a api with POST /assignment/insert method
Clone the repository:
git clone https://github.com/fissama/Go_assignment.git
From the command line:
go build main.go
- POST /assignment/insert
{
"FileData": FileCsv.csv
}