You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This dependency has proved itself to be problematic, so the generator implementation should be relieved of it. I'm thinking that it would be easiest for the consumers of this project if this rewrite took the form of a pure-Rust solution, however, I'm not yet convinced either way.
This could also open the door to improving the build system in this repository--currently, the generator is built using maven, and the whole thing is glued together with a Makefile. Perhaps there's an opportunity to generate the redfish-codegen crate using something like Bazel.
In the coming months, I'll try out a couple of solutions and begin work on this, and I'll try to keep this issue updated with progress.
A full Rust rewrite needs the following:
Primitive elements (e.g. case conversion) rewritten with unit testing.
text package
registry package
specification package
ModelMap implementation to map OpenAPI URIs to Rust paths. This should take the form of a Repository instead of the complicated to- and from- translational logic that exists today.
A primitive Rust expression builder to replace the existing Handebars template rendering scheme, which has only gotten increasingly complicated as time went on.
Build system improvements--the existing Makefile fails to be correct in surprising circumstances, is not hermetic, and relies on certain cargo keys to be set for the generated crates in order to allow uploading to crates.io. An improved system would generate a .crate file from the OpenAPI documents that can be uploaded independently to crates.io.
Model generation backend
Route generation backend for axum (that ideally can be extended to support additional frameworks in the future)
Registry generation backend
Generated crates contain the contents of existing, separate crates today. For example, the generated model crate under the new scheme would contain the contents of redfish-core.
The text was updated successfully, but these errors were encountered:
The resolution for this issue should also include a resolution for not just #3, but also #5, #6, #7, & #8, or at least lend itself easily to a resolution for these issues in any case.
This dependency has proved itself to be problematic, so the generator implementation should be relieved of it. I'm thinking that it would be easiest for the consumers of this project if this rewrite took the form of a pure-Rust solution, however, I'm not yet convinced either way.
This could also open the door to improving the build system in this repository--currently, the generator is built using maven, and the whole thing is glued together with a Makefile. Perhaps there's an opportunity to generate the redfish-codegen crate using something like Bazel.
In the coming months, I'll try out a couple of solutions and begin work on this, and I'll try to keep this issue updated with progress.
A full Rust rewrite needs the following:
text
packageregistry
packagespecification
packageRepository
instead of the complicated to- and from- translational logic that exists today..crate
file from the OpenAPI documents that can be uploaded independently tocrates.io
.axum
(that ideally can be extended to support additional frameworks in the future)redfish-core
.The text was updated successfully, but these errors were encountered: