Patent attributes
Sessions states within virtual machine (VM) environments are maintained. Each VM environment hosts a guest operating system (OS) and one or more application programs running. The guest OS and the application computer programs of each VM environment constitute a session. A connection broker maintains a state machine as to states of the sessions and permits transitions among the states in response to messages, commands, and internal decisions. Different types of agents may send the messages, and the commands. The states of the sessions may include a pending state and a number of other states. The pending state is an interim state that indicates a session is being transitioned from one of the other states to another of the other states. These other states may include an offline state, an online-down state, an online-up state, a suspended state, an active state, an idle state, a disconnected state, and a failed state.