| Summary: | [ui] ProvisioningOperationWizard will not use ProfileChangeOperation | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] Equinox | Reporter: | Matthew Piggott <matthew> | ||||||
| Component: | p2 | Assignee: | Matthew Piggott <matthew> | ||||||
| Status: | RESOLVED FIXED | QA Contact: | |||||||
| Severity: | normal | ||||||||
| Priority: | P3 | CC: | irbull, pascal, susan | ||||||
| Version: | 3.7 | ||||||||
| Target Milestone: | 3.7 RC1 | ||||||||
| Hardware: | All | ||||||||
| OS: | All | ||||||||
| Whiteboard: | |||||||||
| Attachments: |
|
||||||||
|
Description
Matthew Piggott
Created attachment 188089 [details]
TestCase
This test case is fairly simple, I've created a useless subclass of InstallOperation and the operation on the second page of the wizard is no longer of that type.
In my usecase I have a subclass of an InstallOperation which sets the restart policy of the provisioning job. However, I believe this would also be an issue for users who expect their InstallOperation to use a specified ProvisioningContext (ie with some set of repos).
This surprises me because I know we have update cases where we compute the updates and preserve them in the wizard, but this is probably on the first page. Can we not just initialize the provisioning context to the one from the operation as a fix? Also, I don't think you should assume that the operation would never change in the wizard (ie, if the user changes selections, or decides to contact all sites, or something that might change the resolution). Since these classes are internal we've not really been formal about the lifecycle, we've just done what works for the SDK. So if you need that to happen, then that is a new feature. But I agree that if nothing has changed, we shouldn't have to resolve again. Matt could you please work on a patch? Created attachment 188261 [details]
Use ProvisioningContext from ProfileChangeOperation
I believe this should fix the issue for recomputing the plan.
There are a few small changes:
- ProvisioningOperationWizard constructor sets the ProvisioningContext to that of the operation (if not null)
- ProvisioningOperationWizard getProvisioningContext returns the context of the operation, or creates a new one
- UpdateWizard getProfileChangeOperation no longer sets the ProvisioningContext (this was unnecessary as recomputePlan also sets it)
Matt, are you still working on this? I've released the patch. |