Commit Graph

11157 Commits

Author SHA1 Message Date
William Cheng
f664938d8e add back phplint tool: e75b115 2018-08-30 19:57:22 +08:00
William Cheng
9e45fbb13b Merge branch '3.3.x' of https://github.com/openapitools/openapi-generator into 3.3.x 2018-08-30 19:48:01 +08:00
William Cheng
3b2951b305 Merge remote-tracking branch 'origin/master' into 3.3.x 2018-08-30 19:39:09 +08:00
William Cheng
5745f6df70
Prepare 3.2.3 release (#935)
* update release version, disabled ensure up to date script

* update release table

* update stable version to 3.2.3

* update samples/meta-codegen/lib/pom.xml and release_version_update.sh
2018-08-30 19:08:03 +08:00
Matthieu Berthomé
d49fb1c777 StringUtils functions (#859)
* extract StringUtils

* extract escape function

* fixup! extract escape function

* forbiddenapis fix

* fix merge issue

* put string utils methods as deprecated, call with FQDN to call the org.openapitools.codegen.utils.StringUtils static methods

* javadoc fix
2018-08-30 15:56:04 +08:00
Jérémie Bresson
f4d7403ed6 [Java][JAXRS] improve generated readme (#920)
* [Java][JAXRS] improve readmes

* Update samples

* Update jersey readme

* Update jersey examples
2018-08-30 14:05:34 +08:00
Jérémie Bresson
f987306a15
Remove x-nullable extension support (#930) 2018-08-30 07:54:34 +02:00
osjupiter
62abd51a02 [all] add "x-enum-varnames" extension to control enum varname (#917)
* add "x-enum-varnames" extension to control the naming of the enum parameter name
* allow to set different size from target enum
2018-08-30 07:23:19 +02:00
William Cheng
b8db2af4bb
Update swagger annotation version in Java clients (#915)
* update swagger annotation version in java client

* add java retrofit2 play 2.6 to java petstore all bin script

* remove empty line in pom.xml
2018-08-29 16:43:41 +08:00
Jérémie Bresson
8e1e05e86c
[CLI] Improvements for meta and list command (#799) 2018-08-29 06:56:37 +02:00
William Cheng
09a62d7fef
Minor improvements to Kotlin Spring Boot generator (#918)
* minor improvement to kotlin sprinbboot generator

* add dr4ke616 to tech comm, add zalando to company list
2018-08-29 11:34:58 +08:00
Jim Schubert
2544ace262
[docker] Fixes hub dockerfile for online project (#914)
An update was made in #876 to remove version from the generated artifact
for openapi-generator-online. The change is missing the -online suffix.
My original glob pattern put the * in the wrong place for
maintainability.
2018-08-28 18:08:51 -04:00
William Cheng
a1205f6109
add https://www.boxever.com/ to the company list (#916) 2018-08-29 00:42:40 +08:00
lukoyanov
4558e49c7e [Java] Retrofit2 Play! Framework 2.6.x support (#901)
* added play framework 2.6 support

* generated petstore sample

* generated petstore sample #2

* generated petstore sample #3

* Revert "generated petstore sample #3"

* generated petstore sample #4

* fixed circleci configs

* one more time samples regen
2018-08-28 22:48:05 +08:00
Jack O'Sullivan
5926ee5f1f Add callback model (#861)
* Add callback model (#372)

This adds a new `CodegenCallback` class, a list of which is now present in
`CodegenOperation`. `CodegenOperation` now also includes a
`isCallbackRequest` boolean since `fromCallback()` (the method added to
`DefaultCodegen` to process operations which contain OpenAPI callbacks)
uses CodegenOperation as the model for a callback request.

A `CodegenOperation` which represents a callback request will have a
`null` operation id.

A test is included for this new model.

* Generate callback request `operationId`

* Add license to `CodegenCallback`
2018-08-28 21:10:13 +08:00
Adam Drakeford
8689227b3e [KOTLIN] Spring Boot Server Generator (#820)
* Kotlin Spring initial bootstrap

* Basic configuration construction for Kotlin Spring

* Wired up with comand line client

* Initial kotlin spring boot application generated using gradle kotlin-dsl

* Added basic support for generating models

* Basic controllers generated without endpoints generated

* Basic spring boot app generated with models and controllers

* Added fix for type mapping in AbstractKotlinCodegen. Originally it was mapping list o kotlin.Array instead of kotlin.collections.List

* Fixed return type mapping

* Sorted bash springboot petstore generator script

* Implemented toVarName in AbstractKotlinCodegen to better handle some edgecases

* Checking for reserved words or numerical starting class names in AbstractKotlinCodegen

* Implemented toOperationId in AbstractKotlinCodegen

* Fixed types that were not correctly being mapped to primitives (byte / arrayOf / mapOf)

* Escaping dollar symbols in function names

* Added support for outter enum classes

* Added basic support for generating services

* Removed option for generated config package. Added option to enable/disable generated global exception handler

* Added configuration option to generate gradle. Generated maven pom.xml file as default

* Fixed up bash scripts for generating test sample code

* Added configurable option for Swagger Annotations

* Added configurable option for generating service interfaces and service implementations

* Added README generation

* Enable optional bean validation

* Added kotlin spring sample to CircleCI pom.xml

* Removed kotlin spring boot from .gitignore

* Minor fixes from PR comments for user submission (#1)

* Minor fixes from PR comments for user submission

* Puts braces around conditional block bodies with one-liner bodies.
* Modifies README.mustache to use artifact id and version supplied by
user (or default configuration)
* Targets templates under resource directory explicitly to prevent the
need to rebuild for evaluation of  template-only changes.

* [kotlin-spring] Remove comments referencing sbt in bash scripts

* List of changes based upon code review:
* Additional comments around how we set the title based off the open api spec
* Fixed missing `beanValidationCore` template
* Put the lambdas into the lambda object as other generators do (Ktor, C#, cpp)
* Bump swagger-annotations version to latest pre-2.0 version (1.5.21)
* Set kotlin version to 1.2.60
* Updated README to set port based on template
* Added more additional properties to build bash scripts
* Removed `defaultBasePath.mustache` in place of using {{contextPath}} directly
* Log warning for when `serviceImplementation` is set t o true

* Updated samples

* Generating ConstraintViolation Exception Handler, as Springboot doesnt correctly catch the error and return bad request. Handling other exceptions a litle better

* Small fix for date time mappings (plus sample re-gen)

* Minor fix in README template, where port was using wrong variable

* Fix missing jackson-dataformat-xml dependency

* Fix build - needed to re-run kotlin-server-petstore.sh

* Fixes after merge with master

* Revert "Small fix for date time mappings (plus sample re-gen)"

This reverts commit 4152dc78b4813da71c675272ca90fb31a333aea1.

* Moved type mappings to Kotlin Spring generator

* Regenerated samples

* Regenerated samples
2018-08-27 23:54:53 +08:00
William Cheng
5cd5143b80
Add test case to detect stack overflow error (#904)
* add test case to detect stackoverflow errors

* use bash insted of sh
2018-08-27 20:46:50 +08:00
Jeremie Bresson
1ea0a1e856 Revert "[CI] Change the way gradle uploadArchives works (#902)"
This reverts commit e3bd47921c.
2018-08-27 10:51:51 +02:00
William Cheng
b505795bf7
use JsonIgnoreProperties to fix recursion (#903) 2018-08-27 16:14:35 +08:00
Jérémie Bresson
e3bd47921c
[CI] Change the way gradle uploadArchives works (#902) 2018-08-27 09:06:54 +02:00
Yuriy Belenko
e75b115244
[Slim] Add PHPLint tool to check syntax (#898)
* [Slim] Add phplint package to dependencies

There is no phplint package for PHP 5.5.0 version, so I have to increase
required PHP version to 5.5.9.

* [Slim] Update main doc

* [Slim] Refresh samples
2018-08-26 15:42:59 +05:00
Yuriy Belenko
15cec0ae09
[Slim] Add PHP CodeSniffer to check coding style (#897)
* [Slim] Add PHP CodeSniffer package

* [Slim] Add phpcsStandard generator option

We follow PSR-2 coding style guide in PHP generators. It might be convenient
for users to specify own coding standard without modifying templates. That's
why I've added this option.

At first, I thought to add option validation and accept only standards from
predefined list. But this option also can be a full path to the standard's
root directory, I've changed my mind. User should use this option with caution.

Ref to all PHP CodeSniffer CLI options:
https://github.com/squizlabs/PHP_CodeSniffer/wiki/Usage

* [Slim] Extend readme with PHP CodeSniffer docs

* [Slim] Format templates to meet PSR-2

* [Slim] Refresh samples
2018-08-26 15:26:09 +05:00
William Cheng
4401407c7c
remove eof from elm mustache template for better code format (#879) 2018-08-26 16:38:27 +08:00
Jeremie Bresson
267ffc0e2e Merge remote-tracking branch 'origin/master' into 3.3.x
Conflicts:
	modules/openapi-generator-online/Dockerfile
2018-08-26 08:26:07 +02:00
Jérémie Bresson
40d815946a
[CI] use regex to check if TRAVIS_BRANCH is a working branch (#899) 2018-08-26 08:22:17 +02:00
Hugo Barrigas
37fd4264ac [JAVA][Webclient] Add constructor to allow custom WebClient to be passed into ApiClient (#882)
* add constructor to allow custom webclient to be passed into ApiClient
2018-08-25 15:22:36 +02:00
Marco
39e9206976 [Java][Webclient] Init authentication on ApiClient instantiation (#887) 2018-08-25 14:22:16 +02:00
William Cheng
50c6ac34f1
Add x-nullable (OAS2) support (#889)
* add x-nullable oas2 support

* add test spec for testing x-nullable
2018-08-25 18:31:23 +08:00
sunn
6a00b2a802
[cpp-pistache] removed model namespace when unused for operations (#775)
* Remove using model namespace when model is unused
* Add comments to clarify introduction of hasModelImport at API/operations level instead of operation/vendorExtensions level.
2018-08-24 10:52:01 +02:00
Jérémie Bresson
010b469914
[build] create jar without version in openapi-generator-online (#876)
Simplify other scripts needing this jar
Consistent with openapi-generator-cli
2018-08-24 08:50:26 +02:00
sunn
f802f8b7d7
[qt5 server] various improvements (#725)
* Improve handling of all primitive types

* Fix missing includes in case of simple APIs

* Fix minor error in template function

* Remove tabs

* Refactor code for simplicity

* Remove tabs

* rework the router for handling multiple path param

* rework router to handle multiple path parameters

* rework router to handle multiple path parameters

* rework router

* Add support for Multi path param

* Add comments to code block and remove duplicate parameters

* Remove tabs :(

* Add missing imports after resolving conflict
2018-08-24 08:47:01 +02:00
Matiss
219a88e9c6 Add support for Api key in cookie for Symfony (#884) 2018-08-24 09:53:25 +08:00
Tomasz Prus
79dacb20a0 fix: python-asyncio/aiohttp with disabled ssl verification (#891) 2018-08-24 09:43:32 +08:00
William Cheng
704c1b8893 update petstore samples 2018-08-23 18:52:34 +08:00
William Cheng
8be06bc22d Merge remote-tracking branch 'origin/master' into 3.3.x 2018-08-23 18:21:44 +08:00
Navneet Karnani
f2b0adfa05 Nit: Language fix in README.md (#871)
* Nit: Language fix in README.md

Usage of "then" vs "than"

* update TS petstore samples
2018-08-23 17:33:38 +08:00
William Cheng
4830be0ea4
Fix Elm CI issue due to new version (0.19) installation (#877)
* update elm usage

* remove yes from elm script

* install elm 0.18

* add npm cache

* add gem env to travis

* add gem cache directory
2018-08-23 16:25:26 +08:00
William Cheng
4a5bd50202
add xml attr support in go client (#867) 2018-08-23 15:23:49 +08:00
William Cheng
6a47d49ee8
add nullable support (#873) 2018-08-23 10:51:57 +08:00
William Cheng
3d06900e68 Prepare 3.2.3-SNAPSHOT version (#870) 2018-08-22 13:39:20 +02:00
William Cheng
3259bf71e6
3.2.2 release (#869)
* run bin/utils/release_version_update.sh

* comment out ensure-up-to-date script

* run bin/utils/release_version_update_docs.sh

* fix link to lc3
2018-08-22 16:44:31 +08:00
Michael Kotten
526e980a69 [JAXRS] use contextPath variable for @ApplicationPath in RestApplication (#850)
* Use contextPath variable for RestApplication templates
* Update generated RestApplication.java files, as they are skipped by default otherwise
* Update Petstore sample for jaxrs so that CIs can verify the change
2018-08-22 09:15:08 +02:00
Jeremie Bresson
ab09909f99 Add missing import 2018-08-22 06:53:48 +02:00
Matthieu Berthomé
d8b597b168 [DefaultGenerator] consider referenced headers (#863) 2018-08-22 06:07:57 +02:00
Jens Oberender
9bc335b35e Forbiddenapis check and fix (#672)
* Added forbiddenapis check and fixed the findings in the normal code
* Fixed forbiddenapi findings in java templates and samples.
* Generated all samples for Java.
2018-08-22 06:06:01 +02:00
William Cheng
227f2779d7
escape various descriptions in the spec (#866) 2018-08-22 11:48:32 +08:00
William Cheng
2ffda45adf
Add https://www.suva.ch/ to the company list (#868) 2018-08-22 10:43:32 +08:00
marcotta
bb2712fe45 Use thread safe manager store dictionary (#864)
Fix crash due to concurrent access of managerStore dictionary.
Swift2 and Swift3 had been enhanced respectively with the following
pull requests: #3873 #5610
2018-08-22 02:27:40 +08:00
Jim Schubert
cbf61d5524 [docker] build files for automated builds (#836) 2018-08-21 23:08:24 +08:00
matthesrieke
39763a8ca7 fix unescaped description in requestBody (#857)
Fix unescaped description in requestBody
2018-08-21 22:28:32 +08:00