Skip to content

Conversation

@zmoore-usgs
Copy link
Contributor

PR checklist

  • Read the contribution guidelines.
  • Ran the shell script under ./bin/ to update Petstore sample so that CIs can verify the change. (For instance, only need to run ./bin/{LANG}-petstore.sh and ./bin/security/{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\.
  • Filed the PR against the correct branch: master for non-breaking changes and 2.3.0 branch for breaking (non-backward compatible) changes.

Description of the PR

In the same vein as (and following the pattern established by) #5384 this converts instantiation-types, type-mappings, language-specific-primitives, additional-properties, and reserved-words-mappings to lists and moves them outside of configOptions, while still maintaining backwards compatibility. Fixes #6062

This adds support to having configuration like this (same example from #5384 converted to show type mappings):

<configuration>
    <typeMappings>
        <param>json_mymodel=com.mypackage.MyModel</param>
        <param>json_anothermodel=com.mypackage.AnotherModel</param>
    </typeMappings>
</configuration>

…additionalProperties, and reservedWordsMappings out of configOptions and converting it into a list, rather than being a comma-separated string.
@fehguy
Copy link
Contributor

fehguy commented Jul 14, 2017

Please see my comment on the linked issue.

@fehguy fehguy closed this Jul 14, 2017
@zmoore-usgs
Copy link
Contributor Author

@fehguy My implementation does handle the old format as well, in the same way as #5384 which was merged.

See https://github.com/swagger-api/swagger-codegen/pull/6063/files#diff-728390e70cc7f684e2ecec961cd583ffR438 and the functions around it.

@fehguy
Copy link
Contributor

fehguy commented Jul 14, 2017

Hmm how did i miss this :-S

@fehguy fehguy reopened this Jul 14, 2017
@fehguy
Copy link
Contributor

fehguy commented Jul 14, 2017

The travis PR failed with:

-> running reinstall
[ERR!] GitHub API: GitHub rate limit reached.
    To increase the limit use GitHub authentication.
    See: https://github.com/DefinitelyTyped/tsd#tsdrc

I'm boldly going to merge regardless, after looking at the remaining tests (they have nothing to do with this PR).

cc: @wing328 as a FYI

@fehguy fehguy merged commit d065a6a into swagger-api:master Jul 14, 2017
@zmoore-usgs
Copy link
Contributor Author

Thanks for the responsiveness on this PR!

@fehguy fehguy added this to the v2.2.3 milestone Jul 14, 2017
@zmoore-usgs zmoore-usgs deleted the feature/move-config-options branch July 17, 2017 14:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants