`rfd-cli reserve` is slow / can timeout

Abierto
#609 1 comentario 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
45/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
graphql, rust
Área
backend, cli

Línea de trabajo

Start by tracing the rfd-cli reserve request to the endpoint that finds and reserves the next RFD number, then inspect the REST pagination and timeout settings mentioned in the issue. Compare the proposed timeout, GraphQL, and asynchronous approaches; the issue leaves the solution open. Done means reserve completes without a timeout and the caller can obtain the new RFD number.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

I attempted to use rfd-cli reserve and got a timeout:

% rfd-cli reserve --title "Code of Conduct"
  Communication Error: error sending request for url (https://rfd-api.shared.oxide.computer/rfd)

This is because the rfd-cli timeout is set to 10seconds and gave up before the work was completed on the backend. It succeeded successfully, but I had to go lookup my own new RFD number.


There are a couple ways we could improve this

  • increase the default rfd-cli timeout (current 10secs; job took just under 15seconds today)
  • switch from octorust REST pagination of all ~600 branch names (six pages; 6.2seconds) to GraphQL ordered by branch name descending (first page; ~1second)
  • make the endpoint async: splitting the find from the subsequent commit & push (3.3secs) returning the new RFD number early to the caller.
Lenguaje dominante
Rust
Estrellas
98
Forks
23
Merge medio
17 h 47 min
PR fusionados (30 d)
13

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de oxidecomputer/rfd-api

Todos los issues de oxidecomputer/rfd-api

Issues similares

Más issues de Rust

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.