Introduction to multithreading and synchronization in LotusScript®

LotusScript® is thread safe; multiple LotusScript® Web agents can run concurrently within the Domino® server.

A thread is an instance of LotusScript®, in this case an agent. All threads execute in the same memory space. LotusScript® threads have no protection against updates on global variables or contention on the various internal data structures. By running multiple agents, you synchronize instances of LotusScript® running against each other.

LotusScript® agents run as separate threads in the same HTTP process. A process is a collection of one or more threads executing a single application.

Context switching is the act of saving the current state (hardware and software) and switching to another thread or process by restoring its state.

A time slice is the amount of time given to a thread or process to execute before switching context to the next thread or process.

A thread is blocked if a necessary resource is unavailable.

An atomic update is one in which another thread observing the update always sees a complete update and cannot interfere.