News app - backend API
A small API to serve RSS feeds.
View the API documentation here.
This guide assumes you have git and docker installed on your local machine
$ git clone https://github.com/josephroberts/news-app.git
$ cd news-app
$ docker build -t news-app .
docker run -it -p 5050:5050 -v ${PWD}/config.yaml:/app/config.yaml news-app
Edit config.yml
to add/remove feed sources and to change the port used - remember to change port in the docker run command too
- Feed title is unique - if feed title is not unique, only one feed with that title will be served by the API
- When filtering by category, don't serve feed items that don't have a category
- In a feed item has more than one category I only consider the first when filtering by category
- Write some tests
- Write some examples
- Replace
MemoryStore
with a DB or mapcategory
to feed itemGUID
and use this to filter by category more efficiently - Read RSS feeds inside
go routines
to performGET
requests in parallel and handle timeouts - Define
error
types and handleerrors
better