Skip to main content

Power BI Developer community August update

Headshot of article author Nimrod Shalit

This blog post covers the latest updates for Power BI Developers community. Don’t forget to check out the July blog post, if you haven’t done so already.

 

Embedded Analytics

T12426-Final Power BI Embedded Comic Strip 9 2018 06 11

 

Here is the list of August updates for Embedded Analytics…

Power BI Embedded in Azure

Multi-Geo support in Power BI Embedded (Preview)

Integration with Azure Diagnostics

Metrics- new QPU metric added

 

Embed capabilities

Customize end-user’s error experience

Troubleshooting errors

Power BI Embedded Playground new sample content

 

Automation & life-cycle management

Power BI REST APIs with the new workspace (Preview)

 
 

Power BI Embedded in Azure

Multi-Geo support in Power BI Embedded (Preview)

As announced in July, Power BI Premium now supports Multi-Geo (Preview). Based on the same feature set and limitations, Multi-Geo is now available for preview to customers using A capacity for Power BI Embedded. Until now, ISVs who wished to store data in multiple regions, had to deploy different Power BI Tenants in each region, a solution that demanded a lot of manual and repeating work and was very hard to manage. Now, ISVs can deploy different capacities in different regions, ensuring that data resides only in those regions, all in the same Power BI Tenant. Learn more on Multi-Geo in Power BI Embedded.

 

Integration with Azure Diagnostics

We are excited to release the integration of Power BI Embedded with Azure Diagnostics Logs. Using Diagnostics events can help you dive into specific behaviors of the resource and better understand root causes for any peaks in usage or errors that occurred.

With Diagnostics, you can log to many events from your capacity, pour them into any analytics tool and get insights on the behavior of your resource. We added a built-in integration that help you store the events in a storage account in Azure, stream them to event Hub or analyze in Log Analytics. Learn how to use Azure Diagnostics on Power BI Embedded resource.

 

Metrics- new QPU metric added

Following many customer requests, we have added a new metric to Power BI Azure resource monitoring metrics- Query Processing Units (QPU).

QPU1

The QPU metric monitors the compute load on your capacity at any given moment, showing you the raw metric in % relative to the SKU of the resource. Since the capacity is composed of v-cores that holds a certain amount of compute power and memory, you now have a direct way to monitor the exact load on your capacity with different aggregations (see example in the image below), define thresholds and setup alerts on top of it.

QPU3

 

 

Embed capabilities

Customize end-user’s error experience

When a report fails to load or is not available to the end user at that moment, the end user of your application will see a default Power BI error page:

override error 1

Your app’s end-user might not be familiar with Power BI or the use of Power BI in your application, so this error message can be confusing.

Now we added the option for developers to override the default error experience with their own customized page, that will fit the app design and flow. This feature allows you to add anything you want on top of the iFrame- a popup message, entire page with your native app design or custom action buttons to bring the user back to the app flow. Here is a basic example of a different error page instead of the default error:

override error 2

Accomplishing this is very simple. All you need to do is configure the errors to be hidden and listen to error events that will trigger your own error experience. Learn how to override error experience.

There are many errors that can occur, and not all of them are on the same severity level. For example, when a report fails to load, the user can’t do anything with the repot. However, if an operation on the report, such as ‘export data’ fails, the user should be notified but he can continue using the report. To address that, we have added a ‘level’ property, indicating the type of error occurred. Each level refers to a different group of errors. The ‘Fatal’ level, for example’ means the report failed to load completely and the user can’t interact with anything. You can handle different types of errors using the ‘level’ property, giving the user the appropriate context to the error he is facing.

The override feature is available for reports only. We will add this feature to all embedded objects in the future.

 

Troubleshooting your application

In addition to customizing the end-user experience in case of errors, we made significant work in our error infrastructure to enable developers prevent or minimize errors from occurring in the first place.

Starting now, errors will have a more detailed and indicative content that can help you analyze root causes faster and with minimal need for external support. Here is a code snippet to help you debug through the browser’s console log:

// Get a reference to the embedded report HTML element

var embedContainer = $('#embedContainer')[0];

// Get a reference to the embedded report.

var report = powerbi.get(embedContainer);

report.on('error', (errorObject) => {

const err = errorObject.detail;

// Print error to console

console.log(`Error occurred: ${err.message}. Detailed message: ${err.detailedMessage}`);

console.log(err);

});

Learn more on troubleshooting and debugging your solution.

 

Power BI Embedded Playground new sample content

Power BI has made a long way in the last year, adding many new features and capabilities to its visuals, reports and dashboards. Now you can explore many of these new features in our new sample content that is available in Power BI Embedded Playground.

The new sample has replaced the previous report and dashboard, making the tool more engaging and attractive. Now it’s easier to learn how JavaScript API integrates with new features such as Q&A explorer, Drill through, visual configuration, report tooltips and more. The new content will also help us easily add more features and capabilities into the Playground in the future.

 

playground1

 

 

Automation & life-cycle management

