• net

    (@krstarica)


    Site has ~200k published posts; {prefix}_wrc_caches has reached ~650k rows.

    About 560k are deleted = 0, cleaned = 0 (never flushed):

    post / is_single=1       ~260k
    unknown / is_single=1 ~225k
    post_tag / is_single=1 ~60k

    A LEFT JOIN against wrc_relations shows ~225k cache rows with no relations, matching the unknown block.

    99.98% of unknown rows are /wp-json/oembed/1.0/embed?url=.... Average ~1.03 hits each.

    260k post / single rows also average ~1 hit: cached once, never re-requested, never invalidated because the underlying post isn’t edited. They stay forever.

    Suggestions:

    • Exclude /wp-json/oembed/1.0/embed from caching by default, or give it a short TTL.
    • Add a cleanup that drops rows with expiration < NOW() - N days AND cache_hits < M.

You must be logged in to reply to this topic.