Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

About Update Failure of Log Analytics Report

I get logs from Log Analytics, create graphs in Power BI and update regularly.
However, the refresh began to fail irregularly two weeks ago.
This phenomenon is happening in various reports I have. Is there anyone who knows the cause?

Message:

Web.Contents failed to get contents from 'https ://api.loganalytics.io/v1/workspaces/ .../query?query=OfficeActivity...' (502): Bad Gateway Table: LogAnalytics.


image3.png

M Query

let jp_timezone = (x as datetimezone) as datetimezone => DateTimeZone.SwitchZone(x, 9),
AnalyticsQuery =
let Source = Json.Document(Web.Contents("https://api.loganalytics.io/v1/workspaces/...../query", 
[Query=[#"query"="OfficeActivity
| where ( OfficeWorkload == ""OneDrive"" or OfficeWorkload == ""SharePoint"")
",#"x-ms-app"="OmsAnalyticsPBI",#"prefer"="ai.response-thinning=true"],Timeout=#duration(0,0,10,0)])),
TypeMap = #table(
{ "AnalyticsTypes", "Type" }, 
{ 
{ "string",   Text.Type },
{ "int",      Int32.Type },
{ "long",     Int64.Type },
{ "real",     Double.Type },
{ "timespan", Duration.Type },
{ "datetime", DateTimeZone.Type },
{ "bool",     Logical.Type },
{ "guid",     Text.Type },
{ "dynamic",  Text.Type }
}),
DataTable = Source[tables]{0},
Columns = Table.FromRecords(DataTable[columns]),
ColumnsWithType = Table.Join(Columns, {"type"}, TypeMap , {"AnalyticsTypes"}),
Rows = Table.FromRows(DataTable[rows], Columns[name]), 
Table = Table.TransformColumnTypes(Rows, Table.ToList(ColumnsWithType, (c) => { c{0}, c{3}}))
in
Table,.......

 

2 REPLIES 2
v-yuta-msft
Community Support
Community Support

@Anonymous ,

 

Please check if the Azure credentials is still valid or expired.

 

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Hi @v-yuta-msft 
Thanks for the reply.
I have verified my credentials but they have not expired.
If the Azure credentials have expired, then all of the report refreshes should have failed.
When the report refresh is successful, I can check the latest log.

I would like to apologize for my poor English.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors