Return to Jive Software

Skip navigation
684 Views 7 Replies Last post: Jan 26, 2010 1:17 AM by nilsbolsen RSS
nilsbolsen Intermediate 571 posts since
Apr 10, 2008
Currently Being Moderated

Nov 16, 2009 4:02 AM

Short-term Query Cache - for discussions?

Hi Jive,

 

we have set the short-term query cache to 5 seconds.

eTeaming Staging.png

But replies to a discussion is displayed without delay. Allthought the says


Your message was posted successfully, but there will be a short delay before it is viewable in the thread." 

 

Is there some configuration that we have missed?

 

I attached a small clip showing the behavior.

 

best regards,

Nils

Attachments:
Expert 3,517 posts since
Jun 18, 2009
Currently Being Moderated
Nov 16, 2009 7:17 AM in response to: Nils Bolsen
Re: Short-term Query Cache - for discussions?

Hello Nils,

 

If you look at thread.ftl it looks like it says this without condition if you have the short-term query cache enabled.

 

Regarding the fact that content posts instantly, what happens if you try to post another message immediately after posting a message? After 5 seconds, the cache is cleared of the query so the first message you post will put the query back in the cache. For 5 seconds after that, if you try add new content and refresh the page, you'll have to wait for the cache toe expire once more.

 

This cache would probably be a lot more noticeable if you had someone else posting to the discussion and you were constantly hitting the refresh button.

 

Cheers,

Brad

Expert 3,517 posts since
Jun 18, 2009
Currently Being Moderated
Nov 16, 2009 8:42 AM in response to: Nils Bolsen
Re: Short-term Query Cache - for discussions?

Hello Nils,

 

So after exploring this code a bit more it looks like the query cache is used mostly for tracking counts for threads/messages/users in the discussions contexts as these counts are expensive operations. It looks like the only time it has anything to do with adding/creating/deleting content is in the root threads space, not for replies to threads, if that makes sense.

 

Cheers,

Brad

kevin.imber Jive Employee 2,726 posts since
Oct 19, 2009
Currently Being Moderated
Nov 25, 2009 8:45 AM in response to: Nils Bolsen
Re: Short-term Query Cache - for discussions?

Hello Nils,

 

Unfortunately, Brad left Jive last week, and I'm in the process of taking his cases.  I'll take a look at this, and let you know my findings as soon as I can.

 

Thanks,

Kevin

kevin.imber Jive Employee 2,726 posts since
Oct 19, 2009
Currently Being Moderated
Nov 30, 2009 8:52 AM in response to: Kevin Imber
Re: Short-term Query Cache - for discussions?

Hi Nils,

 

Thanks for being patient.  From what I've seen, the short term query cache is just another cache for database data, so any call that is looking for something that lives in the database will check the short term query cache first, fall through to the regular query cache, and then go to the database if it doesn't find the data in either of them.  The reason for the short term query cache is this:  we keep many lists.  And caches are helpful for that.  Problem is that the list is often edited while a copy of it is in the cache.  So an item somewhere down the list goes to the top.  So we nuke the whole copy of the list in the cache, and get it back from the db.  That can suck for the user.  The short term query cache helps with that problem like so:  when a list is invalidated in the regular query cache, the short term query cache spawns a background thread to get that data and load it before you have to call for it again.  That way we try not to spend as much time waiting for the newest version of the list.  A forum thread as it is so far in the conversation can be seen as a list, and the short term query cache can help get a copy of the thread if it has been edited and dropped from the regular query cache at some point while you were viewing/editing/adding to it.  The reason you're seeing it work so quickly is most likely because your copy of the forum thread is current with the actual thread when you edit, so it isn't a big deal.  And honestly, I think the problem is load based.  I don't think you'll be able to really reproduce the behavior for this cache to really take effect unless your system is under some serious load from users.  Let me know if you have any other questions.

 

Thanks,
Kevin

More Like This

  • Retrieving data ...

Bookmarked By (0)

To better serve our customers we have included functionality to automatically follow up on a case after it has been idle for more than 5 days, and then auto close after an additional 3 days of inactivity. Choose No to acknowledge that this case will remain idle for longer than 5 days.
Making cases public allows other customers to learn from the solution of the case. It can also be used to gain feedback from others in the community. Ask our Support Engineers for more info, but we encourage you to make your cases public.