You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Update the server-side api
* In theory, add disk stuff to the front end
* Working as dev environment
* shift config to individual views, tweak the CONTRIB docs, and add an example config
* Update the readme
* Update static/main.js to pass eslint, and create a single style entry
* Correct debugging mis-naming
* Replace missing semicolon..
* fix: Compute disk warning state with config.disk_warning_threshold
* feat: Add model class for keeping resource warnings
* feat: Condition to flash warnings no looks at all computed warnings
* chore: Run lint fix
* chore: Run lint fix again
* chore: Address critical and high dependabot flagged packages
* task: remove console log
Co-authored-by: Michał Krassowski <[email protected]>
* Update CONTRIBUTING.md
Co-authored-by: Michał Krassowski <[email protected]>
* Fix typo in CONTRIBUTING.md
Co-authored-by: Michał Krassowski <[email protected]>
* Fix typo in README.md docs
Co-authored-by: Michał Krassowski <[email protected]>
* Fix server extension docs language
Co-authored-by: Michał Krassowski <[email protected]>
* Fix typo regarding disk warning thresholds
Co-authored-by: Michał Krassowski <[email protected]>
* Catch Exception instead of nothing at all
Co-authored-by: Michał Krassowski <[email protected]>
* Update docs and delete example server config
---------
Co-authored-by: Ian Stuart <[email protected]>
Co-authored-by: Michał Krassowski <[email protected]>
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+8Lines changed: 8 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -127,6 +127,14 @@ JupyterLab v3.0.0
127
127
jupyter-resource-usage v0.1.0 enabled OK
128
128
```
129
129
130
+
## Which code creates what content
131
+
132
+
The stats are created by the server-side code in `jupyter_resource_usage`.
133
+
134
+
For the jupyterlab 4 / notebook 7 UIs, the code in `packages/labextension` creates and writes the content for both the statusbar and the topbar.
135
+
136
+
The topbar is defined in the schema, whilst the contents of the statusbar is driven purely by the labextension code.... and labels are defined by their appropriate `*View.tsx` file
137
+
130
138
## pre-commit
131
139
132
140
`jupyter-resource-usage` has adopted automatic code formatting so you shouldn't need to worry too much about your code style.
Copy file name to clipboardExpand all lines: README.md
+20-1Lines changed: 20 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -134,6 +134,23 @@ memory:
134
134
135
135

136
136
137
+
### Disk [partition] Usage
138
+
139
+
`jupyter-resource-usage` can also track disk usage [of a defined partition] and report the `total` and `used` values as part of the `/api/metrics/v1` response.
140
+
141
+
You enable tracking by setting the `track_disk_usage` trait (disabled by default):
142
+
143
+
```python
144
+
c = get_config()
145
+
c.ResourceUseDisplay.track_disk_usage =True
146
+
```
147
+
148
+
The values are from the partition containing the folder in the trait `disk_path` (which defaults to `/home/joyvan`). If this path does not exist, disk usage information is omitted from the display.
149
+
150
+
Mirroring CPU and Memory, the trait `disk_warning_threshold` signifies when to flag a usage warning, and like the others, it defaults to `0.1` (10% remaining)
151
+
152
+

153
+
137
154
### Disable Prometheus Metrics
138
155
139
156
There is a [known bug](https://github.com/jupyter-server/jupyter-resource-usage/issues/123) with Prometheus metrics which
@@ -157,9 +174,11 @@ render the alternative frontend in the topbar.
157
174
Users can change the label and refresh rate for the alternative frontend using settings
158
175
editor.
159
176
177
+
(The vertical bars are included by default, to help separate the three indicators.)
178
+
160
179
## Resources Displayed
161
180
162
-
Currently the server extension only reports memory usage and CPU usage. Other metrics will be added in the future as needed.
181
+
Currently the server extension reports disk usage, memory usage and CPU usage. Other metrics will be added in the future as needed.
163
182
164
183
Memory usage will show the PSS whenever possible (Linux only feature), and default to RSS otherwise.
0 commit comments