adamkali / adamkali/MiraculousKingdom

Make the Queue a Server State

Aberta
#24 1 comentário 0 reações 0 responsáveis Ver no GitHub
Linguagem predominante
Rust
Estrelas
1
Forks
0
Métricas de merge de PRs
Nenhum PR com merge em 30d

Descrição

When Issue #21 is complete it will help #20 to have the Queue be held as
```rust
pub async fn get_queue(
Extension(mongo): Extension,
State(queue): State>>
) -> Json {
```
rather than

```rust
pub async fn get_queue(
Extension(mongo): Extension,
Path(pass): Path,
) -> Json {
```

this way we will not need to do as many db look ups, and anyone connected could theoretically poll the server by the 'get_queue' function and it will be changed by the post and put methods.

- [x] Change the Queue methods to hold state.
- [x] Create a method called set_state to set the queue from the stored database.
- [ ] test the state on multiple Clients

Guia de contribuição

Abrir o guia de contribuição

Avaliação

Esta issue ainda não foi avaliada.

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.