mirror of
https://github.com/microsoft/onefuzz.git
synced 2025-06-16 20:08:09 +00:00
slightly trim state update logs (#68)
This commit is contained in:
@ -78,6 +78,8 @@ def execute_update(update: Update) -> None:
|
||||
if update.update_type == UpdateType.Scaleset:
|
||||
return
|
||||
|
||||
logging.info("performing queued update: %s", update)
|
||||
|
||||
if update.update_type in update_objects:
|
||||
if update.PartitionKey is None or update.RowKey is None:
|
||||
raise Exception("unsupported update: %s" % update)
|
||||
@ -103,8 +105,3 @@ def execute_update(update: Update) -> None:
|
||||
return
|
||||
|
||||
raise NotImplementedError("unimplemented update type: %s" % update.update_type.name)
|
||||
|
||||
|
||||
def perform_update(update: Update) -> None:
|
||||
logging.info("performing queued update: %s", update)
|
||||
execute_update(update)
|
||||
|
@ -23,7 +23,7 @@ def process_scaleset(scaleset: Scaleset) -> None:
|
||||
|
||||
if scaleset.state in ScalesetState.needs_work():
|
||||
logging.info(
|
||||
"executing scaleset state: %s - %s",
|
||||
"exec scaleset state: %s - %s",
|
||||
scaleset.scaleset_id,
|
||||
scaleset.state.name,
|
||||
)
|
||||
|
@ -8,13 +8,13 @@ import json
|
||||
import azure.functions as func
|
||||
|
||||
from ..onefuzzlib.dashboard import get_event
|
||||
from ..onefuzzlib.updates import Update, perform_update
|
||||
from ..onefuzzlib.updates import Update, execute_update
|
||||
|
||||
|
||||
def main(msg: func.QueueMessage, dashboard: func.Out[str]) -> None:
|
||||
body = msg.get_body()
|
||||
update = Update.parse_obj(json.loads(body))
|
||||
perform_update(update)
|
||||
execute_update(update)
|
||||
|
||||
event = get_event()
|
||||
if event:
|
||||
|
Reference in New Issue
Block a user