Project

General

Profile

Actions

Bug #22449

closed

API seems to be locked during host deletion

Added by Anthony Chevalet over 6 years ago. Updated over 5 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Difficulty:
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

During host deletion, every API requests stay blocked until the host is deleted.

To reproduce this behaviour, you can add a "sleep xx" in foreman hooks (before/after destroy). Example:

$ cat config/hooks/host/managed/after_destroy/after_destroy.sh
#!/bin/bash
sleep 90

Run host deletion, example:
`hammer host delete --name myclient.local`

During that time, try some get requests, example on compute resources:
`hammer compute-resource info --id 47`

This requests will stay blocked until the host get deleted (>90 sec).

Using this kind of request inside hooks (destroy) will block foreman thread indefinitely.

Actions

Also available in: Atom PDF