Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

Caching between thin server and db?

#71

Hi, I've switched to Thin (from Mongrel) in two of the applications I've launched. I've noticed sporadically in both apps that if I change something in my mysql database, some of the Thin procs will continue to run with the old data (from before the change), and some will query the database as they should. Unfortunately, I don't really have any way of verifying that Thin is doing it, but it's a hunch since it happens on some of the instances and not others (and is fixed when the Thins are restarted). Is such a thing even possible? Thanks for any help, sorry I can't provide you with anything more concrete.

Alex Farrill

Reported by Alex Farrill · June 11th, 2008 @ 05:27 PM

State: invalid
Milestone: Future
Assigned to: macournoyer macournoyer

Activity

  1. macournoyer
    macournoyer

    Well you can check that all thins have been restarted at the same time if the pids are close to one another.

    Also make sure you check the log file for any error preventing one of the thin to restart.

    June 11th, 2008 @ 05:31 PM

  2. Alex Farrill
    Alex Farrill

    The problem is I should not have to restart the thin servers when I make a

    change to the database. Is there caching going on at a low level?Thanks,

    Alex

    June 11th, 2008 @ 09:20 PM

  3. macournoyer
    macournoyer
    • State changed from new to invalid

    oh no! Thin doesn't do any kind of caching.

    But, ActiveRecord caches some queries so that might cause your issue.

    You can reset the cache w/:

    ActiveRecord::Base.connection.clear_query_cache
    

    Maybe place that in a hidden action if you need to do that kind of thing.

    June 11th, 2008 @ 10:02 PM

  4. Alex Farrill
    Alex Farrill

    Phew, sanity check. Yes, the problem had nothing to do with Thin, or ActiveRecord it turns out -- was grasping at straws! Thanks for your help, enjoying using Thin quite a bit

    Thanks again,

    Alex

    June 12th, 2008 @ 01:33 PM

  5. John
    John

    Oamenii încearcă să se asigure că.cazinoul poate fi o organizație profitabilă pe viață. Oamenilor din întreaga lume le place să joace la cazinourile online.Am jucat la cazinou GG Bet furnizorul de cazinou online cazinou GG Bet pentru o lungă perioadă de timp și nu pot spune nimic rău despre el, a spus el, Conform statisticilor, acest cazinou online are cel https://gg-bet-ro.com/ mai mare RTP

    April 23rd, 2024 @ 11:48 AM

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.