I think I am on a roll this weekend! And I do not know how much of my previous errors I posted are related to this issue. A few months back I posted problem where the User Session would recreate itself on every page refresh. But not on some computers.
For instance, the dev pc I use would keep it’s session. But 2 other people who were testing my site ran into errors. When I got onto their machines and dumped the session, the sessionid would change with every refresh.
I tried setting Session Management from Memory to File
I went thru and clicked all the clear cache buttons I could find
I restarted Lucee
I restarted Tomcat
I restarted the Server.
I reset the Session Management back to Memory and I saw that the session on my dev machine did not change. It should have because I moved the management, no?
I went thru the Application.cfc thinking I had something weird in there. I cleared it all the way to (yes yes, it is still the old format, I will update it some day)
<cfcomponent displayname="Application" output="true" hint="Handle the application.">
<cfset THIS.Name = "Example.com" />
<cfset THIS.ApplicationTimeout = CreateTimeSpan( 0, 30, 0, 0 ) />
<cfset THIS.sessionTimeout = CreateTimeSpan( 0, 30, 0, 0 ) />
<cfset THIS.SessionManagement = true />
<cfset THIS.SetClientCookies = false />
<cfset THIS.defaultdatasource="mytable" />
<cfset THIS.javaSettings = {
loadPaths = [ expandPath('/libs/') ],
reloadOnChange=true,
watchInterval=600
} />
<cfset this.mappings['/authenticator'] = expandPath("/cfc/authenticator") />
<cfset this.mappings['/spreadsheet'] = expandPath("/cfc/spreadsheet") />
<!--- Define the page request properties. --->
<cfsetting requesttimeout="20" showdebug="no" enablecfoutputonly="no" />
</component>
And still the problem persisted. So I just loaded an empty Application.cfc and it complained there was no component… well I did delete it all. SO I added just the component part back and walla, the sessionid stopped changing after every refresh. My dev session also cleared out and loaded whatever Lucee’s Default Application settings are.
So, now that I fixed the problem, I need to know from someone who knows Lucee far better then I do, how to track down wtf just happened, when it happens again. Because it will. This is the 3rd time I can remember that it has happened.
Current Lucee specs (which are updated since last time this happened because of the new release of 7:
Lucee 7.0.2.106
Apache Tomcat/11.0.13
Java: 21.0.9 (Eclipse Adoptium) 64bit