Power BI REST APIs with the new workspace (Preview)

Power BI has released for Preview a new workspace experience, allowing you to create workspaces without creating an O365 group and assigning user groups to roles. For developers, the new workspace can be managed in the same way as existing workspace, since all the user REST APIs functions in the same way on new workspaces. You can also use the new workspace for embedding Power BI analytics into custom applications.

The new workspace allows for an increase in the no. of workspaces a user can create/ be a member of. It is mostly targeted for ISVs using Power BI Embedded in their app with a ‘Master user’. The recommended approach for handling multi-tenancy in such case is to create a workspace for each tenant, under same ‘Master user’. The limit has increased from 250 workspaces to a 1000, allowing ISVs for an easier scale when they have a large customer base.

The ‘Create Group’ API will continue by default to create the existing workspaces until the new workspace experience is generally available. Until then, if you want the existing API to create new workspace experience, you need Power BI to provision you for this operation. To do so, please open a support ticket and mention the specific users to be provisioned, or if the provisioning should be for the entire Tenant.

 

What’s still puzzling

Answers to some of the frequently asked questions in the Power BI Embedded developer community.

Q: I want users to feel that analytics are a native part of my application, so I want to hide the flickering logo of Power BI when a report is loaded. How can I accomplish that?

Giving your users a seamless experience in the transition from a native page to consuming Power BI analytics is key.

Power BI Embedded JavaScript SDK gives you the tools to do that. After calling ‘embed’ API to show a report, you have the option to listen to 2 different events:

  • Report loaded- fired when report finished loading scripts and data from server, and visuals are being rendered on the browser. When this event is fired, the flickering Power BI logo stops showing but the report is not fully ready to be consumed.
  • Report rendered- fired when visuals finished rendering, and report is fully visible and ready for consumption.

You can place any loading animation you want on top of the iFrame and remove it when the relevant event is being fired.

 

If you are puzzled or run into few issues, be sure to check our resources that can help you get by:

  •  ‘Troubleshooting’ doc to help you get by all the obstacles on your way for building a great app.
  • FAQ doc to answer all your question regarding the Product, licensing and Azure capacities.
  • Community forum for developers, to seek answers or ask any other questions you have.

 

 

Custom Visuals

 

New GitHub for Custom visuals. 

We are very happy to announce that our new custom visual’s Github.io is now live!

All the developer documentation is visible and can be found in one place, that includes: Step-by-step lab, advanced labs, samples, releases, APIs, concepts and more…

This is our first public release, we will keep enriching and adding new content in the coming weeks.

Keep up the great work of contributing and engaging with the community and now in the new GitHub!

CV1

 

CV2

 

Custom visual 2.1 API is now available

As we continue to improve our platform and enhance our feature set to enable our developers and partners to get the most from custom visuals' platform, we release new API versions constantly. It is always recommended to keep your visuals updated with the new released versions of API to get the latest and greatest features.

With API 2.1 we improved the loading time of custom visual by 20% on average!

All you need to do to boost your custom visual's performance is update the pbiviz tool and update your visual with the latest version of API (2.1):

npm install -g powerbi-visuals-tools

pbiviz update 2.1.0

pbiviz package

Two weeks ago we announced that starting from September 1st only API 1.2 and above will be supported. This is a great opportunity to update your old visuals and enjoy the enhancements we release with every new version.

2.1 API Known limitation:

  • Filtering APIs are also being refactored and will be available in API 2.2. Not supported in 2.1.
  • Visuals will only receive the dataView type that was declared in their capabilities. Visuals that used multiple dataView types will break as a result of this update.
  • The DataViewScopeIdentity interface is no longer supported, it was replaced with the data.DataRepetitionSelector interface.
  • undefined is replaced by null inside the dataView.

When iterating over an array with the following way “var key in arr” it skips on undefined but doesn't skip on null.

Visuals that use this pattern may be broken by this update.

Alternatively please use:

for (var item in myArray) {

if (!item)

continue;

    console.log(item);

  • The _proto_ property doesn't store hidden metadata\data anymore inside the dataView. Visuals that access properties via _proto_ may be broken by this update.

For any technical question please reach out to pbicvsupport@microsoft.com

 

Complete support of localization

Good news! buenas noticias חדשות טובות! !أخبار جيدة Хорошие новости!

Now you can localize your custom visual in 44 different languages! That means you can make your custom visual accessible to as many people as possible!

Custom visuals support complete localization. Which means, localization not only in the custom visual framework but also in the visuals inside the canvas.

All our in-house custom visuals are now localized.

Please check out this article for a complete guide to localization and code snippet required to support this feature.

CV3    CV4

CV5

 

As always, feel free to use all the communication channels at your disposal to connect with our team, share your thoughts and ask questions:

 

 

That’s all for this post. We hope you found it useful. Please continue sending us your feedback, it’s very important for us. Have an amazing feature in mind? please share it or vote in our Power BI Embedded Ideas forum, or our Custom Visuals Ideas forum.