Conversation
Co-authored-by: José Iván López González <jlopez@suse.com>
By adding a new query for the system endpoint and consuming data from there. Previous "system" query has been moved to "hostname", which most probably will dissapear once hostname is ported to the new API and, most probably, served as part of the system.
Forgotten in commit dbf9e73
Read the FIXME in the code to know more.
Apart from fixing some wrong keys after a backend update.
- Some code is commented in the supervisor until l10n is able to dispatch the required actions (e.g., apply config).
* Replace the current implementation of the "run" function.
3447dbd to
a2dce67
Compare
a2dce67 to
7540489
Compare
Merged
imobachgs
added a commit
that referenced
this pull request
Oct 6, 2025
Update the changes files according to the changes introduced in #2715.
teclator
added a commit
that referenced
this pull request
Nov 11, 2025
## Problem There is a new config based HTTP API and all the services needs to be adapted. The aim of this PR is to adapt the network backend service (replace #2840). - #2715 ## Solution In the new architecture all the Agama modules will live in its own package implementing the actors/service as described in (#2715), but as network was already using a actors model using an enums approach it was decided to use the current service in the first iteration of changes. ### Changes done - Added the actions for getting the system, proposal and current network configuration using the actual actions passing messages system based on enums. - All the structs or types that are related to the API (needs to be serialized) has been moved to agama-utils, it was decided to not depend on agama-lib anymore. The types will be re-exported to be used by agama-network when needed. - As the current merge is concatenating the connections array, the patch **(updateConfig)** will replace the connections with the given one when present, but is something we need to revisit and decide how to do it in a better way. - Removed the network web service. - As the proposal, system info and config contains similar collections and just change the absence or presence of some of them we have introduced the **NetworkCollection** and **NetworkConnectionCollections** in order to do the conversion between them. ### TODO - Move to the actors/service model using traits instead of enums and adding the issues and progress monitor to the network service. - Remove all the actions which are not needed anymore (old network web service). - Add unit tests covering the new approach.
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.
This pull request introduces two big changes:
l10nmodule. Bear in mind that the specification is still a work in progress.l10nmodule has been heavily reorganized to:The new HTTP API
Here is a brief explanation of how the new API should look like. For further details, check the ongoing description.
In general, it is designed around 3 main concepts:
Here is the API summary (check whether we have done some changes):
This new design allows us to drastically reduce the complexity and the amount of code needed by the old API.
Of course, we still need to extend it to support more use cases (software, DASD, progress, etc.) but this one is a step in the direction we want to take.
The new architecture
Coming from a set of separate single-thread D-Bus services, we had have time to identify a few limitations that we would like to overcome in this redesign. Given that we expect several process to collaborate (holding configuration, listening for system changes, etc.) we want to implement something similar to an very simplified actor model.
With this idea in mind, each Agama module (localization, software, etc.) will live in their own package (e.g.,
agama-l10n,agama-software, etc.) implementing the corresponding actors/services.agama-utilscontains amodulewith some utilities to implement this pattern.Actors implementation
We started using the enum-based approach described in Actors in Tokio (really great). However, after some discussion, we decided to go with a trait-based approach. See the actors module for further information.