microsoft / coe-starter-kit

Other
755 stars 225 forks source link

[CoE Starter Kit - BUG] Orphaned Object notification when user is still with the business #9021

Closed Alyson95170 closed 1 month ago

Alyson95170 commented 1 month ago

Does this bug already exist in our backlog?

Describe the issue

Hi, we currently have the Request Orphaned Objects Reassigned Parent and Child switched on. I have noticed on the last run there was a notification sent to a manger when their employee has not left the company. On checking the Admin view app the Solution Associated view is empty but within the Power Automate this is showing as Project. Do you know what be causing this to show as orphaned when it is not, is it anything to do with Project for the Web? Should these be excluded from inventory?

Expected Behavior

Not to send notifications to managers when their employees are not orphaned

What solution are you experiencing the issue with?

Audit Log

What solution version are you using?

3.25

What app or flow are you having the issue with?

Request Orphaned Objects Reassigned

What method are you using to get inventory and telemetry?

Cloud flows

Steps To Reproduce

No response

Anything else?

No response

Jenefer-Monroe commented 1 month ago

Hello sorry I'm having trouble following your question. What do you mean by this? Can you share a screenshot? image

Alyson95170 commented 1 month ago

Hi Jennefer, so the maker is still with the company image The Power Platform Solution is empty image but within the flow this is showing image I am just trying to understand why I have 2 Power Automates showing as Orphaned when the user is still with the company. Thanks

Jenefer-Monroe commented 1 month ago

Are they listed as the Derived Owner here? image

Alyson95170 commented 1 month ago

Yeah they are.

Jenefer-Monroe commented 1 month ago

Few more questions:

  1. In entra, is this user enabled or disabled?
  2. What do you have for this env var? image
  3. Has the following flow been running and passing? CLEANUP - Admin | Sync Template v3 (Orphaned Makers)
Alyson95170 commented 1 month ago

Hi Jenefer The user in entra is enabled. Env variable is image CLEANUP - Admin | Sync Template v3 (Orphaned Makers) has run successfully I have checked the makers table and the user is not showing as orphaned or system image

It just seems to be 2 flows that are showing as orphaned for this user, which is making me think it could be related to Project for the web, the flow trigger is Dataverse and the table name is msdyn_operationset.

Jenefer-Monroe commented 1 month ago

Can you run the following flow for the two repro flows? You'll need the Flow and Envt ID. Let me know if it passes and if it changes the value for derived owner and/or orphan image

Alyson95170 commented 1 month ago

This ran successfully, derived owner is still the same and flow still showing as orphaned.

Jenefer-Monroe commented 1 month ago

In the most recent run of CLEANUP - Admin | Sync Template v3 (Orphaned Makers) Find the user index in the output of List Makers and then go into the apply to each for them. What do you see for the output of Get Maker image

Alyson95170 commented 1 month ago

image

Jenefer-Monroe commented 1 month ago

Great its being identified as not orphan. In the next run of the flow then I would expect these two flows to get picked up here and marked as no longer orphan Can you please see if that happens on the next run of this flow? image

shanemeisnerdhg commented 1 month ago

We noticed this same issue with the first run after the upgrade to September release. Had many Managers reach out asking why they received this report when in fact the person was still employed.

I'll watch next weeks run and see if it resolves.

Alyson95170 commented 1 month ago

Thanks Jenefer, our next run will be next week. I will check this and confirm.

Alyson95170 commented 1 month ago

Morning Jenefer I have ran CLEANUP - Admin | Sync Template v3 (Orphaned Makers) and CLEANUP - Admin | Sync Template v3 (Orphaned Users). The Derived Owner column is correct but the Flow is Orphaned is = to Yes. The user has 206 flows showing within the admin centre and only 2 of them are marked as orphaned. I have excused flows from inventory to stop their manager receiving the notification about orphaned objects. Is there anything else I should check?

Jenefer-Monroe commented 1 month ago

Please go into the run of orphaned makers that completed. Are the flows returned in List flows no longer oprhaned? If so what happens in the apply to each that follows? image

Alyson95170 commented 1 month ago

It is finding the 2 flows image Orphaned is set to no image

But this is not updating in the table image

Jenefer-Monroe commented 1 month ago

OK there is something very odd happening. Its writing to the table which is where I thought the bug was

Can you please confirm

Alyson95170 commented 1 month ago

Hi Jenefer, I have checked this morning and the issue has resolved, It has identified the 2 orphaned flows image and marked them as No image I ran CLEANUP - Admin | Sync Template v3 (Orphaned Makers) on the 30th and it has also ran again this morning, so looks like it was not picked up correctly on the first run. Thanks for your help with this.

Jenefer-Monroe commented 1 month ago

oh wonderful. This was really bothered me so I'm glad it resolved! Thanks for sticking with it!

Jenefer-Monroe commented 1 month ago

closing out as no further action for starter kit team