Forum Discussion

JoshT's avatar
JoshT
Icon for Advocate III rankAdvocate III
3 years ago
Solved

When are personal workspaces (my workspace) created?

Does anyone know the point at which the 'my workspace' is created in the service for any given user? i.e. is it when:   * A licence of any type is assigned to the user * The user logs in for the f...
  • JoshT's avatar
    3 years ago

    I've tested this with a user who has never logged in, running the below script after a) assigning a licence and b) getting them to log in. I can confirm that the personal workspace is only created when the user logs in:

     

    Connect-PowerBIServiceAccount
    
    $user = [user principal name]
    
    Get-PowerBIWorkspace -Type "PersonalGroup" -Scope Organization -All | ForEach-Object {
        
        $printWs = $false
    
        $_.Users | ForEach-Object {
            if ($_.UserPrincipalName -eq $user) {
                $printWs = $true
            }
        }
    
        if ($printWs -eq $true) {
            $_
        }
    }

    For the other part of my question, I was trying to gather if large amounts of unused personal workspaces affects the performance of any aspects of Power BI - other than returning more data to sift through in the scanner API, the amount of data taken up by an empty workspace is minimal. This sufficed as an answer for my organisation: given that users can easily create lots of workspaces based on sharepoint lists, even if workspace creation rights are restricted, we should expect to have a large number of workspaces in the tenant and that won't be a problem.