Major Performance issue even with new caching?
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 38/100
- Tipo de issue
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Estancado
- Stack tecnológico
- openapi, php
- Área
- api, performance
Línea de trabajo
Comienza con la reproducción mínima en github.com/lextira/openapi-parse-test y ejecuta test.php contra el fork basado en v1.4 y la versión oficial v1.6. Investiga la ruta de resolución de referencias y el comportamiento de la caché, usando la especificación OpenAPI enlazada como carga de trabajo. Se considera terminado cuando la ruta de v1.6 ya no muestra la regresión de parsing reportada en comparación con el fork.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Hi @cebe
Almost 2 years ago we had a rather big issue with the performance for parsing an API-spec, where all components were store in another (the same) file. It took a couple of minutes to process. My collegue then proposed this PR #65
We ended up using this fork for the last two years now. This week I'm updating dependencies, and having seen that you merged #67 made me realize, that I can finally get rid of our fork.
However, running our test-suite after the update was rather painful: Instead of ~1s to parse our specification, like with our fork, it now took ~30s. I spent a couple of hours analyzing, but I couldn't find the issue. It looks like resolving references is painfully slow, it seems to take 100-300ms for each reference. Clearly, this was much faster in version 1.4, where our fork originates.
Therefore, I hope you can find a minute to look into it as well. I prepared a minimal test setup:
$ git clone https://github.com/lextira/openapi-parse-test
$ composer update
# now we have a composer install with our fork, see https://github.com/lextira/openapi-parse-test/blob/master/composer.json
$ php test.php
Start Reading...
Read took 1248 miliseconds!
Parsed file is 791837 characters long.
$ git checkout with-openapi-1.6
$ composer update
# new we are at the latest release of the official repository
$ php test.php
Start Reading...
Read took 37302 miliseconds!
Parsed File is 791837 characters long.
So with v1.6, reading the exact same file from the exact same URL takes almost 30 times longer than with v1.4 (and our custom cache implementation, which is very similar to your implemented cache now). For context, the specification used for the test is our official API documentation and can be found here: https://docs.lexgate.ch/api/
- Lenguaje dominante
- PHP
- Estrellas
- 500
- Forks
- 99
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de cebe/php-openapi
-
Deprecated warnings in PHP 8.2 Abierto
Dificultad 3/5 1-2 días Aptitud para principiantes 48/100
cebe/php-openapi#250 ·
-
BC break in 1.8 Abierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
cebe/php-openapi#247 · 1 comentario · 1 reacción ·
-
php 8.4 deprecations Abierto
Dificultad 3/5 1-2 días Aptitud para principiantes 58/100
cebe/php-openapi#245 · 3 comentarios ·
-
Dificultad 3/5 1-2 días Aptitud para principiantes 52/100
cebe/php-openapi#242 · 6 comentarios · 1 reacción ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 55/100
cebe/php-openapi#238 ·
Todos los issues de cebe/php-openapi
Issues similares
-
tooling
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
-
UX
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
ProfessionalWiki/NeoWiki#1525 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
-
bug customer-reported
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
MagnaCapax/PMSS#949 ·
-
responsive-media kses allow-list strips clipPathUnits, collapsing objectBoundingBox clip paths Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Automattic/static-site-importer#1829 ·