Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DOCS-1054: Add session management diagram to sessions page #1754

Closed
Show file tree
Hide file tree
Changes from 13 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added assets/program/viam-session-management.png
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can it live somewhere else too? If not let's change that wording

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No it should be in orbit of the session management client in this analogy, has to be

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you misunderstand me the image says "The user's sessions client can live here". That implies it can live somewhere else. It probably should be "The user's sessions client lives here"

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unless that's wrong?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do the heartbeats go both directions as indicated by the arrows? Or just one way?

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions docs/program/apis/sessions.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ Without session management, the API request from the client sets the flow of ele
With default configuration, sessions are automatically managed for you with Viam's `SessionsClient`.
If you want to manage sessions yourself, use Viam's sessions management API.

The session management API moderates `viam-server`'s client network connections.
You can think about a user as one of many clients that are connected to `viam-server` like a star in a solar system of application clients.
All stars (clients) are subject to forces of the planet (`viam-server`) and the sun ( the Session Management API), with the API being the larger force managing viam-server's clients' connection to the robot.
npentrel marked this conversation as resolved.
Show resolved Hide resolved
sguequierre marked this conversation as resolved.
Show resolved Hide resolved

{{<imgproc src="program/viam-session-management.png" resize="500x" declaredimensions=true alt="An analogy for Viam's session management API and viam-server's Robot APIs' partnership in managing client sessions within the Viam client ecosystem, with the API as a larger force managing viam-server's clients' connection to the robot. A star and its planet are pictured, with viam-server being the planet, orbiting the session management API but possessing many clients in its orbit itself.">}}

### The `SessionsClient`

A Viam robot has many clients because a client is anything that is receiving the information served by `viam-server` running on the robot, which includes the primary part, sub-parts, client SDKs, and more.
Expand Down
Loading