You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Enhance stream creation to not require a manually ordered list
The Problem: Streams creation is currently a bit of a hassle, because you cannot just provide a list of streams you want imported in the yaml file. Presently, if the user provides the list of streams in an arbitrary order, stream generation will fail on the first stream that doesn't have a parent already created.
Given a list of streams to be created, P4Transfer should create all desired streams without the user having to provide streams in the correct order based on stream parenting relationships.
Two possible approaches:
Just run the stream creation for several passes, stopping when there are no errors in stream creation (or if a max number of passes have been attempted. On each pass, streams that have no parents (mainlines) and streams with existing clients will succeed, others will fail -- ignore the expected failures and keep iterating; each pass will create parents of other streams until eventually all streams can be created. One pass per level of stream depth is necessary, but calculating stream depth from a set of streams requires effort, so just going until all streams are successfully created or we hit an arbitrary limit (25) is easy and effective. (This technique has been proven in bash shell scripts).
Get elegant and build an internal representation of the stream hierarchy, and add streams in proper order, starting with mainlines and following the parenting relationships to create terminal nodes last.
The text was updated successfully, but these errors were encountered:
Enhance stream creation to not require a manually ordered list
The Problem: Streams creation is currently a bit of a hassle, because you cannot just provide a list of streams you want imported in the yaml file. Presently, if the user provides the list of streams in an arbitrary order, stream generation will fail on the first stream that doesn't have a parent already created.
Given a list of streams to be created, P4Transfer should create all desired streams without the user having to provide streams in the correct order based on stream parenting relationships.
Two possible approaches:
The text was updated successfully, but these errors were encountered: