IntuneManagement icon indicating copy to clipboard operation
IntuneManagement copied to clipboard

Limit of applications

Open ASMailer opened this issue 4 years ago • 23 comments

Hi Micke,

First of all, a really big compliment for the developed tool. The development is really super well implemented. You have really closed the big gap that Microsoft has been leaving behind for several years.

Regarding my topic, when I tried the application category it imports not all our apps, seems it took the first ~1000 apps from the graph API. I assume that a limit is defined, and the graph call is not paging until the end. Would it possible to have this variable? We have really a mass of win32apps in intune (~4500).

A workaround would also helpful, I looked for the used graph call, I have found only in the "DocumentationCustom.psm1" the function Get-CDAllTenantApps with the limit 999, but I´m not sure is this the reason.

Thx Andi

ASMailer avatar Sep 24 '21 16:09 ASMailer

Hello Andi,

Thank you for the support and for reporting this. I have been waiting for an issue like this. I know that I need to add paging support in the code so I will look into this.

Graph API has different default based on the API, sometimes 100 and sometimes 1000. I'll add automatic paging to it. However, in a case like this it might be painful since you will get ~4500 items. The data grid can handle it since it uses virtualisation but the scrolling experience will most likely be horrible.

Adding paging is probably going to be the easy part. Making it look good might be way harder. I'll try to implement the paging this weekend or during the week.

Btw...~4500 apps. That is an impressive environment :)

Micke-K avatar Sep 24 '21 23:09 Micke-K

Hey Micke,

Thank you very much for your commitment

Yes, understand, it is precisely in the details that the challenge lies. With the amount of objects we have to use the filter anyway and restrict the view. Otherwise you won't find anything :-)

If there is anything I can test or help, let me know.

Thx Andi

ASMailer avatar Sep 27 '21 14:09 ASMailer

Hello!

I've started this but I've been working every night this week. It might take a bit longer than I thought. I am sorry about that!

Micke-K avatar Sep 30 '21 08:09 Micke-K

I started today also using your tool, great one! I have exactly the same issue ... more than 1000 entries, maybe not only in the apps section. Having the nextlinks included would be great! No hurry.

Phoenix-DH avatar Oct 04 '21 10:10 Phoenix-DH

3.2.3 released with a fix for this. ALL items will now be returned. Please report back how the experience is your environments with 4000+ objects. Will it be impossible because it takes too long time or is it "acceptable".

I will most likely keep looking into this to be able to page or load additional pages in the view but return all objects when exporting, documenting etc.

Micke-K avatar Oct 07 '21 09:10 Micke-K

Fo sure it will take longer, but it is working. Pagination would also be fine if it is quicker, but you need to have all items available to use the filter.

Will try to use it for a preriod of time and give reply.

Phoenix-DH avatar Oct 07 '21 09:10 Phoenix-DH

I will most likely keep looking into this to be able to page or load additional pages in the view but return all objects when exporting, documenting etc.

... that would be the most efficient implementation in the end ...

ASMailer avatar Oct 08 '21 09:10 ASMailer

... i´m already happy ...:-) works really great. We will continue to work with it and see how it goes.

Thank you very much

ASMailer avatar Oct 08 '21 09:10 ASMailer

Hello!

This was fixed in the December update. You will now get two buttons to either download the next batch or download the rest.

Have you tested it yet?

Cheers!

Micke-K avatar Mar 03 '22 11:03 Micke-K

Hey, not now.... Will do! Thanks.

Phoenix-DH avatar Mar 03 '22 11:03 Phoenix-DH

Hey @Micke-K,

I had a look to the applications. In my case a saw the objects amount of 8614 in the bottom line. Does that now mean I got all visible?

Was there a change in the meanwhile again, because there are no buttons ;)

Phoenix-DH avatar Mar 07 '22 06:03 Phoenix-DH

Hmmm that is interesting. So the code only calls it once (single page) and should only return a 1000 objects. Not sure if MS has changed this in the background or I have a bug I can't find. I can force my page size to be 10 and that works great. I have a little bit of problem testing 1000 more objects in my environment :)

Can you try updating MSGraph.psm1. Search for #$params.Add("pageSize",10). Remove # and change size to 500. Should now look like:

$params.Add("pageSize",500)

