title: cookie expiration time with activerecord session store
body: <p>This question is a follow-up to <a href="https://stackoverflow.com/questions/5860950/setting-session-timeout-in-rails-3/9024533">this</a>. I can't seem to change the expiration time on the cookie when I switched to ActiveRecord session store. It contains just the <code>session_id</code> like it should, but its expiration time is set to HTTP session. I tried setting it in <code>application.rb</code>:</p>
  
  <pre><code>config.session_store :cookie_store, {
    :expire_after =&gt;  2.hours,
  }
  </code></pre>
  
  <p>But it doesn't do anything.</p>
  
  <p>I could hack it by creating an additional cookie and storing a <code>session_id</code> there, but that seems wrong.</p>