diff --git a/CHANGELOG.md b/CHANGELOG.md index aa29024..a921ddc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,11 @@ # Changelog +## [0.17.3] - 2025-08-04 +### Improved +- Se ha aƱadido el filtro "jobId" a la entidad Trace. + +--- ## [0.17.2] - 2025-08-04 -## Improved +### Improved - Se ha cambiado la respuesta de algunos endpoints que llaman al ogAgent. Ahora devuelve el job_id asociado a la traza. --- diff --git a/config/services/api_platform.yaml b/config/services/api_platform.yaml index 087e0f9..19a2e47 100644 --- a/config/services/api_platform.yaml +++ b/config/services/api_platform.yaml @@ -298,7 +298,7 @@ services: api_platform.filter.trace.search: parent: 'api_platform.doctrine.orm.search_filter' - arguments: [ { 'id': 'exact', 'command': 'exact', 'client.id': 'exact', 'status': 'exact' } ] + arguments: [ { 'id': 'exact', 'command': 'exact', 'client.id': 'exact', 'status': 'exact', 'jobId': 'exact' } ] tags: [ 'api_platform.filter' ] api_platform.filter.trace.order: diff --git a/etc/cron.d/opengnsys-check-clients b/etc/cron.d/opengnsys-check-clients index 28f5e88..bd2f7da 100644 --- a/etc/cron.d/opengnsys-check-clients +++ b/etc/cron.d/opengnsys-check-clients @@ -1,3 +1,4 @@ */2 * * * * opengnsys php -d memory_limit=512M /opt/opengnsys/ogcore/api/bin/console opengnsys:check-client-availability>> /opt/opengnsys/ogcore/api/var/log/cron.log 2>&1 */1 * * * * opengnsys php -d memory_limit=512M /opt/opengnsys/ogcore/api/bin/console opengnsys:run-scheduled-command-tasks>> /opt/opengnsys/ogcore/api/var/log/cron.log 2>&1 -*/1 * * * * opengnsys php -d memory_limit=512M /opt/opengnsys/ogcore/api/bin/console opengnsys:execute-pending-traces>> /opt/opengnsys/ogcore/api/var/log/cron.log 2>&1 \ No newline at end of file +*/1 * * * * opengnsys php -d memory_limit=512M /opt/opengnsys/ogcore/api/bin/console opengnsys:execute-pending-traces>> /opt/opengnsys/ogcore/api/var/log/cron.log 2>&1 + diff --git a/src/State/Processor/PartitionProcessor.php b/src/State/Processor/PartitionProcessor.php index d127e4b..56803c0 100644 --- a/src/State/Processor/PartitionProcessor.php +++ b/src/State/Processor/PartitionProcessor.php @@ -76,14 +76,13 @@ readonly class PartitionProcessor implements ProcessorInterface $response = $this->partitionAssistantAction->__invoke($data); - // Si hay una respuesta exitosa, devolvemos el contenido del job ID if ($response instanceof JsonResponse && $response->getStatusCode() === 200) { $jobContent = json_decode($response->getContent(), true, 512, JSON_UNESCAPED_SLASHES); $jsonString = json_encode($jobContent, JSON_UNESCAPED_SLASHES); return new JsonResponse($jsonString, Response::HTTP_OK, [], true); } - return new JsonResponse('OK', Response::HTTP_NO_CONTENT); + return new JsonResponse(data: ['/clients/' . $image->getClient()->getUuid() => ['headers' => []]], status: Response::HTTP_OK); } private function processDelete($data, Operation $operation, array $uriVariables = [], array $context = []): null