Skip to content

Commit c274807

Browse files
committed
Revert "Prevent slow-to-start containers from trying to run in the same slot (#114)"
This reverts commit 90cb917. This commit is kept in the legacy branch. Signed-off-by: Marco Casaroli <marco.casaroli@gmail.com>
1 parent 5bc126e commit c274807

3 files changed

Lines changed: 1 addition & 4 deletions

File tree

src/ocre/components/container_supervisor/cs_sm_impl.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -354,8 +354,7 @@ ocre_container_status_t CS_create_container(ocre_container_t *container)
354354
}
355355

356356
if (container->container_runtime_status != CONTAINER_STATUS_UNKNOWN &&
357-
container->container_runtime_status != CONTAINER_STATUS_DESTROYED &&
358-
container->container_runtime_status != CONTAINER_STATUS_RESERVED) {
357+
container->container_runtime_status != CONTAINER_STATUS_DESTROYED) {
359358
LOG_ERR("Cannot create container again container with ID: %d, already exists", curr_container_ID);
360359
return CONTAINER_STATUS_ERROR;
361360
}

src/ocre/ocre_container_runtime/ocre_container_runtime.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ ocre_container_status_t ocre_container_runtime_create_container(ocre_cs_ctx *ctx
5454
(ctx->containers[i].container_runtime_status == CONTAINER_STATUS_DESTROYED)) {
5555
*container_id = i;
5656
ctx->containers[i].container_ID = i;
57-
ctx->containers[i].container_runtime_status = CONTAINER_STATUS_RESERVED;
5857
validity_flag = true;
5958
break;
6059
}

src/ocre/ocre_container_runtime/ocre_container_runtime.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ typedef enum {
5656
*/
5757
typedef enum {
5858
CONTAINER_STATUS_UNKNOWN, ///< Status is unknown.
59-
CONTAINER_STATUS_RESERVED, ///< Container slot has been reserved.
6059
CONTAINER_STATUS_CREATED, ///< Container has been created.
6160
CONTAINER_STATUS_RUNNING, ///< Container is currently running.
6261
CONTAINER_STATUS_STOPPED, ///< Container has been stopped.

0 commit comments

Comments
 (0)