Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Try Vanilla Forums Cloud product

Post count not updating.

Hello, I am currently having a problem where on my site the Discussion Count does not update in the category after posting. Is there any way to fix this?

Comments

  • I'm having the same problem.

  • CaylusCaylus ✭✭

    Could you try visiting yourforum/dba/counts to see if that fixes your problem?

  • x00x00 MVP

    /dba/counts will recalculate

    It can be that there is a denormalise config setting so that counts are updated every post but every n posts, it can also be a problem with caching.

    2.5 is very new, so worth opening an issue on github

    grep is your friend.

  • I have the same problem after updating to 2.5.1.
    running /dba/counts resets the counters but they still won't update on their own.

    Recalculate Conversation.CountMessages
    Recalculate Conversation.CountParticipants
    Recalculate Conversation.FirstMessageID
    Recalculate Conversation.LastMessageID
    Recalculate Conversation.DateUpdated
    Recalculate Conversation.UpdateUserID
    Recalculate Discussion.CountComments
    Recalculate Discussion.FirstCommentID
    Recalculate Discussion.LastCommentID
    Recalculate Discussion.DateLastComment
    Recalculate Discussion.LastCommentUserID
    100%
    Recalculate Category.CountDiscussions
    Recalculate Category.CountAllDiscussions
    Recalculate Category.CountComments
    Recalculate Category.CountAllComments
    Recalculate Category.LastDiscussionID
    Recalculate Category.LastCommentID
    Recalculate Category.LastDateInserted
    Recalculate Tag.CountDiscussions

  • BTW, the counters may have stopped working after I deleted a user (including data).

  • Ivan_GurinIvan_Gurin Moscow

    It's old bug. You must wait until number of discussions or number of comments in discussion will be great then current number. Or you can recalculate counters. Same behavior when you split or merge or move discussions.

  • R_JR_J Cheerleader & Troubleshooter Munich Moderator

    @x00 said:
    /dba/counts will recalculate

    It can be that there is a denormalise config setting so that counts are updated every post but every n posts, it can also be a problem with caching.

    2.5 is very new, so worth opening an issue on github

    There is a config setting 'Vanilla.Views.Denormalize' used in the DiscussionModel which defaults to false, but I really do not know the purpose of that setting.

    You can try adding $Configuration['Vanilla']['Views']['Denormalize'] = true; to your config.php and see if that changes something... :confused:

  • SugarFreeSugarFree New
    edited March 7

    adding $Configuration['Vanilla']['Views']['Denormalize'] = true; to config.php didn't change anything. Nor other values: false, '1'.
    I also reinstalled Vanilla 2.5.1, starting with an empty directory. Didn't help.
    Recalculating counters doesn't help either. The counters just don't... count.

  • @Ivan_Gurin said:
    It's old bug. You must wait until number of discussions or number of comments in discussion will be great then current number. Or you can recalculate counters. Same behavior when you split or merge or move discussions.

    does this bug affect everyone, or are some counters more lucky?

  • I'm having the same issue

  • LincLinc Director of Development Detroit Vanilla Staff
    edited March 16

    @R_J said:
    There is a config setting 'Vanilla.Views.Denormalize' used in the DiscussionModel which defaults to false, but I really do not know the purpose of that setting.

    If you use memcached, we store pageview counts in its cache until it gets to 10 before adding that increment of 10 to the database counter. This reduces writes to the database dramatically. The downside to this is that clearing the cache can lose up to 9 views per discussion, so if you're running a small site and notice tiny increments like that & clear the cache regularly (like during a deploy) it can be irritating. So that config passes thru all the writes to the database, which isn't the worst thing on a low-traffic site. If you're not using memcached, the setting does nothing.

    If you're getting a few thousand or more pageviews a day I'd leave it set to the default.

  • LincLinc Director of Development Detroit Vanilla Staff
    edited March 16

    Pageview counters in Vanilla happen asynchronously via Javascript to conserve resources and avoid counting bot views. If you have any Javascript errors on your site, that would cause pageviews to stop. In your browser's web development console, look for a call to /settings/analyticstick.json. If it's not firing, look for a Javascript error. If it is firing, look to see if an error is being returned by your server.

  • Did anyone get this fixed? Cause I have the exact same problem and /settings/analyticstick.json seems to work just fine.

Sign In or Register to comment.