Cheers!

Micke-K avatar Mar 07 '22 07:03 Micke-K

Thats not in the code ... completely not. I only find something with

        elseif($AllPages -eq $true -and $HttpMethod -eq "GET" -and $ret.value -is [Array])
        {
            $allValues += $ret.value
            if($ret.'@odata.nextLink')
            {
                $Url = $ret.'@odata.nextLink'
            }
        }

Seems that you are doing this by default ...

Phoenix-DH avatar Mar 07 '22 07:03 Phoenix-DH

Sorry, I had pageSize at 100 in my original test. It should be at row 489. At least in version 3.4.0.

if($SinglePage -eq $true) { #Use default page size or use below for a specific page size for testing #$params.Add("pageSize",100) }

Cheers!

Micke-K avatar Mar 07 '22 08:03 Micke-K

Oh ... version 3.4? I used only the download button what might not download 3.4. but 3.2.3

How can I grab all new files? I'm not so familiar to github to be honest.

Phoenix-DH avatar Mar 07 '22 08:03 Phoenix-DH

Ah sorry, that is me being confusing :)

I don't like creating a release until I know it is ok. I think I must change my whole release process...

You can download the master directly. Go to the code page and click Code and then Download Zip

https://github.com/Micke-K/IntuneManagement/archive/refs/heads/master.zip

Micke-K avatar Mar 07 '22 08:03 Micke-K

Hey Micke,

I successfully tested the "load all" and "load more" buttons, and it works perfectly. The "load more" was paging in a 1000 item step, and "load all" has got all items as before 👍

After it loaded the first 1000 records I filled a search criteria for a specific item in the filter. As designed the filter is only able to select "loaded" records. It would be really helpful to have an additional "search", or load by "filter", be able to "load" only direct required items.

Greetings Andi

Am Mo., 7. März 2022 um 09:02 Uhr schrieb Mikael Karlsson < @.***>:

Sorry, I had pageSize at 100 in my original test. It should be at row 489. At least in version 3.4.0.

if($SinglePage -eq $true) { #Use default page size or use below for a specific page size for testing #$params.Add("pageSize",100) }

Cheers!

— Reply to this email directly, view it on GitHub https://github.com/Micke-K/IntuneManagement/issues/28#issuecomment-1060291194, or unsubscribe https://github.com/notifications/unsubscribe-auth/AS3B2K2Z6EIAT4GTWX4YZRLU6WZYLANCNFSM5EWKLWDQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

ASMailer avatar Mar 07 '22 09:03 ASMailer

Works alsom for me now.

Phoenix-DH avatar Mar 07 '22 11:03 Phoenix-DH

Thank you both for testing and reporting back!

I've been thinking about the search. Not sure how to implement it in the best way though. I do agree that it would be best if search/filter generates a new API query. That would probably require some re-write of the list APIs.

Cheers!

Micke-K avatar Mar 07 '22 12:03 Micke-K

You can filter "better" in 3.5.0. If you specify a filter and press Refresh, it will only load applications based on the filter.

Have a try and let me know how it goes

Micke-K avatar Apr 26 '22 11:04 Micke-K

Will try ...

But means that I now have not to change the code again after downloading 3.5.0?

Phoenix-DH avatar Apr 26 '22 12:04 Phoenix-DH

At least not until the next version is released :)

Micke-K avatar Apr 26 '22 12:04 Micke-K

Wow, cool, yes sure i will try it out 👍🏻

Mikael Karlsson @.***> schrieb am Di., 26. Apr. 2022, 13:57:

You can filter "better" in 3.5.0. If you specify a filter and press Refresh, it will only load applications based on the filter.

Have a try and let me know how it goes

— Reply to this email directly, view it on GitHub https://github.com/Micke-K/IntuneManagement/issues/28#issuecomment-1109705181, or unsubscribe https://github.com/notifications/unsubscribe-auth/AS3B2K6VRK3B4OPRYGZU3W3VG7K3FANCNFSM5EWKLWDQ . You are receiving this because you authored the thread.Message ID: @.***>

ASMailer avatar Apr 26 '22 14:04 ASMailer

Closing this. Please open a new Issue if it is not working as intended.

Cheers!

Micke-K avatar Sep 10 '22 05:09 Micke-K