def METHOD_NAME(self, message, event_queue=None):
    try:
        mobj = json.loads(message)
    except ValueError:
        self.log.warning(
            "Received message is not a valid JSON: %r",
            message
        )
        return
    try:
        isResponse = self._isResponse(mobj)
    except TypeError:
        self.log.warning(
            "Received batch contains responses and events, ignoring."
        )
        return
    if isResponse:
        self._processIncomingResponse(mobj)
    else:
        self._processEvent(mobj, event_queue)