Skip to content

Commit

Permalink
Submission commit
Browse files Browse the repository at this point in the history
  • Loading branch information
vsdepontes committed Jun 20, 2022
1 parent 2c6b50e commit 00784d4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,14 @@ Backend service for the Coodesh "[Back-end Challenge 2021 🏅 - Space Flight Ne
The service consumes the [Space Flight News API](https://api.spaceflightnewsapi.net/v3/documentation), saving articles about space news on its own
database and exposing them through its own API.

Loom presentation link: https://www.loom.com/share/8030dc795bd94a3b9965c509cf8221ee

## Try it Live!

https://space-flight-news-backend-node.herokuapp.com/
Base URL: https://space-flight-news-backend-node.herokuapp.com/
Documentation URL: https://space-flight-news-backend-node.herokuapp.com/api

It might take a while for the service to answer on the first time.

## Technologies Used

Expand Down
3 changes: 2 additions & 1 deletion src/cron/update-space-flight-news.cron.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Cron } from "@nestjs/schedule";
import { Cron, Timeout } from "@nestjs/schedule";
import { HttpService } from "@nestjs/axios";
import { Injectable, Logger } from "@nestjs/common";
import { firstValueFrom } from "rxjs";
Expand All @@ -20,6 +20,7 @@ export class UpdateSpaceFlightNews {
@InjectModel(Article.name) private readonly articleModel: Model<Article>,
) {}

//@Timeout(1000)
@Cron("0 0 9 * * *")
async importArticles() {
const queryParams = new SpaceFlightNewsQueryParameters();
Expand Down

0 comments on commit 00784d4

Please sign in to comment.