docs(device-state): document profile-level inactivity timeout#426
Open
zzzeebra wants to merge 1 commit into
Open
docs(device-state): document profile-level inactivity timeout#426zzzeebra wants to merge 1 commit into
zzzeebra wants to merge 1 commit into
Conversation
5 tasks
Adds documentation for the new Device Profile "Device inactivity timeout" field introduced by thingsboard/thingsboard#15527, and updates existing inactivity timeout references to reflect the three-tier resolution: per-device server attribute → device profile → global default. - user-guide/device-profiles: new "Device inactivity timeout" section with unit selector, resolution order, and propagation behavior. - user-guide/connectivity-status: expand Aside to the three-tier hierarchy; rewrite Inactivity Detection paragraph; fix TB_TRANSPORT_SESSIONS_INACTIVITY_TIMEOUT default 300000 -> 600000 to match thingsboard.yml. - recipes/device-inactivity-alarm: replace yml-property reference with env var; split Step 1 into Option A (device profile, recommended) and Option B (per-device override). - edge/reference/configuration/rule-engine-config: tighten the defaultInactivityTimeoutInSec description and mention the new three-tier resolution. Note: core-rule-engine-config.mdx (CE+PE) is auto-generated from application/src/main/resources/thingsboard.yml comments by scripts/generate_config_pages.py, so it is updated in the platform yml as part of the matching CE PR rather than edited here.
b460ed3 to
de7660c
Compare
There was a problem hiding this comment.
Pull request overview
This PR updates the ThingsBoard documentation to cover the newly introduced Device inactivity timeout field on Device Profile Details and to consistently explain the three-tier inactivity timeout resolution (per-device attribute → profile field → global default) across user guides, recipes, and Edge configuration reference pages.
Changes:
- Added a new Device inactivity timeout section to Device Profiles docs and linked it from the Profile Details table.
- Expanded Connectivity Status docs to describe the full three-tier inactivity timeout hierarchy and updated the transport session inactivity timeout default to
600000. - Updated the Device Inactivity Alarm recipe and Edge rule engine configuration reference to reflect the three-tier resolution and env-var naming.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/content/_includes/docs/user-guide/device-profiles.mdx | Adds a new profile-level inactivity timeout section and links to it from the Details tab description. |
| src/content/_includes/docs/user-guide/connectivity-status.mdx | Documents the three-tier inactivity timeout resolution and updates the transport session inactivity timeout default value. |
| src/content/_includes/docs/recipes/device-inactivity-alarm.mdx | Refactors “set inactivity timeout” guidance into profile-level (recommended) vs per-device override options. |
| src/content/_includes/docs/edge/reference/configuration/rule-engine-config.mdx | Updates the global inactivity timeout parameter description to include the three-tier resolution order. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
|
||
| ### Device inactivity timeout | ||
|
|
||
| Set how long a device may be silent before ThingsBoard marks it inactive. Choose the unit from the dropdown (seconds, minutes, hours, or days). Leave the field empty or set it to 0 to fall back to the global `DEFAULT_INACTIVITY_TIMEOUT` setting. |
| ## Inactivity Detection | ||
|
|
||
| A device is marked **inactive** when no activity is received for `DEFAULT_INACTIVITY_TIMEOUT` seconds (default: 600 s / 10 minutes). ThingsBoard checks all devices on a schedule controlled by `DEFAULT_STATE_CHECK_INTERVAL` (default: 60 s). | ||
| A device is marked **inactive** when no activity is received within its effective inactivity timeout. ThingsBoard resolves the value per device in this order: per-device `inactivityTimeout` server attribute (milliseconds), then the device profile's **Device inactivity timeout** field, then the global `DEFAULT_INACTIVITY_TIMEOUT` (seconds, default 600 s / 10 minutes). ThingsBoard checks all devices on a schedule controlled by `DEFAULT_STATE_CHECK_INTERVAL` (default: 60 s). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Documents the new Device inactivity timeout field on the Device Profile Details page (introduced by thingsboard/thingsboard#15527) and updates existing inactivity timeout references to reflect the three-tier resolution.
Effective inactivity timeout per device, in priority order:
inactivityTimeoutserver-side attribute (milliseconds)DEFAULT_INACTIVITY_TIMEOUTfallback (seconds, default 600)Files changed
user-guide/device-profiles.mdx— new "Device inactivity timeout" section (unit selector, resolution order, profile-update propagation). Profile Details table row updated with anchor link.user-guide/connectivity-status.mdx— Aside expanded from per-device-only override to the full three-tier hierarchy with link to the new profile section. "Inactivity Detection" paragraph rewritten to mention all three sources. Drive-by bug fix:TB_TRANSPORT_SESSIONS_INACTIVITY_TIMEOUTdefault300000→600000to matchthingsboard.yml.recipes/device-inactivity-alarm.mdx— "Step 1. Set inactivity timeout" split into Option A (Device profile, recommended) and Option B (per-device override). Replacedstate.defaultInactivityTimeoutInSecyml-property withDEFAULT_INACTIVITY_TIMEOUTenv name per style guide.edge/reference/configuration/rule-engine-config.mdx— tightened the description ofstate.defaultInactivityTimeoutInSec; mentions the three-tier resolution.Test plan
Pairing
Pair with thingsboard/thingsboard#15527. If the field name or UX changes during code review on that PR, this PR will need to follow.