示例#1
0
文件: views.py 项目: tcpcloud/kedb
    def post(self, request, *args, **kwargs):
        event = json.loads(request.body)['event']

        event.update(
            find_by_event(event['check']['name'], event['check']['output']))

        return HttpResponse(json.dumps(event))
示例#2
0
文件: views.py 项目: digideskio/kedb
    def post(self, request, *args, **kwargs):
        event = json.loads(request.body)['event']

        event.update(
            find_by_event(event['check']['name'], event['check']['output']))

        return HttpResponse(json.dumps(event))
示例#3
0
文件: views.py 项目: tcpcloud/kedb
    def post(self, request, *args, **kwargs):

        output = []

        try:
            events = json.loads(request.body)['events']
            for event in events:
                event.update(find_by_event(event["check"]))
                output.append(event)
        except Exception as e:
            raise e
            log.error(e)

        return HttpResponse(json.dumps(output))
示例#4
0
文件: views.py 项目: digideskio/kedb
    def post(self, request, *args, **kwargs):

        output = []

        try:
            events = json.loads(request.body)['events']
            for event in events:
                event.update(find_by_event(event["check"]))
                output.append(event)
        except Exception as e:
            raise e
            log.error(e)

        return HttpResponse(json.dumps(output))