#metabrainz

/

      • ademoglu_ has left the channel
      • 2015-12-08 34203, 2015

      • Bookzombie has quit
      • 2015-12-08 34215, 2015

      • Bookzombie joined the channel
      • 2015-12-08 34221, 2015

      • bitmap
        https://pastee.org/eqcx4 would there be something wrong with that that I'm not seeing?
      • 2015-12-08 34231, 2015

      • bitmap
        getting the type to restrict the number of tables it joins with, I mean
      • 2015-12-08 34252, 2015

      • Leftmost
        It seems reasonable to me.
      • 2015-12-08 34245, 2015

      • chirlu`
        Well, I think there is a feature request to have mixed-type collections.
      • 2015-12-08 34201, 2015

      • MetaNova has left the channel
      • 2015-12-08 34230, 2015

      • bitmap
        I see
      • 2015-12-08 34203, 2015

      • bitmap
        although even then we could be more restrictive
      • 2015-12-08 34204, 2015

      • chirlu`
        Haven’t found it yet, though.
      • 2015-12-08 34239, 2015

      • NotTheFBI is now known as TheHackOps
      • 2015-12-08 34255, 2015

      • bitmap
        I've snuck that diff on beta just to see if it knocks any more seconds off...
      • 2015-12-08 34206, 2015

      • CallerNo6 has quit
      • 2015-12-08 34248, 2015

      • bitmap
        or even milliseconds I'd be happy with
      • 2015-12-08 34246, 2015

      • chirlu`
        Milliseconds are more likely. :) Leftmost’s collection is fast now, but that’s probably because it is in cache (I tried it some time ago already).
      • 2015-12-08 34218, 2015

      • Leftmost
        09a5666d-7062-4b62-b153-68c5b8dbd2d4, you mean?
      • 2015-12-08 34224, 2015

      • regagain_ joined the channel
      • 2015-12-08 34225, 2015

      • chirlu`
        “CDs”.
      • 2015-12-08 34235, 2015

      • Leftmost
        Oh, that one's fast. I have a private collection which is a good bit larger and a good bit slower.
      • 2015-12-08 34246, 2015

      • Leftmost
        I can give you a dump of it if that's helpful.
      • 2015-12-08 34258, 2015

      • regagain_ has quit
      • 2015-12-08 34219, 2015

      • chirlu`
        Looking at http://explain.depesz.com/s/Nif, you see that the additional tables only contribute about 13 ms to the total time of 35,816 ms.
      • 2015-12-08 34210, 2015

      • cshah joined the channel
      • 2015-12-08 34229, 2015

      • cshah has left the channel
      • 2015-12-08 34239, 2015

      • chirlu`
        And 7 ms to the total of 199 ms with warm cache, http://explain.depesz.com/s/9XKC
      • 2015-12-08 34259, 2015

      • bitmap
        very low-hanging fruit, then
      • 2015-12-08 34221, 2015

      • chirlu`
        It’s not inconveivable that the planner might find a better plan with less tables, though, but I don’t see how.
      • 2015-12-08 34200, 2015

      • bitmap
        maybe I'll submit it later after removing the sql duplication
      • 2015-12-08 34217, 2015

      • bitmap
        more concerned with the subscribed_entity_edits query right now, which is totally broken
      • 2015-12-08 34207, 2015

      • Leftmost
        chirlu`, I'll put together a dump of the larger coll. What's the best way to pass it to you?
      • 2015-12-08 34232, 2015

      • CallerNo6 joined the channel
      • 2015-12-08 34224, 2015

      • ariscop has quit
      • 2015-12-08 34204, 2015

      • opatel99
        CallerNo6, I was reviewing the logs, and it seems that your vast knowledge could be better put to use if you started coding
      • 2015-12-08 34223, 2015

      • CallerNo6
        heh, it's been on my 'to do' list for a ridiculous number of years.
      • 2015-12-08 34221, 2015

      • opatel99
        Mind if I PM, I have an idea to get that todo list started...
      • 2015-12-08 34219, 2015

      • chirlu`
        bitmap: (now() - edit.open_time) < interval $3) ← that’s likely very, very slow
      • 2015-12-08 34205, 2015

      • chirlu`
        I’d expect (edit.open_time > now() - interval $3) to be much faster.
      • 2015-12-08 34255, 2015

      • bitmap
        hmm
      • 2015-12-08 34257, 2015

      • chirlu`
        Leftmost: I don’t think I’ll be able to use it.
      • 2015-12-08 34222, 2015

      • chirlu`
        Leftmost: You could tell me the row ID, though.
      • 2015-12-08 34238, 2015

      • CallerNo6
        opatel99, thanks, how about another time? I'm in the middle of something.
      • 2015-12-08 34209, 2015

      • chirlu`
        bitmap: They are mathematically equivalent (I hope, unless I made a dumb mistake), but the second can make use of the index on edit (open_time).
      • 2015-12-08 34211, 2015

      • opatel99
        CallerNo6, No probs bro
      • 2015-12-08 34221, 2015

      • Leftmost
        Hmm? Why wouldn't you be able to use it? Anyhow, I'm not sure of the row ID, just the MBID.
      • 2015-12-08 34203, 2015

      • chirlu`
        Leftmost: Because I can’t duplicate the production environment.
      • 2015-12-08 34219, 2015

      • chirlu`
        You can find the row ID in the subscribe/unsubscribe links.
      • 2015-12-08 34245, 2015

      • Leftmost
        36642
      • 2015-12-08 34243, 2015

      • ariscop joined the channel
      • 2015-12-08 34211, 2015

      • opatel99 has quit
      • 2015-12-08 34211, 2015

      • chirlu`
        Noted for future reference.
      • 2015-12-08 34251, 2015

      • chirlu`
        bitmap: Now the query is *really* broken. ;-)
      • 2015-12-08 34253, 2015

      • Nyanko-sensei joined the channel
      • 2015-12-08 34234, 2015

      • bitmap
        yeah, I forgot some parentheses when I was sneaking in the change you suggested >_<
      • 2015-12-08 34205, 2015

      • D4RK-PH0_ has quit
      • 2015-12-08 34244, 2015

      • bitmap
        still consistently times out, sadly
      • 2015-12-08 34245, 2015

      • chirlu`
        Can you get me a query plan (plain EXPLAIN)?
      • 2015-12-08 34218, 2015

      • bitmap
        sure, one moment
      • 2015-12-08 34247, 2015

      • chirlu`
        And the query itself, too. The code producing it is really hard to follow. :)
      • 2015-12-08 34207, 2015

      • bitmap nods
      • 2015-12-08 34231, 2015

      • chirlu`
        I was trying to produce a timeout locally where I have ShowErrorStatement, but it’s hard with an almost empty database.
      • 2015-12-08 34229, 2015

      • bitmap
      • 2015-12-08 34254, 2015

      • bitmap
        (including the open_time change)
      • 2015-12-08 34206, 2015

      • bitmap
        http://explain.depesz.com/s/QX1 there's the explain for it
      • 2015-12-08 34236, 2015

      • chirlu`
        The expensive part is the direct subscriptions to artists.
      • 2015-12-08 34259, 2015

      • chirlu`
        By direct I mean not via collections.
      • 2015-12-08 34229, 2015

      • bitmap
        whoops, that's actually your editor ID. copied the wrong one from the logs :)
      • 2015-12-08 34254, 2015

      • chirlu`
        Doesn’t matter much, I think.
      • 2015-12-08 34202, 2015

      • bitmap
        yeah
      • 2015-12-08 34208, 2015

      • bitmap
        makes sense, anyway, since I have way more artist subscriptions than any other kind
      • 2015-12-08 34252, 2015

      • CallerNo6 has quit
      • 2015-12-08 34223, 2015

      • chirlu`
        bitmap: Could you throw out the (status = 1) conditions and only leave the other part of the OR in, then run another EXPLAIN with
      • 2015-12-08 34203, 2015

      • chirlu`
        I.e. get all recent edits, ignore any possibly-still-open older edits.
      • 2015-12-08 34228, 2015

      • bitmap
      • 2015-12-08 34218, 2015

      • chirlu`
        Now try an EXPLAIN (ANALYZE, BUFFERS) with that, perhaps it will end in a reasonable time. ;-)
      • 2015-12-08 34202, 2015

      • bitmap
        yup, it did
      • 2015-12-08 34241, 2015

      • bitmap
      • 2015-12-08 34216, 2015

      • chirlu`
        Hmmm.
      • 2015-12-08 34215, 2015

      • chirlu`
        So we should do this in any case, have either the status = 1 part in the query (for open edits only) or the open_time thing, not an OR of them both.
      • 2015-12-08 34225, 2015

      • chirlu`
        Perhaps make it 7 days plus 3 hours or something, to avoid expired-but-not-applied-yet edits from falling out of the results.
      • 2015-12-08 34201, 2015

      • Nyanko-sensei has quit
      • 2015-12-08 34222, 2015

      • chirlu`
        This doesn’t change functionality, I think, except for the rare case where an edit fails to apply due to a bug.
      • 2015-12-08 34229, 2015

      • Nyanko-sensei joined the channel
      • 2015-12-08 34200, 2015

      • chirlu`
        It still takes rather long time, though, because it has to use the index on open_time to avoid even worse performance, and that means a less good join order for the other tables.
      • 2015-12-08 34201, 2015

      • bitmap
        wouldn't it affect edits that have their close time extended due to no votes?
      • 2015-12-08 34216, 2015

      • chirlu`
        Oh, right.
      • 2015-12-08 34212, 2015

      • bitmap
        I guess that's rare, too, but it'd be confusing if they weren't visible until you clicked 'Only show open edits'...
      • 2015-12-08 34213, 2015

      • chirlu`
        I’d still say, make the interval longer to include those and leave it at that.
      • 2015-12-08 34219, 2015

      • chirlu`
        I’ll think about if there is an index that we could add and that would help.
      • 2015-12-08 34207, 2015

      • bitmap
        agreed, I'm happy with that workaround if it makes the site usable
      • 2015-12-08 34214, 2015

      • bitmap
        thanks for digging into this
      • 2015-12-08 34232, 2015

      • chirlu`
        Interval would be $OPEN_EDIT_DURATION days + $MINIMUM_RESPONSE_PERIOD + 1 hour, or something.
      • 2015-12-08 34216, 2015

      • chirlu`
        (We should perhaps change $OPEN_EDIT_DURATION to be a Duration instead of a plain number?)
      • 2015-12-08 34258, 2015

      • bitmap
        that would be smart :)
      • 2015-12-08 34245, 2015

      • DakshShah has left the channel
      • 2015-12-08 34232, 2015

      • chirlu`
        OK, it’s not the time of day for me to have brilliant optimization ideas, but I’ll think more about it later or tomorrow.
      • 2015-12-08 34205, 2015

      • chirlu`
        But without the OR and with open_time on one side of the condition, most people should not need to reload too often to see their subscribed entity edits. ;-)
      • 2015-12-08 34213, 2015

      • ignacio
        Hello, can I bring gcibot here?
      • 2015-12-08 34249, 2015

      • chirlu`
        What does it do?
      • 2015-12-08 34216, 2015

      • ignacio
      • 2015-12-08 34216, 2015

      • ignacio
        <gcibot> Add keyboard control for journal || 3 days || Sugar Labs
      • 2015-12-08 34255, 2015

      • ignacio
        chirlu`, Just paste task link, and it tells you the name date, and another thins
      • 2015-12-08 34247, 2015

      • chirlu`
        Ah, that could be useful.
      • 2015-12-08 34200, 2015

      • chirlu`
        Perhaps get some more feedback, though.
      • 2015-12-08 34216, 2015

      • ignacio
        It's ok? I will remove from the channel if someone wants
      • 2015-12-08 34221, 2015

      • chirlu`
        Most mentors etc. should be awake again in a few hours. :)
      • 2015-12-08 34227, 2015

      • ignacio
        Okay
      • 2015-12-08 34235, 2015

      • chirlu`
        Freso ^
      • 2015-12-08 34239, 2015

      • ignacio
        Good night
      • 2015-12-08 34204, 2015

      • chirlu`
        Ah, other end of the time zones. :) Good night.
      • 2015-12-08 34240, 2015

      • stanislas joined the channel
      • 2015-12-08 34255, 2015

      • bitmap
      • 2015-12-08 34258, 2015

      • bitmap
        bed time now...thanks again for help there, chirlu` ^
      • 2015-12-08 34238, 2015

      • stanislas has quit
      • 2015-12-08 34251, 2015

      • stanislas joined the channel
      • 2015-12-08 34219, 2015

      • stanislas has quit
      • 2015-12-08 34242, 2015

      • stas joined the channel
      • 2015-12-08 34204, 2015

      • stas is now known as Guest15403
      • 2015-12-08 34251, 2015

      • Guest15403 has quit
      • 2015-12-08 34219, 2015

      • stanislas joined the channel
      • 2015-12-08 34240, 2015

      • stanislas has quit
      • 2015-12-08 34237, 2015

      • zag2 joined the channel
      • 2015-12-08 34250, 2015

      • zag has quit
      • 2015-12-08 34221, 2015

      • Kevin joined the channel
      • 2015-12-08 34200, 2015

      • Kevin is now known as Guest11362
      • 2015-12-08 34219, 2015

      • Guest11362 has left the channel
      • 2015-12-08 34250, 2015

      • stanislas joined the channel
      • 2015-12-08 34242, 2015

      • stanislas has quit
      • 2015-12-08 34224, 2015

      • ariscop has quit
      • 2015-12-08 34236, 2015

      • Freso
        ignacio: I'm up now, but I haven't caught up on backlog yet.
      • 2015-12-08 34202, 2015

      • Freso
        ignacio: But yes, please bring gcibot here. :) Possibly also #musicbrainz
      • 2015-12-08 34221, 2015

      • Freso goes to catch up on backlog
      • 2015-12-08 34216, 2015

      • Leo_Verto joined the channel
      • 2015-12-08 34245, 2015

      • tinyhippo joined the channel
      • 2015-12-08 34201, 2015

      • Freso is now known as Freso_
      • 2015-12-08 34212, 2015

      • Freso_ is now known as Freso
      • 2015-12-08 34208, 2015

      • ariscop joined the channel
      • 2015-12-08 34206, 2015

      • UmkaDK has quit
      • 2015-12-08 34259, 2015

      • UmkaDK joined the channel
      • 2015-12-08 34255, 2015

      • ruaok
        holiday in catalunya, still going to make the xurros.
      • 2015-12-08 34200, 2015

      • ruaok
        time to make the xurros.
      • 2015-12-08 34259, 2015

      • ruaok
      • 2015-12-08 34201, 2015

      • Freso
        Gentlecat: I just took you off https://codein.withgoogle.com/tasks/4783192871534… and replaced you with CallerNo6. Seems like this is something right up Alex' alley, and you have plenty of things with CB and stuff on your plate already. :)
      • 2015-12-08 34259, 2015

      • Freso
        (Plus, with you + reosarevok + me as mentors, the time zone distribution spanned UTC+0100 to UTC+0200... Caller help spread the timezone out a bit more. :))
      • 2015-12-08 34231, 2015

      • chirlu`
        Speaking of time zones, can we get more channel ops?
      • 2015-12-08 34200, 2015

      • chirlu`
        E.g. bitmap and someone at UTC +xx.
      • 2015-12-08 34245, 2015

      • reosarevok
        Yay two more flags need updating
      • 2015-12-08 34251, 2015

      • reosarevok makes two tasks :)
      • 2015-12-08 34259, 2015

      • Freso
        chirlu`: bitmap is already a channel op?
      • 2015-12-08 34228, 2015

      • Freso
        He should be anyway.