-
Notifications
You must be signed in to change notification settings - Fork 42
Initial PR for extension module migration #67
Conversation
However, the tests will no longer catch when a core change breaks something in a module. Trading test time for more bugs and time spent investigating and fixing them. |
Yes, this is a trade-off that I feel is worth considering. Given the time spend on pushing PRs through, I feel that the preservation of more time and the distribution of testing should free up more time to address these bugs and issues. But it is a resource shuffle we are cognizant of. |
Moving away from "batteries included" increase the complexity of installing the minion. Unless also extensions can be installed on the Master, and the minions fetches any extensions on start-up (possible pip dependencies as well). Currently including batteries solves:
Possible solution for when "batteries" are removed is documentation of the best approach to cover the above operational issues (and how to set it up). On side note, thought we might of seen |
I tend to list multiple repos under file_roots and deploy via git checkouts, but I suppose it could also be built off of spm |
That's definitely a valid concern. Honestly I'm more concerned about extension modules stomping on each other, though. But those are still problems we (can) have today. I've seen a number of bugs that were tracked down to a custom module that conflicted with a pre-existing Salt module. And some of our modules don't have a whole lot of tests today. The way that I envision this working is that extension module maintainers would test their module against the current LTS (if that happens), main release, and development branch of Salt. Similar to how Python modules can use nox or tox to test against multiple versions of Python. So one might have the following nox test setups:
Something to that effect. Then if bugs are detected that should not be then the module maintainers can file an upstream bug with Salt. Of course if it's something that's properly deprecated and then removed from the main Salt codebase then obviously the module should correctly handle that, but hopefully that should be few and far between at this point (most of the removals and deprecations I'm aware of have been driven by underlying modules changing or other changes in the underlying systems, not just Salt changing) I would like to see some much clearer guides/documentation for how to extract a module from Salt and turn it into an extension, though, as a requisite for this effort. I've done some with the https://github.com/saltstack/salt-extension project, but it's probably closer to 80% there than 100%, and there isn't a super great tutorial/walkthrough that we can point folks to, either. |
I'm cautiously positive on this, but it all depends on how the transition is going to be executed. Plus, there are a couple of aspects that will be hard to address:
|
Thanks Max, let me try to discuss a few of these
|
@max-arnold I would say that we're both in the same boat 🙂
|
I think @myii can add something valuable here given his experience with using salt formulas as an integration test suite for Salt |
Is https://github.com/saltstack/salt-extension still envisioned as part of this? saltstack/salt-extension#15 for error with current template output Also to the point someone else made. It would be really nice if extensions installed on the master synced down any states/modules/utils needed to the minion side. It feels like a bit of a regression to have to also install the same extensions on the minions. |
A little note: currently the https://extensions.saltproject.io index is not being updated. When the time to put this SEP into action will arrive, it also makes sense to allocate some development resources to fix and improve the extension index. See this Slack thread for more context on what is broken. |
Maybe this move could be the groundwork for some better support of "extensions" which aren't just write a function which expects these arguments but instead expect some data structure as in and output from these extensions. Which would potentially allow users to write their extensions in whatever language they want. And in the far future maybe include other stuff like states, renderers, since these also "basically" are outputting state in a data structure. The reason for saying this is because I doubt this will be pleasant for anyone since there is a lot of salts magic objects, variables. |
A request to migrate the modules inside the Salt repo into external repos for better maintenance