[Discussion] AppServiceConnection lifecycle question
@gave92, I am seeing an intermittent issue with cloud drive detection when two app service connections are created and called at almost the same time. From what I can see, the first instance of FilesFullTrust launches, and a second is then launched followed by the process ending and no results coming back to the second callee.
Looking around and I have seen examples of implementing the full trust model where a single instance of the full trust process is launched at startup, and left open to handle all future requests.
I have tried to implement this, but found the full trust process is being terminated by being sent a "Terminate" command. The only place I see this being done from is StartupTask which appears to handle multiple background startup tasks, and specifically terminates AppServiceConnection's when a background task is cancelled.
Is there a particular reason or issue for launching a new process every time a new app service connection is needed?
I addressed this in my PR related to network shares. I took your suggestion of having a single connection per app instance :)
@gave92, that looks great. Do you know when that PR will be merged?
I think I have worked around the duplication issue on the sidebar but I don't want to throw these changes in to the mix when you are working on most of the same files.
@AndyMDoyle I won't be able to work on that for a week. So you can go ahead and do anything. If you wish you're free to take anything from that PR (those changes don't really belong to that PR anyway) 👍