-
-
Notifications
You must be signed in to change notification settings - Fork 7k
Beta server stub generator for F#/Giraffe #2705
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
Conversation
...penapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractFSharpCodegen.java
Outdated
Show resolved
Hide resolved
...i-generator/src/main/java/org/openapitools/codegen/languages/FsharpGiraffeServerCodegen.java
Outdated
Show resolved
Hide resolved
use CLI generator work on handlers add binding to url params add parameter declaration to handler & fix array types order models by dependency and add tests add oauth handlers add service generation add service implementation return json for map types and add all return types to service implementation pare down record types for readability move implementations to impl folder fix additional handler invocation remove logging remove open api type provider package reference add sane defaults for OAuth add readme and reorganize files for easier ignore fix oauth checks and move login to default template typedef operation body params as model add API test templates fix test templates set project & other folders when packageName is set add ignore to test pipes add ignore for oauth to hide compile warnings escape model types for generic dictionaries remove Boolean object from primitives fix handler and param templates for multiple path params remove "Model" from model module names and fix import mapping for dictionary add package name to model imports change model templates to use imports move login to CustomHandlers raise exception where oauth not properly configured allow webhost configuration from CustomHandlers remove explicit support for nullable types and render option in template instead move Cookie options to CustomHandlers add header params integrate api key provider add nullable to datetime types fix test generation and pretty up model folder add context path to handler test template dont copy spec file remove superseded copyright notices remove superseded copyright notices
<Compile Include="api/params/UrlParams.fs" /> | ||
<Compile Include="api/params/QueryParams.fs" /> | ||
<Compile Include="api/params/BodyParams.fs" /> | ||
<Compile Include="api/params/HeaderParams.fs" /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nmfisher Looks like these 4 files under api/params
are not yet added to the project (templates)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually that directory (samples/server/petstore/fsharp-giraffe/src) was the sample output directory from an earlier revision.
The proper output directory is samples/server/petstore/fsharp-giraffe/{{packageName}} (e.g. samples/server/petstore/fsharp-giraffe/OpenAPI)
I just forgot to remove the earlier version (samples/server/petstore/fsharp-giraffe/src) from the final commit. This is OK to delete - see nmfisher@ee4672e
Sorry about the CRLF - will configure git/IDE to stick with LF going forward. |
@nmfisher no worries. We've a script to catch these CRLF as part of the CI workflow. |
OK. I'll test again. If no more question from me, I'll merge it into the master to release a beta version so as to collect feedback from the community. |
Tests passed via https://travis-ci.org/OpenAPITools/openapi-generator/builds/527636181. The CircleCI failure is due to the outdated doc. I'll fix it with another PR after merging this into master.
|
* Beta server stub generator for F#/Giraffe (#2705) * first commit for F#/Giraffe use CLI generator work on handlers add binding to url params add parameter declaration to handler & fix array types order models by dependency and add tests add oauth handlers add service generation add service implementation return json for map types and add all return types to service implementation pare down record types for readability move implementations to impl folder fix additional handler invocation remove logging remove open api type provider package reference add sane defaults for OAuth add readme and reorganize files for easier ignore fix oauth checks and move login to default template typedef operation body params as model add API test templates fix test templates set project & other folders when packageName is set add ignore to test pipes add ignore for oauth to hide compile warnings escape model types for generic dictionaries remove Boolean object from primitives fix handler and param templates for multiple path params remove "Model" from model module names and fix import mapping for dictionary add package name to model imports change model templates to use imports move login to CustomHandlers raise exception where oauth not properly configured allow webhost configuration from CustomHandlers remove explicit support for nullable types and render option in template instead move Cookie options to CustomHandlers add header params integrate api key provider add nullable to datetime types fix test generation and pretty up model folder add context path to handler test template dont copy spec file remove superseded copyright notices remove superseded copyright notices * remove carriage return in fsharp template * remove superseded sample output directory * fix bash build script * update generated sample * update documentation * add new file * fix compile issues
PR checklist
./bin/
to update Petstore sample so that CIs can verify the change. (For instance, only need to run./bin/{LANG}-petstore.sh
,./bin/openapi3/{LANG}-petstore.sh
if updating the {LANG} (e.g. php, ruby, python, etc) code generator or {LANG} client's mustache templates). Windows batch files can be found in.\bin\windows\
.master
,. Default:3.4.x
,4.0.x
master
.Description of the PR
This is a beta server stub generator for F#/Giraffe as discussed in #2342.
Much of the OpenAPI specification is still unsupported, but this is mature enough to open up to the community for discussion/comments/contributions.