Closed (fixed)
Project:
Openlayers
Version:
6.x-2.x-dev
Component:
OpenLayers UI
Priority:
Normal
Category:
Task
Assigned:
Issue tags:
Reporter:
Created:
10 Feb 2010 at 19:54 UTC
Updated:
3 Jan 2014 at 01:08 UTC
Jump to comment: Most recent
Comments
Comment #1
tmcw commentedThe upgrade path from 1.x to 2.x is by running the schema hook and manually upgrading layers and presets. Since there is a growing amount of documentation for 2.x, I think that this is reasonably clear. I'm not planning on writing the very complex code it would take to automatically do this when the majority of OpenLayers configurations are quite simple, and the 1.x branch doesn't have a huge installed base.
Patches are welcome, but for the time being this is by design, because it's stated everywhere that the upgrade path is manual but documented.
Comment #2
zzolo commentedI would very much disagree. Saying "it's manual" is not an upgrade path. This is a manual upgrade path.
I never had any expectations that you would create an upgrade path from 1.x. But I have always had plans to create an upgrade path, which involves some automatic conversions and documentation of manual changes. I have made this very clear since the beginning of 2.x.
Also, 1.x is still being worked on. It went RC1 yesterday. It'll go 1.0 soon and be done.
Comment #3
zzolo commentedWe also want to note API changes. Note some of this may be out of date (taking it form the advance_help)
Hooks
1.x:
2.x:
Major API
1.x:
2.x:
Theming
1.x:
2.x:
Comment #4
zzolo commentedCompare the map arrays/objects to note changes.
1.x:
2.x:
Comment #5
zzolo commentedhttp://drupal.org/cvs?commit=328688
Put in initial automatic upgrade parts for the 1.x to 2.x upgrade. There's a fair amount of the map array that can be automated; of course we can only automate the things that are in the DB:
* General map properties
* Named layers
* (not in yet) but can save layer arrays if they are in the preset.
* Most of the behaviors can be transfer
* Styles can be (but still needs some work)
Major parts of the map presets that could use some work to have a smooth upgrade process:
* Vectors
* Features
* Behaviors (Cluster, Zoom to Feature, Tooltip, Draw Features, Declutter)
The next step which I will start right now is to make a D.o page describing the process. (Also, I am going to make a quick blog entry on how I set things up to easily test an upgrade.)
Comment #6
zzolo commentedBeginning of doc page: http://drupal.org/node/714366
Still needs work and better formatting.
Note that this ticket won't be fixed until 2.x is stable and we have agreed there will not be any API or data structure changes.
Comment #7
alex_b commentedJust upgraded 0.x->2.x upgrade with latest OL 2.x head and found that the 1.x->2.x upgrade executes and, of course, causes errors:
http://skitch.com/alexbarth/nikui/drupal-database-update-managing-news
- Via SQL terminal I verified that my previous schema version of the 0.x OL installation was as expected 6002.
- However drupal_get_installed_schema_version('openlayers'); in openlayers_update_6200() returns 6199 instead of the expected 6002.
This is a peculiar behavior of the update system. Requires more research on how to fix it/circumvent it. For the time being, can we remove the 1.x->2.x upgrade path until we've sorted out how it won't break 0.x ?
Comment #8
alex_b commentedPlace to start reading: update_batch() in update.php. I see a
drupal_set_installed_schema_version($module, $version - 1);in there :(Comment #9
zzolo commented@alex_b I think this is what Will was talking about in the other ticket. This seems like really silly behavior in Drupal.
Anyway, I am just going to go with the variable method, where we set something in the 1.x branch that we can manually test for in the upgrade; this is the simplest method. I should be able to address this tonight.
Comment #10
alex_b commentedYes - I just talked to Will about that. This behavior was not on my radar :\
That would be *great*. I am planning on a Managing News release tomorrow morning...
Comment #11
zzolo commentedAdded variables to hook_update_6100 and hook_enable in 1.x:
http://drupal.org/cvs?commit=329134
Comment #12
zzolo commentedChanged logic in 2.x install file to use Drupal variable. I have tested with 1.x to 2.x upgrade but not with 0.x:
http://drupal.org/cvs?commit=329138
Comment #13
alex_b commentedI can confirm that 0.x -> 2.x upgrade is working fine - i. e. 1.x -> 2.x upgrade code is not being executed.
How are we looking for a 2.x alpha 2 release? Would be good to get the broken code off the project page.
Comment #14
zzolo commentedI personally have no problem with an alpha2, but would want to discuss more before a beta. I can do this real quick like.
Comment #15
zzolo commentedhttp://drupal.org/node/715384
Should show up in about 10 minutes.
Comment #16
alex_b commentedzzolo: thanks!
Comment #17
tmcw commentedIs this fixed, or are there other tasks remaining here?
Comment #18
zzolo commentedYeah, I need to look at some more. Should be able to get to it this weekend.
Comment #19
tmcw commentedIs there continuing work on this ticket, for making automatic transitions from one version to the next?
Comment #20
zzolo commentedI've just been waiting for other changes to get it and things become stable. I don't want to put in too much time when things are still subject to change. Will try to address soon.
Comment #21
tmcw commentedThe APIs are stable except for behaviors at this point, you can count on the rest, I think.
Comment #22
zzolo commentedUpdating documentation to explain that Views will have to be manually upgraded as there is no way to automate the huge structural changes that have been made.
http://drupal.org/node/714366
I will still need to look at CCK. I would assume there is a way to upgrade things automatically.
Comment #23
tmcw commentedI think that we can mark this as very much fixed. The ticket is incredibly stale and this is no longer a hot topic or serious need for most users.
Comment #24
zzolo commentedI would like to keep this open until we at least have a beta as an upgrade path is not stable until then. I think the main thing that needs to get done here is the CCK stuff, which might actually already work, I just havent tested it out yet.
Comment #25
zzolo commentedtagged as beta blocker
Comment #26
zzolo commentedAlright, looked over CCK stuff. The WKT formats are different, but can still be handled fine in the 2.x version. Closing 'er down. Just to reiterate, documentation for upgrading from 1.x to 2.x here:
Upgrading OpenLayers 1.x to 2.x
Comment #27
tmcw commentedGreat, thanks for finishing this.