Session states
An openOBD session can be in one of five possible states. The five states, and the possible transitions between these states, are shown in figure 1.
When creating a new openOBD session, the session's state will be available.
The moment any communication occurs, authentication will first take place, and the session will transition to active.
From either of these states, it is possible for a session to become either interrupted or failed.
interrupted means that a session hasn't been gracefully stopped through gRPC, but has been stopped by other means,
for example by a call made through the Partner API, or by calling interruptSession.
failed means that a session has been stopped because of a server-side error.
The finished state can only be reached when an available or active session has been gracefully closed by a gRPC call.
When a session has transitioned to one of the final states (interrupted, finished, or failed) it is not possible to use the session anymore,
and the session's info will remain retrievable for two more minutes.
A new session will have to be started if further communication is desired.