I need to run Exchange online cmdlets using powershell classes in C#.
To run exchange online cmdlets i need to establish a remote powershell session.
My doubts are: 1) If runspacepool size is 2, should i create that remote powershell session in both the runspaces in that runspacepool? If yes, how can I / Is there a way to loop through the runspaces to run the New-PSSession command in both the runspaces.
2) If session expires in ONE runspace, is there a way to get that particular runspace from the runspacepool, and create new session that runspace alone?