The following rules apply to ending a session and deleting Session scope variables:
<cfset StructClear(Session)>
cflogout
tag to log users out.
<cfset getPageContext().getSession().invalidate()>
This line creates a pointer to the servlet page context and calls an internal method to reset the session. This clears all session information, including the session ID Session scope variables, and if you are using session login storage, the login information, for future request. However, the session information does remain available until the end of the current request. After you invalidate a session, attempts by the browser to access the application will generate an invalid session exception until the session times out.
Note: You cannot destroy the session and create a session on the same request, as creating a new session involves sending session cookies back.