#metabrainz

/

      • Mr_Monkey
        That's good to know.
      • 2019-03-10 06933, 2019

      • samj1912
        well - here's the thing
      • 2019-03-10 06951, 2019

      • samj1912
        shifting to Sir would mean you don't have to worry about scaling the indexer later
      • 2019-03-10 06902, 2019

      • samj1912
        but it would mean having a python sqla orm
      • 2019-03-10 06916, 2019

      • samj1912
        if you want - you could use your existing JS orm to shift to solr
      • 2019-03-10 06923, 2019

      • samj1912
        I would leave it to you to prioritize
      • 2019-03-10 06937, 2019

      • samj1912
        the current schema is simple enough that the JS one can be used
      • 2019-03-10 06959, 2019

      • Mr_Monkey
        That could be a good stepping stone.
      • 2019-03-10 06907, 2019

      • samj1912
        but in the future if you want to scale to a complex schema/faster indexer you can shift to sir
      • 2019-03-10 06943, 2019

      • samj1912
        anyway - you would first want to prioritize this
      • 2019-03-10 06950, 2019

      • Mr_Monkey
        I think that's a good way forward, that doesn't seem to me to hinder later needs
      • 2019-03-10 06905, 2019

      • samj1912
        so you want to move to sir?
      • 2019-03-10 06930, 2019

      • Mr_Monkey
        No, I think using the existing ORM might be more manageable
      • 2019-03-10 06935, 2019

      • samj1912
        ah okay
      • 2019-03-10 06936, 2019

      • samj1912
        cool
      • 2019-03-10 06943, 2019

      • samj1912
        so I would start with this
      • 2019-03-10 06957, 2019

      • samj1912
        look up existing Solr JS api helpers
      • 2019-03-10 06905, 2019

      • samj1912
        figure one you'd like to use
      • 2019-03-10 06913, 2019

      • samj1912
        and make a simple solr schema for now
      • 2019-03-10 06949, 2019

      • samj1912
      • 2019-03-10 06903, 2019

      • samj1912
        instead of tag you will have name
      • 2019-03-10 06911, 2019

      • samj1912
        everything else I guess remains the same
      • 2019-03-10 06918, 2019

      • samj1912
        id = bbid
      • 2019-03-10 06929, 2019

      • samj1912
        you have a ngram for autocomplete
      • 2019-03-10 06945, 2019

      • samj1912
        and maybe throw in a "type" field
      • 2019-03-10 06913, 2019

      • Mr_Monkey
        OK, indeed that's simple enough. Would that be all that is needed for a simple schema then?
      • 2019-03-10 06918, 2019

      • samj1912
        yup
      • 2019-03-10 06947, 2019

      • samj1912
        and since you seem to have just 1 core and all your entities are indexed there you can also have a unified search like you currently do
      • 2019-03-10 06907, 2019

      • samj1912
        so all you would be indexing is the name of the entity, its bbid and its type
      • 2019-03-10 06925, 2019

      • samj1912
        all 3 fields would be stored and indexed
      • 2019-03-10 06938, 2019

      • samj1912
        keep the ngram field indexed but not stored
      • 2019-03-10 06941, 2019

      • Mr_Monkey
        I suppose aliases would be good as well, but maybe not a lot more complicated ?
      • 2019-03-10 06914, 2019

      • samj1912
        yeah - you can copy the alias config from https://github.com/metabrainz/mbsssss/blob/master…
      • 2019-03-10 06920, 2019

      • samj1912
        should be just that
      • 2019-03-10 06929, 2019

      • Mr_Monkey
        >keep the ngram field indexed but not stored
      • 2019-03-10 06929, 2019

      • Mr_Monkey
        /me is a noob, didn't understand
      • 2019-03-10 06945, 2019

      • samj1912
        ngram is used for partial searches
      • 2019-03-10 06906, 2019

      • samj1912
        like if you search for "Sam" "samj1912" will show up in the results
      • 2019-03-10 06919, 2019

      • samj1912
        solr stored fields are any fields that you want solr to return
      • 2019-03-10 06926, 2019

      • samj1912
        indexed fields are any fields you want to search
      • 2019-03-10 06939, 2019

      • Mr_Monkey
        Ah, I see.
      • 2019-03-10 06920, 2019

      • samj1912
        since ngrams basically break up something like samj1912 into - "sam", "amj", "mj1" etc. you do not want those things to be returned by solr
      • 2019-03-10 06924, 2019

      • samj1912
        just searchable
      • 2019-03-10 06935, 2019

      • samj1912
        (I am assuming trigrams here)
      • 2019-03-10 06944, 2019

      • Mr_Monkey
        Got it. I see how that's configured in the schema
      • 2019-03-10 06917, 2019

      • samj1912
        so yeah - this should be very simple to do all this
      • 2019-03-10 06918, 2019

      • dns[m] has quit
      • 2019-03-10 06933, 2019

      • samj1912
        maybe you can piggy back on you existing solr servers hosted for mb
      • 2019-03-10 06935, 2019

      • dns[m] joined the channel
      • 2019-03-10 06940, 2019

      • samj1912
        since it is just 1 more core
      • 2019-03-10 06947, 2019

      • samj1912
        I would leave it to zas to decide
      • 2019-03-10 06923, 2019

      • Mr_Monkey
        Yes, I'll see with him about hosting
      • 2019-03-10 06950, 2019

      • samj1912
        but yeah all of this should be simple enough
      • 2019-03-10 06901, 2019

      • Mr_Monkey
        So that path wouldn't prevent us from later on creating more complex schemas down the line?
      • 2019-03-10 06943, 2019

      • samj1912
        well - I would suggest moving to something like Sir once you have complex relationships between your searchable objects
      • 2019-03-10 06905, 2019

      • samj1912
        but as of now - this should be good to go
      • 2019-03-10 06929, 2019

      • Mr_Monkey
        Right, that'll be a chunk of work, but that means GSOC aspirants don't need to know JS+Python at least
      • 2019-03-10 06942, 2019

      • samj1912
      • 2019-03-10 06949, 2019

      • samj1912
        and trying it out
      • 2019-03-10 06911, 2019

      • Mr_Monkey
        For sure
      • 2019-03-10 06905, 2019

      • samj1912
        also since your schema is so simple I guess you can use the postgres driver to index data https://www.searchstax.com/blog/importing-data-po…
      • 2019-03-10 06924, 2019

      • Mr_Monkey
        Hah, I was about to ask about continuous indexing/reindexing
      • 2019-03-10 06946, 2019

      • samj1912
        well I don't know how BB currently handles that
      • 2019-03-10 06916, 2019

      • Mr_Monkey
      • 2019-03-10 06934, 2019

      • Mr_Monkey
      • 2019-03-10 06900, 2019

      • samj1912
        but that basically deletes the index and reindexes everything right
      • 2019-03-10 06901, 2019

      • Mr_Monkey
        Although that's all ES specific
      • 2019-03-10 06904, 2019

      • samj1912
        what about updates?
      • 2019-03-10 06918, 2019

      • Mr_Monkey
        Hang on, I'll have to dig it up
      • 2019-03-10 06919, 2019

      • Mr_Monkey
        samj1912: Here it is. That's called when an entity is created https://github.com/bookbrainz/bookbrainz-site/blo…
      • 2019-03-10 06900, 2019

      • samj1912
        cool - btw what is body?
      • 2019-03-10 06912, 2019

      • samj1912
        can I see an example of what it looks like?
      • 2019-03-10 06924, 2019

      • Mr_Monkey
        The content of the http request body
      • 2019-03-10 06931, 2019

      • Mr_Monkey
        Hang on
      • 2019-03-10 06926, 2019

      • Mr_Monkey
        I don't have an example at hand for the body, but it will be a json object representing the entity from the ORM object
      • 2019-03-10 06943, 2019

      • samj1912
        okay
      • 2019-03-10 06944, 2019

      • samj1912
      • 2019-03-10 06905, 2019

      • pac23 has quit
      • 2019-03-10 06911, 2019

      • samj1912
        hmm not updated in 2 yrs
      • 2019-03-10 06905, 2019

      • samj1912
      • 2019-03-10 06907, 2019

      • Mr_Monkey
        I figure I'll find something suitable
      • 2019-03-10 06920, 2019

      • Mr_Monkey
        I was reading that earlier, looks like there's some alternatives
      • 2019-03-10 06941, 2019

      • samj1912
        well solr recommends using plain old xmlhr
      • 2019-03-10 06915, 2019

      • Mr_Monkey
        I'm happy with that.
      • 2019-03-10 06941, 2019

      • Mr_Monkey
        I mostly need to read up some docs of the API
      • 2019-03-10 06917, 2019

      • samj1912
        yeah
      • 2019-03-10 06921, 2019

      • samj1912
        well thats that
      • 2019-03-10 06940, 2019

      • Mr_Monkey
        https://lucene.apache.org/solr/guide/6_6/uploadin… looks like it would be fairly easy
      • 2019-03-10 06953, 2019

      • samj1912
        yeah
      • 2019-03-10 06908, 2019

      • Mr_Monkey
        JS/Expressjs and HTTP requests will be a breeze
      • 2019-03-10 06915, 2019

      • samj1912
        let's catch up in 2 weeks around the same time on progress?
      • 2019-03-10 06919, 2019

      • samj1912
        im off for lunch
      • 2019-03-10 06933, 2019

      • Mr_Monkey
        OK, that gives me a much clearer picture, and it seems like an easier project than I anticipated.
      • 2019-03-10 06939, 2019

      • Mr_Monkey
        Thanks a lot for your help samj1912 !
      • 2019-03-10 06941, 2019

      • samj1912
        yeah
      • 2019-03-10 06943, 2019

      • samj1912
        no worries
      • 2019-03-10 06950, 2019

      • Mr_Monkey
        Much appreciated
      • 2019-03-10 06911, 2019

      • Mr_Monkey
        And bon appétit :)
      • 2019-03-10 06929, 2019

      • pac23 joined the channel
      • 2019-03-10 06936, 2019

      • pac23 has quit
      • 2019-03-10 06955, 2019

      • michelv has quit
      • 2019-03-10 06931, 2019

      • Cyna
        reosarevok: Can you help me test changes made to the .tt and React files ?
      • 2019-03-10 06902, 2019

      • Cyna
        I've tried recompiling the resources and running the redis-server again but it didnt work
      • 2019-03-10 06942, 2019

      • reosarevok
        Cyna: are the components listed in server/components?
      • 2019-03-10 06952, 2019

      • reosarevok
        (that's a new thing that might not be documented properly yet?
      • 2019-03-10 06955, 2019

      • reosarevok
        )
      • 2019-03-10 06945, 2019

      • Cyna
        I want to test change to the existing .tt file as of now
      • 2019-03-10 06951, 2019

      • reosarevok
        Oh
      • 2019-03-10 06914, 2019

      • Cyna
        I am trying to understand catalyst
      • 2019-03-10 06926, 2019

      • reosarevok
        Those should change automatically as far as I know, unless you're embedding a React component in which case you'll still need to list it in root/server/components
      • 2019-03-10 06939, 2019

      • Cyna
        Hmm...
      • 2019-03-10 06947, 2019

      • reosarevok
        I'm at the shop on mobile now, but if you push and link me to your branch I can take a quick look
      • 2019-03-10 06914, 2019

      • Cyna
        Im changed index.tt
      • 2019-03-10 06918, 2019

      • Cyna
      • 2019-03-10 06906, 2019

      • reosarevok
        What are you changing there? I don't know it by heart and can't find a different properly on mobile :)
      • 2019-03-10 06930, 2019

      • Cyna
        I've changed the href
      • 2019-03-10 06906, 2019

      • Cyna
        <li><a href="[% c.uri_for_action('/admin/attributes/attribute_index', [ m ]) %]">[% m %] hell</a></li>
      • 2019-03-10 06918, 2019

      • Cyna
        But Im getting the output
      • 2019-03-10 06937, 2019

      • Cyna
      • 2019-03-10 06938, 2019

      • Cyna
        I must've got *attribute_name + hell*
      • 2019-03-10 06951, 2019

      • reosarevok
        Is models defined? That's inside an if models, you might actually be rendering the else
      • 2019-03-10 06907, 2019

      • Cyna
        Yea the models is defined in the controller
      • 2019-03-10 06912, 2019

      • reosarevok
        Ok. I'll take a look when I get home if you haven't figured out in the meantime
      • 2019-03-10 06917, 2019

      • Cyna
        Sorry reosarevok
      • 2019-03-10 06922, 2019

      • reosarevok
        Might take like 30 min
      • 2019-03-10 06933, 2019

      • Cyna
        I just found out that I had edited the wrong copy
      • 2019-03-10 06955, 2019

      • Cyna
        It worked after changing the right copy which my container is binded to
      • 2019-03-10 06901, 2019

      • Cyna
        Thanks and sorry for the trouble
      • 2019-03-10 06949, 2019

      • reosarevok
        Haha
      • 2019-03-10 06955, 2019

      • reosarevok
        Well, that's good to hear!
      • 2019-03-10 06911, 2019

      • reosarevok
        Do let me know if you need help with something :)
      • 2019-03-10 06933, 2019

      • Cyna
        Yea sure... Im figuring out perl right now
      • 2019-03-10 06939, 2019

      • CallerNo6 joined the channel
      • 2019-03-10 06939, 2019

      • CallerNo6 has quit
      • 2019-03-10 06939, 2019

      • CallerNo6 joined the channel
      • 2019-03-10 06953, 2019

      • Zastai joined the channel
      • 2019-03-10 06940, 2019

      • ahmedkrmn joined the channel
      • 2019-03-10 06901, 2019

      • Zastai
        Where can I find the current ListenBrainz API docs? I've been using https://listenbrainz.readthedocs.io/en/latest but that is clearly outdated.
      • 2019-03-10 06940, 2019

      • Zastai
        And the GitHub repo is no immediate help since it's .rst files, with the bulk of the API documented at document expansion time
      • 2019-03-10 06959, 2019

      • CatQuest
        usb sticks are ancient? 🤔
      • 2019-03-10 06921, 2019

      • CatQuest
        [13:27] <yvanzo> good instant
      • 2019-03-10 06922, 2019

      • CatQuest
        hah! that one. 👍
      • 2019-03-10 06942, 2019

      • outsidecontext joined the channel
      • 2019-03-10 06935, 2019

      • Zastai
        (and it looks like the mbids in listens are now deprecated in favour of msids, which I assume are MessyBrainz IDs - but that's not documented, and messybrainz.org does not seem to document an API either)
      • 2019-03-10 06907, 2019

      • amCap1712 has quit
      • 2019-03-10 06928, 2019

      • Freso
        Zastai: Fetching or submitting listens?
      • 2019-03-10 06943, 2019

      • Zastai
        Currently fetching
      • 2019-03-10 06948, 2019

      • Freso
        For submitting, you shouldn't submit MSIDs, always MBIDs.
      • 2019-03-10 06935, 2019

      • Freso
        iliekcomputers is likely the one that can best answer your questions.
      • 2019-03-10 06941, 2019

      • Zastai
        I'm fetching, but getting null for all _documented_ fields; only MSIDs are filled. (Imported scrobbles)