-
Notifications
You must be signed in to change notification settings - Fork 58
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Swagger server from schema? #190
Comments
We had discussion about it few years back #81 It should be possible (just need to choose correct target like Giraffe for example) |
There are some clear advantages of TP vs any kind of code-generation templates:
|
What if you do not commit generated code? It should prevent modification of generated code. The primary cons of TP is speed, number of times IDE call it and all-time schema availability requirement (like DB connection). What's may go wrong if codegen generate contract/interface that you have to implement in your controllers and you will not commit these files? |
If you don't let modifications to the generated code, then that's a compiler, not a code-generator. Which is nice, if possible. But typically issues are easier to fix to the generated code, and the hard way to fix is to modify the initial template. (Reverse-engineer the source location, etc.) Quoting (freely) the book "Microsoft .NET - Architecting Applications for the Enterprise":
|
Is there an ongoing effort to do schema to server? Can I attempt to do this? Any lessons you can share before i lose my sanity trying? |
This might be bit off-topic, but still with Swagger and F#:
Right now OpenApiProvider/SwaggerProvider generates the clients from the schema.
Is there a way to generate a server (/server-template) from the schema?
Any kind of Owin/Katana/.NET WebApi, or something F# specific like Giraffe templates?
Current tools seem to be generating a schema from server, but what about generating a server from schema, is there any tools for that? What is the current best practice?
The text was updated successfully, but these errors were encountered: