Jump to content

Gain speed by reducing session length?


Guest Broarne

Recommended Posts

Guest Broarne

I am having problems with slow database. The traffic on my site is quite intense, and I suspect that the performance problems has something to do with the number of stored sessions. In Admin panel I have an option to set the max session length (now 172800 sec, 48 hrs). Is there any disadvantages by reducing that number? Can I break something? Any experiences in this?

Sorry if this may be a stupid question, but I really don't want to mess up something in the database.

Mats

Link to comment
Share on other sites

Hi Mats,

I don't think it will speed things up. The session is held in a cookie, and and then updates a specific record in the database for the visitor. There is a "SELECT" statement to pull the session data (langange/currency etc) based on the token held in the cookie.

Providing the database engine is not overloaded, the query will execute very quickly. (not much data being stored, and only 1 record being returned)

How much traffic (visitors) are you talking about? Things that will effect the speed of the site can be (in typical order);

-Server Loading (is it already heavily loaded by other sites -more applicable on a shared server) Is the slowness consistent throughout the day?

-Number of queries per page. If you've applied lots of mods, or have many categories (100's+) with an expanding category mod, then it will slow down the site.

-Large images (filesize), or flash/other media. Some people upload large (100KB+) images, and simply resize in the FCK Editor (this does not resize the image, simply the dimensions used in the HTML)

-Poor network connection- this could be the host's end, or anywhere in between. Is the hosting companies website ok for speed? Run a TRACERT to see if there are dropped packets or high latency.

You can try reducing the session length, the effect will be that visitors who return after the session timeout will not see their basket. 2 or 3 hrs could be fine, but I can't see any benefit to reducing it.

If you're still stuck, please post your URL (or PM if you want to keep it private). If you are selling adult goods to protect other members. (workplace rules etc)

Jason

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...