Commit 1575bdc9 authored by Lukas Burgey's avatar Lukas Burgey
Browse files

Make an obsolete ack is non critical

parent 016589c9
import logging
from rest_framework import generics, views, status
from rest_framework.authentication import TokenAuthentication
from rest_framework.response import Response
from ..models import RabbitMQInstance
from .serializers import SiteSerializer, ServiceSerializer
LOGGER = logging.getLogger(__name__)
# authentication class for the client api
AUTHENTICATION_CLASSES = (TokenAuthentication, )
......@@ -41,4 +45,6 @@ class AckView(views.APIView):
return Response({'ok': True})
return Response({'ok': False}, status=status.HTTP_400_BAD_REQUEST)
# this is no critical'%s executed the obsolete task#%s', request.user, task_id)
return Response({'ok': True})
......@@ -665,11 +665,12 @@ class DeploymentTask(models.Model):
return self.deployment.service
def __str__(self):
return "{}:{}:{} - {}".format(
return "{}:{}:{} - {}#{}".format(
def _msg(self, msg):
......@@ -718,9 +719,10 @@ class DeploymentTaskItem(models.Model):
def __str__(self):
return "{}@{}".format(
return "{}@{}#{}".format(
def _msg(self, msg):
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment