Skip to content

Doc: Align server and simulator narrative post-#2895#2896

Merged
janiversen merged 2 commits into
pymodbus-dev:devfrom
FedericoMusa:doc-server-simulator-convergence
Mar 10, 2026
Merged

Doc: Align server and simulator narrative post-#2895#2896
janiversen merged 2 commits into
pymodbus-dev:devfrom
FedericoMusa:doc-server-simulator-convergence

Conversation

@FedericoMusa
Copy link
Copy Markdown
Contributor

Hi @janiversen,

This PR addresses a few narrative inconsistencies following the merge of #2895 to ensure the documentation fully reflects the architectural shift toward the unified DataModel.

Changes:

server.rst: Added a brief note explaining that the server now utilizes the simulator's engine as its standard datastore. This provides context for the :ref:Datastore definitions link that now points to the simulator.

simulator3.rst: Updated the text to clarify that the simulator core is being integrated into the server, rather than just removed. This aligns the documentation with the current usage of SimDevice in the base server tests.

datamodel.rst: Minor cleanup to ensure the transition from legacy DataBlocks to the new SimData workflow is clear for users.

The goal is to provide a cohesive explanation for the 3.9/4.0 transition without changing any functional logic.

All files checked for trailing newlines (Ruff/POSIX).

Copy link
Copy Markdown
Collaborator

@janiversen janiversen left a comment

Choose a reason for hiding this comment

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

A smaller number of corrections.

Comment thread doc/source/server.rst Outdated
Datastore for server
--------------------
.. note::
The legacy datastores have been replaced by a unified DataModel based on
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

They have not been replaced but will be in v.
4.0.0

Comment thread doc/source/server.rst Outdated
--------------------
.. note::
The legacy datastores have been replaced by a unified DataModel based on
the Simulator engine. This ensures consistent data handling across all
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I do not understand this. Nor the existing data stores nor the SimData very between different server types.

Comment thread doc/source/simulator3.rst Outdated
The purpose of the simulator is to provide support for client
application test harnesses with end-to-end testing simulating real life
modbus devices.
The purpose of this integration is to provide a single, robust way to handle modbus registers for both standard servers and simulation environments.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

A simulator is a standard server with http additionally.

Comment thread doc/source/simulator3.rst Outdated
The purpose of this integration is to provide a single, robust way to handle modbus registers for both standard servers and simulation environments.

The datastore simulator allows the user to (all automated)
The unified datamodel allows the user to:
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

"unified data model" is not an objetive of the datastore. The objective is to provide a more flexible data definition.

Comment thread doc/source/simulator3.rst Outdated
- simulate a modbus device by adding a simple configuration,
- test how a client handles modbus exceptions,
- test a client apps correct use of the simulated device.
- Define a modbus device using the new ``SimDevice`` architecture.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

"new" should be removed.

@janiversen
Copy link
Copy Markdown
Collaborator

Currently the datastore simulator exist in parellel to the old datastores and that will not change in the short term.

v4 is probably not sooner then end of the year.

@FedericoMusa FedericoMusa force-pushed the doc-server-simulator-convergence branch from 4efb876 to f0445e2 Compare February 25, 2026 15:19
@FedericoMusa
Copy link
Copy Markdown
Contributor Author

Hi @janiversen, PR updated with the following corrections:

Removed 'unified data model' in favor of 'flexible data definition'.

Clarified that legacy datastores will be replaced in v4.0.0 (parallel existence maintained for now).

Removed wording about datastore variance between server types.

Added simulator definition as a standard server with an additional HTTP interface.

Removed the word 'new' from architecture descriptions.

All files checked for Ruff/POSIX compliance.

Copy link
Copy Markdown
Collaborator

@janiversen janiversen left a comment

Choose a reason for hiding this comment

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

Sorry to be picky, but as you yourself pointed out, it is important that the documentation is clear, understandable and correct.

I try only to be picky, with the technical details, because the should be correct. You have a better writing than I do, but you still need to understand the technical details.

Comment thread doc/source/server.rst Outdated
Datastore for server
--------------------
.. note::
The legacy datastores will be replaced in v4.0.0 by a more flexible
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

would it not be better, to write directly "by SimData/SimDevice" (already available), instead of having readers guess.

Comment thread doc/source/simulator3.rst
Comment thread doc/source/simulator3.rst Outdated
Comment thread doc/source/simulator3.rst Outdated
@janiversen
Copy link
Copy Markdown
Collaborator

Maybe you are confused about the modules.

A running server uses 2 modules:

  • datastore (SimData/SimDevice + the old datastores)
    (physically stored in module: datastore and simulator)
  • server (physically stored in module: server)

A running simulator uses the above and:
- http simulator (physically stored in module: simulator)
- typescript and html needed

so SimData/SimDevice is just another datastore not more and not less.

And as you correctly write, mid-term the old datastores will be removed or replaced as you write.

Mid-term module: datastore and server will also be removed and the whole server/simulator will be in module simulator,
but that is not something users should concern themselves with.

@FedericoMusa
Copy link
Copy Markdown
Contributor Author

Jan, I really appreciate your detailed explanation and the insights into the long-term module migration. It helps a lot to understand that the goal is a complete consolidation into the simulator module.
You are right about clarity; there is no point in making the reader guess when the solution is already available. I will update the documentation to explicitly mention SimData/SimDevice as the current and future replacement for legacy datastores.
Thank you for the guidance on the technical details. I'll make the final adjustments now to ensure the wording is both clear and technically precise.

@janiversen
Copy link
Copy Markdown
Collaborator

Thanks.

@FedericoMusa
Copy link
Copy Markdown
Contributor Author

You´re welcome.

@FedericoMusa FedericoMusa force-pushed the doc-server-simulator-convergence branch from f0445e2 to 788e8b6 Compare February 25, 2026 19:13
@janiversen
Copy link
Copy Markdown
Collaborator

Still working on this ?

@FedericoMusa
Copy link
Copy Markdown
Contributor Author

Hi Jan! Sorry for the delay, I missed that the branch had fallen out-of-date with dev.

I've just updated the branch, and all 18 CI checks are now passing. The technical adjustments from commit 788e8b6 are ready for your final review:

server.rst: Explicitly mentions SimData/SimDevice as the replacement.

simulator3.rst: Updated with the 'flexible data definition' terminology and the standard server remark.

Thanks for your patience!

Copy link
Copy Markdown
Collaborator

@janiversen janiversen left a comment

Choose a reason for hiding this comment

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

I see you updated to the newest dev, but I cannot see that you have solved the comments I gave earlier.

Comment thread doc/source/simulator3.rst Outdated
Comment thread doc/source/simulator3.rst Outdated
The core logic of the simulator (SimDevice/SimData) is being integrated into the base server to provide a more flexible data definition.

The datastore simulator allows the user to (all automated)
The purpose of this integration is to provide a flexible data definition for both standard servers and simulation environments.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Which integration ? I think you talk about SimDevice/SimData, but they are not an "integration".

Comment thread doc/source/simulator3.rst
Comment thread doc/source/simulator3.rst Outdated
@FedericoMusa FedericoMusa force-pushed the doc-server-simulator-convergence branch from 268dbcc to 43e7d49 Compare March 9, 2026 19:42
@FedericoMusa
Copy link
Copy Markdown
Contributor Author

Hi Jan! I've updated the branch and applied the fixes in commit 43e7d49.

I restored the 'purpose' section in simulator3.rst to maintain the 'why' for new users.

I reverted the unnecessary change in the REST API link to keep the diff clean.

All 18 checks should be green shortly. Ready for your final review!

Comment thread doc/source/simulator3.rst Outdated
Comment thread doc/source/simulator3.rst Outdated
The core logic of the simulator (SimDevice/SimData) is being integrated into the base server to provide a more flexible data definition.

The datastore simulator allows the user to (all automated)
The purpose of this integration is to:
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

there are no "integration".....it is "simulator".

@FedericoMusa FedericoMusa force-pushed the doc-server-simulator-convergence branch from 311588b to a67f67f Compare March 9, 2026 22:13
@FedericoMusa
Copy link
Copy Markdown
Contributor Author

I've applied the final corrections in commit 43e7d49.

Updated the text to state that the logic is fully integrated into the server.

Focused the purpose section directly on the simulator, removing the term 'integration'.

Restored the user-facing 'why' (testing exceptions and client logic).

Everything should be aligned with the current architectural state now. Ready for the merge!

@janiversen janiversen merged commit c3525d6 into pymodbus-dev:dev Mar 10, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants