What are the Slack Archives?

It’s a history of our time together in the Slack Community! There’s a ton of knowledge in here, so feel free to search through the archives for a possible answer to your question.

Because this space is not active, you won’t be able to create a new post or comment here. If you have a question or want to start a discussion about something, head over to our categories and pick one to post in! You can always refer back to a post from Slack Archives if needed; just copy the link to use it as a reference..

hi, technical question, are there any plans to implement a cache mechanism in glue?

UK7TM6CQJ
UK7TM6CQJ Posts: 123 πŸ§‘πŸ»β€πŸš€ - Cadet

hi, technical question, are there any plans to implement a cache mechanism in glue?

Comments

  • i would guess no, where would you suggest to add caches?

  • UK7TM6CQJ
    UK7TM6CQJ Posts: 123 πŸ§‘πŸ»β€πŸš€ - Cadet

    was thinking...everywhere

  • UK7TM6CQJ
    UK7TM6CQJ Posts: 123 πŸ§‘πŸ»β€πŸš€ - Cadet

    like a global/general thing

  • UK5DS29L2
    UK5DS29L2 Posts: 546 πŸ§‘πŸ»β€πŸš€ - Cadet
    edited September 2019

    I don't think you would really want to cache API responses

  • UK7TM6CQJ
    UK7TM6CQJ Posts: 123 πŸ§‘πŸ»β€πŸš€ - Cadet

    but we do, because catalog-search takes 6 seconds

  • UK5DS29L2
    UK5DS29L2 Posts: 546 πŸ§‘πŸ»β€πŸš€ - Cadet

    πŸ€” wasn't that Elasticsearch-based search? that was glue?

  • UK5DS29L2
    UK5DS29L2 Posts: 546 πŸ§‘πŸ»β€πŸš€ - Cadet

    ah, you're right, there's glue endpoint for that. but I wouldn't cache that.

  • UK5DS29L2
    UK5DS29L2 Posts: 546 πŸ§‘πŸ»β€πŸš€ - Cadet

    the point of the API is to serve you the current state

  • UK5DS29L2
    UK5DS29L2 Posts: 546 πŸ§‘πŸ»β€πŸš€ - Cadet

    a lot of events would have to be added around glue and update events to cache the response in a stable way. more work than it's worth to be honest. varnish would work here if you still want to cache it anyway

  • UK7TM6CQJ
    UK7TM6CQJ Posts: 123 πŸ§‘πŸ»β€πŸš€ - Cadet
    edited September 2019

    well, we just have ~45k products, and 5-6 seconds fetching the first page in catalog search is not acceptable...by far. we'll profile soon to check exactly what's causing it

  • but that sounds like a lot of other things that might be addressed first

  • because 45k is by no means a lot

  • Unknown
    edited September 2019

    what are your cluster’s specs? how is it configured?

  • more nodes? different nodes? cpu? memory? more shards?

  • is the time really lost during the roundtrip to elasticsearch?

  • just by the numbers i see, a fairly modest setup should provide 2 digit ms response times

  • maybe + latency

  • UK7TM6CQJ
    UK7TM6CQJ Posts: 123 πŸ§‘πŸ»β€πŸš€ - Cadet

    surely we'll profile