#amara

/

      • bendk
        2) is there a good way for me to look at the webstats and see what API calls people have been using?
      • nicholasreville: ^^ this means that when we do the metadata code, it's just a delpoy no migrations needed and not much downtime
      • daughter is crying going to take her for a walk, but I'll be back soon
      • nicholasreville
        bendk: sounds good
      • janeted1 joined the channel
      • janeted has quit
      • thurloat has quit
      • thurloat joined the channel
      • janeted1 has quit
      • janeted joined the channel
      • deanjansen joined the channel
      • ehazlett
        all: back but internet is a little wonky
      • bendk: migrations finished but still crashed on the same duplicate key error
      • bendk: i think another migration wont hurt at this point
      • bendk: as for stats on the api i would have to collect them. we have analytics but they dont catch the api. i have to use the raw logs for that.
      • bendk
        raw logs would actually be fine
      • nicholasreville: okay can we get terri on a call to try to figure out what to do?
      • ehazlett: what's a good way for me to check out that data?
      • I want to run some sql queries on it to better understand what the issue is
      • ehazlett
        bendk: ill send you creds
      • nicholasreville
        bendk: sure
      • bendk
        ehazlett: did you send the creds?
      • deanjansen has quit
      • deanjansen joined the channel
      • deanjansen
        bendk: let us know whenever you're ready
      • bendk
        okay, give me 5 more minutes
      • ready
      • ehazlett
        bendk: sorry - notification fail - one sec
      • bendk: DM'g
      • bendk
        deanjansen: so there are a few times where the data changes, but the only thing that changed was the team_id, from TED to TED translate
      • for 3 subtitle versions
      • is it still okay to drop that data?
      • deanjansen has quit
      • deanjansen joined the channel
      • nicholasreville
        ehazlett: bendk: how are we looking on migration stuff?
      • ehazlett
        nicholasreville: bendk is looking at the database now to see the state of the DB
      • bendk
        should be done in a few minutes
      • nicholasreville
        k
      • bendk
        deanjansen: you around?
      • nicholasreville: got one part done, now wehave another issue
      • deanjansen
        bendk: hey what's up?
      • bendk
        should we only have 1 billing record per video language?
      • even if there are multiple versions on it?
      • deanjansen
        bendk: yes, that's correct
      • bendk
        ok, well that's another database constraint error
      • let me look into it more
      • janeted
        bendk: did you just skype me?
      • bendk
        yes
      • janeted
        i'm here now
      • bendk
        talking about billing again
      • janeted
        oh fun
      • ehazlett
        bendk: 0157 migrations still running...
      • nicholasreville: janeted ^ fyi... (on test)
      • michelled has quit
      • bendk
        ehazlett: how long has that been going for?
      • there's definitely a better way to implement that oen
      • one
      • ehazlett
        bendk: nicholasreville 0157 migrations still running...
      • janeted has quit
      • nicholasreville
        ehazlett: does that mean it's going well?
      • ehazlett
        nicholasreville: it means it's going :)
      • but the fact that it's not erroring is a good thing
      • deanjansen has quit
      • janeted joined the channel
      • janeted
        ehazlett: is migration 157 the last one?
      • nigel_bot
        157 - Fix widget-breaking CSS - https://unisubs.sifterapp.com/issue/157
      • ehazlett
        janeted: for the videos app yes. not sure how many others
      • deanjansen joined the channel
      • janeted
        wow - ok
      • ehazlett
        janeted: i'm guessing it's close
      • janeted
        phew - how many hrs?
      • ehazlett
        4.5 total without this one included (have to wait until it's finished to get the count)
      • deanjansen has quit
      • deanjansen1 joined the channel
      • janeted
        and no other problems after the billing stuff, ehazlett?
      • ehazlett
        janeted: so far no but we removed a bunch of data
      • bendk: done
      • bendk: nicholasreville total migration time looks like 7 hours
      • this last migration (videos 0157 took 160 minutes)
      • bendk: nicholasreville and the app at least starts and returns the index
      • bendk
        ehazlett: wow that's long
      • I'm pretty sure I can re-write some of those migrations to work faster
      • but I'm not sure if it's a good idea
      • nicholasreville: what do you think?
      • maggie_s joined the channel
      • nicholasreville
        wow, ok
      • so that's 7 hours of downtime? and how confident are we that it would work?
      • bendk: ehazlett ^
      • bendk
        I can't say
      • nicholasreville
        and nothing we can do to add raw capacity?
      • bendk
        So the other route would be that ehazlett tells me which migrations were on the slow side, then I rewrite them to make them faster
      • I think if I wrote 0157 using raw SQL, it wouldn't take very long at all
      • it's just a join and an update
      • I'm assuming the actions table has a lot of rows, but still
      • janeted has quit
      • ehazlett
        yeah not sure -- we could at least try
      • i don't want to migrate until i do this again with steps that work successfully out of the box
      • i really don't want to be manually fixing migrations during the downtime
      • bendk: nicholasreville ^
      • nicholasreville
        wellllllllllll, hmm
      • so the choice is:
      • 1. do a 7 hour downtime
      • 2. do some speedups, then do a full test of that, then do the migration
      • right?
      • ehazlett: bendk ^
      • bendk
        the other side of that is that it worked because I stepped in in the middle and ran some DB queries
      • so I can cut-n-paste them into the migration and things *should* work the same, but that's slightly risky
      • nicholasreville
        so you are saying someone needs to be watching while it goes anyway, is that right?
      • oh i see
      • bendk: roughly how much faster would it be able to get?
      • i wouldn't hold you to an estimate, just ballpark
      • bendk
        I would guess 10 minutes
      • if we had other migrations that were that long, then I think it would definitely be worth it to rewrite them
      • if it's only that one, then we have to way the time improvement with another round of testing
      • stepping away for a bit, i'll be back to check on the chat
      • ehazlett
        nicholasreville: correct
      • nicholasreville
        ehazlett: when ben says 10 minutes that means it goes from 160 minutes to 10 minutes? so it saves almost 3 hours?
      • nigel_bot
        160 - Fix Add Another Translation and Ask Friend to Translate buttons on Finished dialog - https://unisubs.sifterapp.com/issue/160
      • bendk
        that's what I think
      • ehazlett
        nicholasreville: yeah if that works
      • will save 2.5 hours
      • nicholasreville
        bendk: well, ok, let's do that
      • worst case we have to wait until tomorrow, right?
      • but 7 hours is just too much downtime i think
      • bendk
        ehazlett: I think we can change that python code to just to:
      • db.execute("UPDATE video_action va SET new_language_id = (SELECT new_language_id FROM videos_subtitlelanguage sl WHERE sl.id = va.subtitle_id)")
      • along those lines
      • pretty sure that will result in a huge speedup, but correct me if you think otherwise
      • maggie_s_ joined the channel
      • maggie_s has quit
      • ehazlett: do you know if there were other queries that took more than say, 30 minutes?
      • s/queries/migrations/
      • ehazlett
        bendk: hm
      • bendk: yeah i think that 0127 was a while
      • bendk: other than that i didn't log that close
      • DarrenBridenbeck joined the channel
      • DarrenBridenbeck
        ehazlett: ping?
      • ehazlett
        DarrenBridenbeck: hey
      • DarrenBridenbeck
        ehazlett: i know you've got a big night ahead of ya, but have you had a chance to take a look at that email?
      • ehazlett
        DarrenBridenbeck: well i'm not migrating at this point (we don't have a reproducible successful migration plan yet)
      • DarrenBridenbeck: yeah i encoded it -- let me see if it's finished
      • DarrenBridenbeck
        ehazlett: you are awesome
      • DarrenBridenbeck has quit
      • DarrenBridenbeck joined the channel
      • nigel_bot has quit
      • nigel_bot joined the channel
      • ehazlett
        all: taking off for a while ; will be aroun dlater