Update docs for Resource.Reconfigure removal [On Hold until v0.133.0]#5042
Update docs for Resource.Reconfigure removal [On Hold until v0.133.0]#5042Shannon Bradshaw (shannonbradshaw) wants to merge 3 commits into
Conversation
✅ Deploy Preview for viam-docs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
Hold: source change reverted. The RDK change this PR documents (viamrobotics/rdk#5944, Remove-Reconfigure) was reverted by viamrobotics/rdk#5997 on 2026-05-07. The #5997 PR description says: "To reland Remove-Reconfigure: revert this PR." So Remove-Reconfigure is expected to re-land in 1-2 weeks. Recommendation: Do not merge this PR until Remove-Reconfigure re-lands. Once it does, this PR's changes will be correct again and can be merged (possibly with minor updates if the re-land differs from #5944). Generated by daily docs change agent Generated by Claude Code |
|
Hey Shannon Bradshaw (@shannonbradshaw) — CI is green and no reviewer is assigned yet. Could you request one when you have a chance? Auto-comment from overwatch. Will not re-nudge for 7 days. |
2 similar comments
|
Hey Shannon Bradshaw (@shannonbradshaw) — CI is green and no reviewer is assigned yet. Could you request one when you have a chance? Auto-comment from overwatch. Will not re-nudge for 7 days. |
|
Hey Shannon Bradshaw (@shannonbradshaw) — CI is green and no reviewer is assigned yet. Could you request one when you have a chance? Auto-comment from overwatch. Will not re-nudge for 7 days. |
Daniel Botros (danielbotros)
left a comment
There was a problem hiding this comment.
LGTM, but I would hold off on merging since we reverted the linked PR to let the additional fixes bake and will land the actual remove reconfigure in the next week or so.
| @@ -240,12 +240,16 @@ if __name__ == '__main__': | |||
|
|
|||
| The default behavior when you don't implement a method: | |||
|
|
|||
| | Behavior | Go | Python | | |||
| | ------------------------ | ------------------------------------------------------------ | ---------------------------------------------------------------------------------------- | | |||
| | Rebuild on config change | Default (`viam-server` destroys and re-creates the resource) | Default (`viam-server` destroys and re-creates the resource) | | |||
| | In-place reconfigure | Not supported for modular resources | Implement `reconfigure()` (called if your class satisfies the `Reconfigurable` protocol) | | |||
| | No-op close | Embed `resource.TriviallyCloseable` | Default on `ResourceBase` | | |||
| | Skip config validation | Embed `resource.TriviallyValidateConfig` | Default on `EasyResource` | | |||
| | Behavior | Go | Python | | |||
| | ------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | | |||
| | Rebuild on config change | Default (`viam-server` destroys and re-creates the resource) | Default (`viam-server` destroys and re-creates the resource) | | |||
| | No-op close | Embed `resource.TriviallyCloseable` | Default on `ResourceBase` | | |||
| | Skip config validation | Embed `resource.TriviallyValidateConfig` | Default on `EasyResource` | | |||
|
|
|||
| `viam-server` always rebuilds modular resources when their configuration | |||
| changes. It removes the existing resource instance and creates a new one | |||
| using the constructor. In-place reconfiguration is not supported for | |||
| modular resources in any language. | |||
There was a problem hiding this comment.
The rebuild row doesn't really fit the structure of this table anymore since there is no default / not-default behavior, the behavior is to always rebuild. It can probably be dropped and the paragraph at the bottom explaining how modular resources are always rebuilt can do the explaining. Also, rebuilds happen when dependencies change as well, if worth mentioning.
nit: As an aside. this table structure was a little confusing to me. I interpreted as: default behavior if you don't implement a Close method is a no-op close, which embeds resource.TriviallyCloseable. But it should be conveyed the other way around. If you embed resource.TriviallyCloseable then you get the default behavior of a no-op close.
| | --------------------- | ----------------------------------------------------------------------------------- | | ||
| | `Ready` | Handshake: module returns its supported API/model pairs. | | ||
| | `AddResource` | Create a new resource instance from config. | | ||
| | `ReconfigureResource` | Rebuild an existing resource with new config (removes and re-creates the resource). | |
There was a problem hiding this comment.
I think this is clear as-is, and the distinction is mostly one of internal mechanics but since we mention:
In-place reconfiguration is not supported for modular resources in any language.
consider mentioning the name ReconfigureResource is retained for compatibility reasons for more clarity.
| Reconfigure this resource. | ||
| Reconfigure must reconfigure the resource atomically and in place. | ||
| For modular resources, reconfiguration destroys the existing resource instance and creates a new one using the constructor. |
There was a problem hiding this comment.
Maybe we can move away from the language of reconfigure towards reconstruction? i.e.
Reconstruct this resource.
For modular resources, reconstruction destroys...
|
Thanks, Daniel Botros (@danielbotros). Will hold off on merging. |
|
Hey Shannon Bradshaw (@shannonbradshaw) — this PR has been approved and CI has been green for 3+ business days. Ready to merge? Auto-comment from overwatch. Will not re-nudge for 7 days. |
|
Daniel Botros (@danielbotros) Thanks for the review. The three feedback points were already incorporated into the latest push:
On your nit about table framing: the header changed from "Behavior" to "To get this behavior" to make the direction clearer (embed X → get Y), though I understand the original framing was ambiguous. Important caveat: The Remove-Reconfigure change (rdk#5811/rdk#5944) that this PR documents is still reverted (rdk#5997). The current RDK behavior is in-place reconfiguration for modular resources, not the always-rebuild behavior this PR describes. I'll keep this PR on hold until Remove-Reconfigure re-lands. If the re-land changes the design (e.g., per your suggestion about reconstruction language), I'll update accordingly. Generated by daily docs change agent Generated by Claude Code |
|
Hey Shannon Bradshaw (@shannonbradshaw) — this PR has been approved and CI has been green for 9+ business days. Ready to merge? Auto-comment from overwatch. Will not re-nudge for 7 days. |
|
Hey Shannon Bradshaw (@shannonbradshaw) — this PR has been approved and CI has been green for 14+ business days. Ready to merge? Auto-comment from overwatch. Will not re-nudge for 7 days. |
|
Hey Shannon Bradshaw (@shannonbradshaw) — this PR has been approved and CI has been green for 20+ business days. Ready to merge? Auto-comment from overwatch. Will not re-nudge for 7 days. |
|
Daniel Botros (@danielbotros) mentioned this should make it in the June 30th release. Need to run a new check on the docs content |
|
Overlaps with #5111 — these should be consolidated. Both PRs rewrite the same The release gate isn't met yet — gate on the tag, not the date. The removal is not in a released rdk tag: latest is v0.132.0 (June 23), which still has If reconciling: this PR's prose paragraph (always rebuilds; not supported in any language) is the cleaner, language-agnostic table treatment — prefer it over #5111's "Not supported" row. But #5111's |
viam-server now always rebuilds modular resources (close + re-create) when their configuration changes. In-place reconfiguration via Reconfigure() is no longer supported for modular resources in any language. This removes the incorrect claim that Python modules can implement reconfigure() to handle config changes in place. Source: viamrobotics/rdk#5944 https://claude.ai/code/session_01Xd7GAtzjRzypiJK1amk4Uu
…nstruct language - Drop "Rebuild on config change" row from defaults table since rebuilds are universal, not a default-vs-custom behavior. Note dependency changes also trigger rebuilds. - Add compatibility note to ReconfigureResource RPC description. - Use "Reconstruct" language in sensor.Reconfigure override. https://claude.ai/code/session_01Xd7GAtzjRzypiJK1amk4Uu
…otographer fixes; fix ReconfigureResource wording Incorporates changes from #5111 so both PRs can be consolidated: - platform-apis.md: fix frontmatter "reconfigure functions" to "constructor" - filter-at-the-edge.md: fix "reconfigure method" to "constructor" - pet-photographer.md: Reconfigure -> reconfigure (private method) - module-reference.md: ReconfigureResource RPC is no longer called by viam-server (uses RemoveResource + AddResource instead); not labeled Deprecated since proto has no [deprecated = true] Per btshrewsbury-viam review: gate merge on v0.133.0 containing rdk#6098. https://claude.ai/code/session_01Xd7GAtzjRzypiJK1amk4Uu
45c5ae7 to
beabe1f
Compare
|
Consolidated in
Updated title and description to gate on v0.133.0 containing rdk#6098. Once this merges, #5111 can be closed. Generated by Claude Code |
|
Hey Shannon Bradshaw (@shannonbradshaw) — this PR has been approved and CI has been green for 3+ business days. Ready to merge? Auto-comment from overwatch. Will not re-nudge for 7 days. |

Source changes
Reconfigurefrom theResourceinterface; modular resources are now always rebuilt (close + construct) on config change.ReconfigureResourceRPC is no longer called byviam-server.Docs changes
docs/build-modules/module-reference.md: Simplified the Python/Go defaults table — removed the "Rebuild on config change" and "In-place reconfigure" rows (rebuild is now universal, not a default-vs-custom behavior). Added a prose paragraph clarifying thatviam-serveralways rebuilds modular resources when config or dependencies change. UpdatedReconfigureResourceRPC description: no longer called byviam-server, config changes go throughRemoveResource+AddResourceinstead. Not labeled Deprecated since proto has no[deprecated = true].docs/build-modules/platform-apis.md: Fix frontmatter description from "validate and reconfigure functions" to "validate function and constructor".docs/data/filter-at-the-edge.md: Change "reconfigure method" to "constructor" when describing how to access dependencies.docs/tutorials/configure/pet-photographer.md: Rename GoReconfigureto privatereconfiguresince it is no longer part of the public Resource interface.static/include/components/apis/overrides/protos/sensor.Reconfigure.md: Updated override text to use "Reconstruct" language.Consolidation
This PR now incorporates all changes from #5111. Once this PR merges, #5111 should be closed.
Merge gate
Do not merge until rdk v0.133.0 is tagged AND contains #6098. The latest tag (v0.132.0) still has
Reconfigureon theResourceinterface. Merging before the release would make docs wrong for the current shipped SDK.How I found these
search-patterns.yamlentry forResource.Reconfigurewith associated terms (AlwaysRebuild,ReconfigureResource, etc.)Reconfigure,reconfigure method,reconfigure functionacross docs repoGenerated by daily docs change agent