Is simply shutting down the PowerShell console an effective way of disposing of SharePoint objects?
Thanks for drawing out that distinction, Hugh. I appreciate your time and expertise.
You use it when you want to run long running PowerShell that uses disposable objects like SPWeb. It’s automatic for the powershell session but it doesn’t stop the owsvr caching that occurs with solutions. For this powershell still needs to be restarted.
What if you aren’t making any changes to the objects? When do you use SPAssignmentCollection?
If any changes to anything linked to the object are made after it was opened then the object is no longer valid.
What about using SPAssignmentCollection? When is it appropriate to use this over simply closing out of the current PowerShell session?