0
ZIMMER TWINS – D4.6 to D6<br /><ul><li>Ashok Modi
August 9, 2009
http://www.zimmertwins.com</li></li></ul><li>AGENDA<br /><ul><li>Introduction
About Zimmer Twins
Why Upgrade?
Why Drupal 6.X?
Upgrading the Site</li></li></ul><li>INTRODUCTION<br /><ul><li>About zinc Roe Design
Based in Toronto.
Make websites (and web games) aimed primarily at youth and non-profits.
Site at http://www.zincroe.com
About me (BTMash)
Systems programmer.
Work at California Institute of the Arts.
Primarily help with patches and upgrades for contrib modules on d.o.</li></li></ul><li>ABOUT ZIMMER TWINS<br /><ul><li>ZT ...
The show provides a starting story line….
And kids create an ending
Best videos are given production value and broadcast on television
ZT was entering its 3rd season
It is currently shown in Canada-Tele-Toon, USA-NBC/Qubo, & Australia-ABC
Over 500, 000 members
Over 1.2 million user contributed nodes (or movie clips)
Over 1.1 million comments
Want to add new features to the site.</li></li></ul><li>WHY UPGRADE THE SITE?<br />New Features<br /><ul><li>Award partici...
Award badges based on total number of points
Create contests where users could vote on best content chosen by site editors
Improve workflow for switching homepage animations
Change method for choosing crowd pleaser movies.</li></ul>Better security<br /><ul><li>Current version of drupal unsupport...
Fairly easy to spam.
Did not know of exploits until too late.</li></li></ul><li>WHY UPGRADE THE SITE? CONT’D<br />Use work from community<br />...
Upcoming SlideShare
Loading in...5
×

Zimmertwins Presentation

1,207

Published on

