What is a Coldfusion session?

I have been using Coldfusion sessions for quite some time, so I know how they are used , but now I need to know how they work , so that I can plan to scale my site.

Is a Coldfusion session a β€œsession” just a quick way to set up 2 cookies (CFTOKEN and CFID) and the associated server-side memory structure? (SESSION area) Does this do anything else? I am trying to determine the overhead associated with user sessions and other methods such as cookies.

+5
source share
4 answers

Your understanding of them is basically correct. Although they are not tied to cookies. Cookies are a token record. This token can be passed in the url string if cookies are not enabled in the browser.

There are two main benefits that I see in storing things in a session instead of cookies:

  • You control the session area. People cannot edit data in the session area without providing them with an interface. Cookies are subject to change by the client.
  • Complex data can be stored there, such as structures, arrays, objects, network sessions (FTP, exchange).

Their memory overhead is "low" but a relative term. Use the ColdFusion Admin Server Monitor to maximize how much memory your session is using.

+10
source

, Session - : , . , " ", , (, , ) cookie.

-, : onSessionStart() onSessionEnd().

-, : CF CF J2EE.

+2

- , jvm. () . , ( , ..), , .

+2

, , , : 20 (). , , ColdFusion Administrator.

If memory usage is a concern, the time limit may be reduced, although much still depends on the Java garbage collection.

+2
source

All Articles