|
JSP files and the files they import execute in isolation from all other requests to the same files. In addition, their statements are reevaluated for each request. The static statement lets the developer execute a statement only once or to share information between requests
Requests are still isolated from each other. All JavaScript objects created or modified in a static statement are copied for each request. Since wrapped Java objects are not copied, developers can use static statements in combination with wrapped Java objects to create application objects. In general, Java used as application objects will need synchronization to keep the state consistent between request threads
|