1. Marcin Kuzminski
  2. RhodeCode
  3. Issues

Issues

Issue #733 new

Cache invalidation issue

A P
created an issue

This is similar to #703, but the resolution for that does not apply to me.

After upgrading to 1.5.1, I found that sometimes the commits were disappearing. vcs_full_cache was True.

This is probably because, the setup regularly (but not most of the time) requires us to commit from outside rhodecode. So, manually invalidating the cache is not an option.

Setting vcs_full_cache to False resolves this issue, but destroys the performance.

Is there a better way to enable caching but invalidate the cache when commits are made from outside.

I've only tested this with 1.5.1 right now, but I'm guessing this might happen with 1.5.2 too.

Comments (4)

  1. Marcin Kuzminski repo owner

    Here's what i will do: 1 - expose an API function to invalidate cache so you can call it when you need cache invalidation runned manually 2 - write an example hooks that will call RhodeCode hooks internally. This will allow basically cache invalidation executed after pushing outside of RhodeCode

  2. A P reporter

    I patched 1.5.3 with the commit that exposes the invalidate_cache API function.

    https://secure.rhodecode.org/rhodecode/changeset/d6029dacbcc456cea48ea7a2bf8fd45725a1dc05

    This seems to create an issue.

    Let me explain what I'm doing: When making a push to A.git (through rhodecode), I am making a commit to B.git (outside of rhodecode, in the post-receive hook of A.git). So that rhodecode knows that B.git has changed, I am also calling the invalidate_cache API function for B.git (in the post-receive hook of A.git, right after I make the commit to B.git).

    This seems to cause the commit to A.git to appear in B.git (along with the commit made to B.git). This only shows on rhodecode though, if I make a fresh clone of B.git and check "git log", it is as I expect it to be (with just the commit to B.git). I manually invalidated the cache, and the ghost commit still exists.

    I hope that makes sense. Could this be an issue with patching? How do I get rid of the ghost commit.

  3. Log in to comment