21 Aug, 2015

1 commit


13 Aug, 2015

2 commits


12 Aug, 2015

1 commit


11 Aug, 2015

2 commits


10 Aug, 2015

1 commit


27 Jul, 2015

2 commits


25 Jul, 2015

1 commit


24 Jul, 2015

1 commit


22 Jul, 2015

2 commits


12 Jul, 2015

2 commits


08 Jul, 2015

2 commits


03 Jul, 2015

1 commit


25 Jun, 2015

1 commit


17 Jun, 2015

9 commits


16 Jun, 2015

4 commits


15 Jun, 2015

3 commits


12 Jun, 2015

2 commits


11 Jun, 2015

2 commits

  • See merge request !563
    Larissa Reis
     
  • Whenever you have 2 or more tags with the same name but different cases,
    ActsAsTaggableOn returns an empty list of objects tagged with either of
    the tags. To solve this problem, we must not have tags with different
    cases stored.
    
    Performance was my primal concern on this migration since we have
    instances that have over 130k tags registered. So I decided to convert
    every tag to lower case.  This is the fastest way I could conceive this
    migration and still it might take a lot of time. Here is basic resume of
    what it basically does:
    
      x: number of new downcased tags created.
      y: number of oddcased tags.
      z: number of tags
    
      1. Find all tags do not have a downcased form already created - [1 fast select query].
      2. Create a downcased version of the above queries - [x slow update queries but
      n is usually low because a minority of tags have odd case and all
      different cases of a single word generate only 1 query].
      3. Update taggings relations based on new ids - [1 slow update and 2 join queries].
      4. Updates the taggings_count of every tag - [1 slow update with z fast selects]
      5. Delete all unused tags tags - [1 slow delete query].
    
    Signed-off-by: Larissa Reis <larissa@colivre.coop.br>
    Rodrigo Souto
     

10 Jun, 2015

1 commit