From 1590e4c5b53cfa1796653e75badad78ac4021988 Mon Sep 17 00:00:00 2001 From: ryonsteele Date: Tue, 12 Dec 2023 15:16:13 +0000 Subject: [PATCH] Fix logging bugs --- docs/deployment/worbook_usage.md | 2 +- functions/FileLayoutParsingOther/__init__.py | 1 + infra/core/logging/monitor.bicep | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/deployment/worbook_usage.md b/docs/deployment/worbook_usage.md index efb636d8e..4d9e9deab 100644 --- a/docs/deployment/worbook_usage.md +++ b/docs/deployment/worbook_usage.md @@ -9,7 +9,7 @@ The Azure Workbook template `infoasst-lw-xxxx` is designed for log analysis, pro - Default Query: ```kql AppServiceConsoleLogs - | project TimeGenerated, Level, ResultDescription, _ResourceId + | project TimeGenerated, ResultDescription, _ResourceId | where TimeGenerated > ago(6h) | order by TimeGenerated desc ``` diff --git a/functions/FileLayoutParsingOther/__init__.py b/functions/FileLayoutParsingOther/__init__.py index e1aa0adf9..d0f5787a3 100644 --- a/functions/FileLayoutParsingOther/__init__.py +++ b/functions/FileLayoutParsingOther/__init__.py @@ -52,6 +52,7 @@ def PartitionFile(file_extension: str, file_url: str): bytes_io = BytesIO(response.content) response.close() metadata = [] + elements = None try: if file_extension == '.csv': from unstructured.partition.csv import partition_csv diff --git a/infra/core/logging/monitor.bicep b/infra/core/logging/monitor.bicep index fb10c78eb..0bcb9dca9 100644 --- a/infra/core/logging/monitor.bicep +++ b/infra/core/logging/monitor.bicep @@ -30,7 +30,7 @@ resource logworkbook 'Microsoft.Insights/workbooktemplates@2020-11-20' = { type: 3 content: { version: 'KqlItem/1.0' - query: 'AppServiceConsoleLogs | project TimeGenerated, Level, ResultDescription, _ResourceId | where TimeGenerated > ago(6h) | order by TimeGenerated desc' + query: 'AppServiceConsoleLogs | project TimeGenerated, ResultDescription, _ResourceId | where TimeGenerated > ago(6h) | order by TimeGenerated desc' size: 0 timeContext: { durationMs: 86400000