Can you really disable session handling in Joomla 1.5 for visitors.

I donot use user system within the frontend, i believed it's unnecessary to operate queries like below:

Site uses APC or Memcache as caching system under heavy load, therefore it is essential for me

interesting comments

DELETE FROM jos_session WHERE ( time < '1274709357' )

Choose * FROM jos_session WHERE session_id = '70c247cde8dcc4dad1ce111991772475'

UPDATE jos_session SET time='1274710257',userid='0',usertype='',username='',gid='0',guest='1',client_id='0',data='__defaulta:8:Home windows U Home windows NT 5.1 en-US rv:1.9.2.3) Gecko/20100401 Opera/3.6.3"s:8:"registry"O:9:"JRegistry":3:s:7:"_errors"a::s:4:"user"O:5:"JUser":19:s:12:"_elementPath"a:1:s:17:"_defaultNameSpace"s:8:"_default"s:9:"_registry"a:1:s:7:"_errors"a::s:9:"_errorMsg"Ns:7:"_errors"a::s:13:"session.token"s:32:"a2b19c7baf223ad5fd2d5503e18ed323"' WHERE session_id='70c247cde8dcc4dad1ce111991772475'

Joomla automatically tracks session data within the jos_session table, when i see you've determined. However, it is simple to disable this by visiting your admin panel - Global Configuration - System - Session Configurations and alter the session handler from "database" to "None".

I'd this same issue and desired to disable guest periods in frontend but retain periods in after sales. Too i discovered that google along with other bots make plenty of page request after which create session and our session table was gettin too large.

Solution (Not too nice, but works)

I changed function place (libraries/joomla/database/table/session.php)

with

 function insert($sessionId, $clientId) {

 $url = 'http://'.$_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"];

 $this->session_id  = $sessionId;

 $this->client_id   = $clientId;

 $this->time = time();

 if ($this->guest!=1 || stristr($url,'/administrator'))
      $ret = $this->_db->insertObject( $this->_tbl, $this, 'session_id' );

 if( !$ret && $this->guest!=1) {
      $this->setError(strtolower(get_class( $this ))."::". JText::_( 'store failed' ) ."<br />" . $this->_db->stderr());
      return false;
 } 
 else {
      return true;
 }
 }

I most likely discovered the solution:

You can include another argument towards the line in /index.php

/**
* CREATE THE APPLICATION
*
* NOTE :
*/
$mainframe =& JFactory::getApplication('site');

change this line as

$mainframe =& JFactory::getApplication('site',array('session'=>false));

This can close session handling in frontend only, and you also can set session handler to some cache mechanism like APC,Memcache.I favor APC.