Published in: Education, Travel, Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
1,207
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
1
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • Show homepage animation changer
  • (show sheet)
  • Transcript of "Zimmertwins Presentation"

    1. 1. ZIMMER TWINS – D4.6 to D6<br /><ul><li>Ashok Modi
    2. 2. August 9, 2009
    3. 3. http://www.zimmertwins.com</li></li></ul><li>AGENDA<br /><ul><li>Introduction
    4. 4. About Zimmer Twins
    5. 5. Why Upgrade?
    6. 6. Why Drupal 6.X?
    7. 7. Upgrading the Site</li></li></ul><li>INTRODUCTION<br /><ul><li>About zinc Roe Design
    8. 8. Based in Toronto.
    9. 9. Make websites (and web games) aimed primarily at youth and non-profits.
    10. 10. Site at http://www.zincroe.com
    11. 11. About me (BTMash)
    12. 12. Systems programmer.
    13. 13. Work at California Institute of the Arts.
    14. 14. Primarily help with patches and upgrades for contrib modules on d.o.</li></li></ul><li>ABOUT ZIMMER TWINS<br /><ul><li>ZT was created in 2005 as a show on Tele-Toon
    15. 15. The show provides a starting story line….
    16. 16. And kids create an ending
    17. 17. Best videos are given production value and broadcast on television
    18. 18. ZT was entering its 3rd season
    19. 19. It is currently shown in Canada-Tele-Toon, USA-NBC/Qubo, & Australia-ABC
    20. 20. Over 500, 000 members
    21. 21. Over 1.2 million user contributed nodes (or movie clips)
    22. 22. Over 1.1 million comments
    23. 23. Want to add new features to the site.</li></li></ul><li>WHY UPGRADE THE SITE?<br />New Features<br /><ul><li>Award participation points
    24. 24. Award badges based on total number of points
    25. 25. Create contests where users could vote on best content chosen by site editors
    26. 26. Improve workflow for switching homepage animations
    27. 27. Change method for choosing crowd pleaser movies.</li></ul>Better security<br /><ul><li>Current version of drupal unsupported on drupal.org (last update was in January, 2007!)
    28. 28. Fairly easy to spam.
    29. 29. Did not know of exploits until too late.</li></li></ul><li>WHY UPGRADE THE SITE? CONT’D<br />Use work from community<br /><ul><li>Nearly all modules (core and custom) were maintained internally
    30. 30. Modules that were from community were no longer supported (and in case of our newsletters, had broken throttling mechanisms)
    31. 31. Easier to build on work done by community to reach the goal.
    32. 32. Drupal core has improved by leaps and bounds.
    33. 33. Drupal community also grown by leaps and bounds (many excellent modules)</li></li></ul><li>WHY DRUPAL 6?<br /><ul><li>Any Drupal version would have required a lot of work
    34. 34. Upgrade path in D4.7, D5, and D6 were equally large so to narrow down which to use…</li></ul>D4.7 - was older (security issues, better, and custom modules were needed)<br />D5 - had gained a lot of support from the community<br />D6 - number of enhancements:<br /><ul><li>Memory management
    35. 35. Theme registry (use theme devel module to figure out override theme calls/templates which was very useful)
    36. 36. Views and CCK (moreso CCK) were not necessary for our site at that time (Views would be helpful but main modules would still require lots of work)
    37. 37. Finally, we wanted to get ourselves familiar with D6 so the site upgrade was a good opportunity to see what it can do!</li></li></ul><li>BIG Q!<br />HOW DID WE UPGRADE THE SITE?<br />
    38. 38. UPGRADING SITE CONT’D<br />Strip Down:<br /><ul><li>Contributed modules and themes that is…
    39. 39. The old code was not going to work so you don’t want something enabled that might cause some funny behaviour
    40. 40. See how much change is necessary in the database from D4.6 to D6</li></ul>Upgrade the database<br /><ul><li>Upgrade from 4.6 to 4.7, then from 4.7 to 5, and finally from 5 to 6
    41. 41. Upgrades build on top of old versions
    42. 42. Safest way to ensure core data is safely upgraded and accounted for</li></ul>Steps 1 & 2 took approximately 2 weeks to iron out other steps in process <br />
    43. 43. UPGRADING SITE CONT’D<br />Development:<br /><ul><li>Once data upgrades were completed gracefully (the ungraceful parts will be mentioned near the end)
    44. 44. See which modules can be used from d.o, what contributed modules needed to be upgraded, and which ones would be custom modules
    45. 45. Ongoing process as more modules were actively upgraded by rest of community
    46. 46. Started by upgrading / creating the smaller sets of modules
    47. 47. Modules that didn’t rely on the movie saving / creation.
    48. 48. Quick to create functionality that didn’t yet rely on look / feel.</li></li></ul><li>UPGRADING SITE CONT’D<br /><ul><li>Old site:</li></ul>-about -abuse -bad words<br />-block -blog -cache exclusion<br />-extras -favourites -filter<br />-flexiblock -help -legal<br />-locale -menu -movie<br />-node -page -path<br />-rating -search -send to friend<br />-site stats -sponsor -statistics<br />-story -subscription -system<br />-telepicks -user -watchdog<br />-watchlist -taxonomy -phplist<br /><ul><li>Fairly small list but keep in mind D4.6 was unsupported & most of these weren’t available on Drupal.org
    49. 49. We had to customize, develop and maintain these ourselves</li></li></ul><li>UPGRADING SITE CONT’D<br />Converting smaller custom modules:<br /><ul><li>sendtoafriend
    50. 50. sponsor
    51. 51. site_statistics (custom zimmertwins stats)
    52. 52. about & extras converted into pages</li></ul>Converting larger custom modules:<br /><ul><li>Core movie module with frontpage animation settings, movieclipnodetype, and moviestarternodetype
    53. 53. Moviepicks (select additional status for movies)
    54. 54. movie_search module (converted to module so we can disable in case of large load on site)
    55. 55. abuse
    56. 56. watchlist
    57. 57. sponsor</li></li></ul><li>UPGRADING SITE CONT’D<br />Notable Improvements:<br /><ul><li>very easy for theme developer to override series of my un-designed templates
    58. 58. Easy to override core modules (override user module)
    59. 59. Adding AJAX (AHAH) functionality was simple (abuse module uses jquery and ahah for moderating content on site)
    60. 60. Use drupal_system_listing(directory_path) and drupal_parse_info_file($file) to create your own set of custom drupal files to parse for specific settings!</li></li></ul><li>UPGRADING SITE CONT’D<br />Contributed modules<br /><ul><li>Google analytics
    61. 61. Userpoints
    62. 62. Userpoints basic
    63. 63. User badges
    64. 64. Cache exclude
    65. 65. Legal
    66. 66. Login toboggan
    67. 67. Login destination
    68. 68. Favorite_node</li></li></ul><li>UPGRADING SITE CONT’D<br />More contributed modules<br /><ul><li>Votingapi
    69. 69. Very flexible (can be used for more than simple ratings)
    70. 70. Hooks to use for other stats
    71. 71. Fivestar
    72. 72. Messaging
    73. 73. Frameworks
    74. 74. Token
    75. 75. Simplenews</li></li></ul><li>UPGRADING SITE CONT’D<br /><ul><li>Influence of Drupal conference:
    76. 76. Midway through development timeline, attended Boston Drupal conference.
    77. 77. Attended a seminar on messaging and notification frameworks
    78. 78. Goal was to create module and api to get rid of the 100+ modules that provided bits and pieces of such functionality
    79. 79. Opted to use framework over building own large module to perform same functionality
    80. 80. Created module (comment_notifications) to email user when comment added to their node.
    81. 81. We were able to get back email news letter functionality through a module called simplenewsand ‘pretty’ emails via small modifications to the mimemail module (which has now been properly upgraded by the maintainer – need to upgrade our module)</li></li></ul><li>UPGRADING SITE CONT’D<br /><ul><li>Using Form Alter Hook – userpoints_badges:
    82. 82. Userpoints& user badge modules
    83. 83. Userpoints has api and hooks to create additional rules on when to award points
    84. 84. Userbadges can award badges either to roles or to single user (though single user addition has to be either manually or through rules
    85. 85. Created a bridge module that alters user badges form
    86. 86. Contains extra field where you can specify minimum number of points to get badge (leave blank or 0 to discard check)</li></li></ul><li>UPGRADING SITE CONT’D<br /><ul><li>Using form alter hook – node_css:
    87. 87. Needed functionality to provide extra css info for a particular node (so our ‘credits’ page could take on extra css rules)
    88. 88. Felt providing an ID for a given node was the easiest way to go.
    89. 89. Module allowed you to create a specific id for a given node (altered node form to add a css id)
    90. 90. With this could create additional design particular to one type of page or a series of pages with that particular id</li></li></ul><li>UPGRADING SITE CONT’D<br />Custom modules<br /><ul><li>Movie userpoints voting module:
    91. 91. Votingapi hook implements check to give movie a ‘crowd-pleaser’ status if it meets requirements in total ratings and average rating.
    92. 92. Awards extra userpoints to users on positive change in movie status
    93. 93. Comment_spam_control
    94. 94. Throttles number of comments an authenticated user can post (1 per minute…which stopped them from spamming a user to watch their movie)
    95. 95. Comment_list
    96. 96. Provides a strict list of comments a user select to post from.</li></li></ul><li>UPGRADING SITE CONT’D<br />Custom modules<br /><ul><li>Contest
    97. 97. Allow users to vote on a particular movie
    98. 98. Vote as many times as a user wants during the contest (free-for-all)
    99. 99. View current tally of votes (or black out for regular users)
    100. 100. Refresh page with random set of contestants after vote (using ahah functionality)
    101. 101. Can choose if contest should be based around users or nodes and admins enter the uid/nid of the content they want as part of contest.
    102. 102. Module wasn’t around at time (currently versus and another module named contest have been contributed – came out around same time we finished work on this module)</li></li></ul><li>UPGRADING SITE CONT’D<br /><ul><li>Modules for D6X:</li></ul>-abuse -watchlist -blog<br />-comment -contact -help<br />-locale -menu -path<br />-php filter -search -statistics<br />-taxonomy-update status -upload<br />-block -filter -node_css<br />-system -user -mime mail<br />-simplenews-simple mail -comment notification<br />-notifications -cache exclude -comments spam control<br />-googleanalytics -legal -login destination<br />-login toboggan -token-userpoints<br />-user points basic -user points-userpoints badges<br />-fivestar -voting API -contest<br />-favourite_node -movie -moviepicks<br />-movie pics voting user points -movie search -node css<br />-send to a friend -site statistics -sponsor<br />-messaging -user badges<br />
    103. 103. END of Talk on Modules!!!<br />
    104. 104. UPGRADING SITE CONT’D<br /><ul><li>Hurdles
    105. 105. Migrating data
    106. 106. Site was under latin1 encoding
    107. 107. Drupal 5+ moved towards utf-8 encoding
    108. 108. Tough due to size of data.
    109. 109. Strip out character encoding of file created from mysqldump (so characters are not saved in utf8 format and garbled.
    110. 110. Replace instances of latin1 with utf8
    111. 111. Ensure content will migrate to database in utf8 format
    112. 112. run perl -pi -w -e 's/latin1/utf8/g;' <sqldumpfile>
    113. 113. 90% of issue was resolved</li></li></ul><li>UPGRADING SITE CONT’D<br /><ul><li>Hurdles
    114. 114. Issue with users table and usernames
    115. 115. In utf8,eva seen to be equal to éva so users who had ‘duplicate’ names would not be inserted into the database
    116. 116. Login was painfully slow
    117. 117. Usernames entered by user were compared with lowercase version of all names on site – check in mysql alone took nearly 3 seconds.
    118. 118. Choices
    119. 119. Keep table in latin1 encoding and deal with character encoding discrepancies
    120. 120. Keep name column in utf8-binary encoding (so eva is not same as éva but deal with slow login.
    121. 121. Opted for the latter
    122. 122. Found issue on d.o dealing with slow login (http://drupal.org/node/83738)
    123. 123. Login much faster now </li></li></ul><li>UPGRADING SITE CONT’D<br /><ul><li>Actual upgrade of site:
    124. 124. Tested out ability to upgrade site multiple times
    125. 125. Large dataset
    126. 126. Needed to document full upgrade path.
    127. 127. Created a migration script so data from deprecated modules (about, extras, favourites and more) would migrate over to the new in-use module (page, favourite_node, etc)
    128. 128. Needed to see time to complete upgrade.
    129. 129. Took approximately 18 hours to fully upgrade the site. </li></li></ul><li>UPGRADING SITE CONT’D<br /><ul><li>Things We Learnt
    130. 130. Ensure new site is under correct encoding or you'll pull your hair out!!!
    131. 131. Don't always go for the latest and greatest
    132. 132. many modules had not been ported over to D6 when we started on the project--as an easy example, no views or cck at the time.
    133. 133. That said…was a great opportunity for us to help out with upgrading the modules.
    134. 134. Use the Drupal overrides to your advantage.
    135. 135. Take advantage of drupal’s multisite
    136. 136. Previously all modules were in core module directory, site structure was in such a way that zimmertwinsaustralia and zimmertwins USA had to run from separate directories
    137. 137. Now fixed so lower memory usage
    138. 138. Don’t call contributed module functions from a theme (or atleast don’t call them unless you check the the particular module is enabled).</li></li></ul><li>UPGRADING SITE CONT’D<br /><ul><li>Things as they are now
    139. 139. Site performs very well under load
    140. 140. Maintenance on modules is easier (even though there are now 55 modules versus 31, actively maintaining at most 15 modules as opposed to over 20)
    141. 141. Newsletters actually work
    142. 142. Recently sent out approx 150k email newsletters without any glitches
    143. 143. Recently upgraded the Australian version of the ZT site to D6 as well
    144. 144. Upgrading the theme and testing took a little over 1 week and running through the migration took a little over 4 hours.</li></li></ul><li>UPGRADING SITE CONT’D<br /><ul><li>Planning for future
    145. 145. Integration with views
    146. 146. Look into search technologies (sphinx, lucene) and possible ways to using it on site
    147. 147. Caching via memcached/apc/files/??? (cacherouter)</li></li></ul><li>Questions for Discussion?Thank you!!!<br />
    1. A particular slide catching your eye?

      Clipping is a handy way to collect important slides you want to go back to later.

    ×