FluidFramework icon indicating copy to clipboard operation
FluidFramework copied to clipboard

Code upgrade flow is broken

Open alpaix opened this issue 5 years ago • 3 comments

Our code upgrade flow implies each code proposal represents a code constraint the code loader should satisfy when matching an actual runtime module to get loaded by the container. In reality, the container uses the older cached constraint rather then actual loaded module capability when processing the new code proposal to determine whether the container should be terminated. code-propose-min

Consider refactoring the container/context behavior to unblock the code upgrade scenario. The change proposed in #5012 can contribute to the solution.

alpaix avatar May 27 '21 01:05 alpaix

@arinwt , @anthony-murphy - please triage

vladsud avatar May 27 '21 02:05 vladsud

The current sliding window requires full back compat, such that v2.0 always satisfies v1.0. The expectation is that the client who is upgrading to v2.0 loads that version, then issues the code proposal to upgrade, thus kicking out the 1.0 clients.

We have #5012 filed. As part of this on load of v2.0 package the context will know it is v2.0. Currently the code loader itself need to track this mapping by knowing that when the loader asked for v1.0, it gave it v2.0, which is valid as v2.0 statifies v1.0 The next extension of this is automatically propose code in this scenario. Ideally, we would block loading of v2.0 until the proposal is accepted in this case

I agree there are gaps, and current implementation is incomplete, but it works for the scenarios it was needed for. I’d rather us focus on how to improve it, as it is a difficult space to get right. is there a specific scenario that needs investment here?

anthony-murphy avatar May 27 '21 16:05 anthony-murphy

Fixed with #6394

alpaix avatar Jun 30 '21 02:06 alpaix