21 Commits

Author SHA1 Message Date
Philzen
2b9949a66b
Bump Jackson to latest v2.17.1 and sync in templates (#18799)
* Drop separate version property

Not required as all Jackson packages usually tether on a version bump.

* Update Jackson to v2.17.1

* Sync Jackson version used by Spring Boot with project version

* Sync jackson update to v2.17.1 with generator templates

* Regenerate samples with updated versions

* Adjust test to current exception msg behavior

* Add dependency mgmt to ensure matching version for transitive dependencies

* Update library descriptions with correct Jackson version number

* Update library descriptions with correct GSON and JSONB versions

* Update retrofit library description with correct version number

* Update retrofit description to include Jackson as an option

This should have been done as part of in #16853.

* Update remaining libary version descriptions with correct versions

* Generate updated doc
2024-06-02 15:17:38 +08:00
Horace Li
d0a8726580
[java][resttemplate] Fix missing javax validation imports with list validation (#18332)
* Fix java list validation

* Fix java list validation

* Fix java list validation

* Fix java list validation
2024-05-22 15:07:42 +08:00
Thorsten Hirsch
b67a019cf9
upgrade apache-httpclient to junit5 (#18616) 2024-05-09 09:54:32 +08:00
William Cheng
e17777044e
Use systemPropertyVariables in pom.xml (#18213)
* use system property variables in pom.xml

* update
2024-03-23 21:45:29 +08:00
martin-mfg
e3db882ed4
[JAVA][KOTLIN][SPRING] upgrade dependencies (#16759)
* upgrade spring-boot-starter-parent

* upgrade springdoc and swagger-ui

* upgrade v3 swagger-annotations

* generate samples

* upgrade jackson

* fix spring cloud, remove temp comment

Putting "8" instead of "1.8" should be ok, because Spring Boot 3 requires Java 17 anyway, so it should be able to understand that 8 is the same as 1.8.

* generate samples

* upgrade JUnit 5, remove commons-io dependency, remove outdated samples/client/petstore/java/feign/feign10x/ files, generate samples

commons-io dependency was introduced in https://github.com/OpenAPITools/openapi-generator/pull/8484, but I don't see why it would be needed now or back then.

* update gson, generate samples

* update logback

* update feign

* update scribejava

* generate samples

* update httpmime

* okhttp-gson: update commons-lang & okhttp & junit-platform, remove mockito; generate samples

It seems Mockito is not used at all there.

* okhttp-gson: remove unnecessary sample files, generate sample files

* upgrade google-api-client & jersey-common, restore ClientTest, generate samples

* misc. upgrades in jersey2 and jersey3

jersey 3.1.3 is available already, but IntelliJ reports security problems in 3.1.3 and 3.1.2, so I used 3.1.1 instead.

* align some gradle&sbt files with poms, generate samples

* whitespace fix
2023-10-09 14:55:32 +08:00
William Cheng
a4b5b85067
Update jackson nullable version to newer version v0.2.6 (#14823)
* update jackson nullable to newer version

* update samples

* update samples

* update samples
2023-02-27 18:38:31 +08:00
Andre Vegas
d7edbad8d6
[java][apache-httpclient] update httpclient dependency to the latest 5.x (#14673)
* #14672 - adding generator with apache http client 5

* #14672 - adding generator with apache http client 5

* #14672 - adding generator with apache http client 5

* #14672 - adding generator with apache http client 5
2023-02-15 15:12:39 +08:00
William Cheng
743202241e
[Java][native][apache-httpclient] update dependencies to newer versions (#14110)
* update java native dependencies to newer versions

* update java native, apache-httpclient to newer version
2022-11-24 23:55:14 +08:00
William Cheng
980062f2bb
Improve Java native, apache-httpclient with better spec (#14109)
* improve java native, apache client with better spec

* fix java native async tests

* regenerate java native tests
2022-11-24 21:48:09 +08:00
cachescrubber
5221682086
[Java][Client] Support annotationLibrary=none to remove swagger annotations (#13869)
* Support annotationLibrary=none in JavaClientCodegen

* Add example using annotationLibrary=swagger1

* Support annotationLibrary=none in libraries

* Fix missing curly brace.

* fix if statement condition

* Support {{#swagger1AnnotationLibrary}} in java/rest-assured

* Adopt JavaModelTest

* Generate docs

* Generate samples

* clean up java feign files

* clean up feign samples

* fix resttemplate, native

* fix resttemplate withXml

* fix webclient

* fix java-jersey2, vertix

* fix googleapi client

* fix rest assured

* fix rest assured

* update apache-httpclient

* fix jersey2 special character

* fix resteasy

* fix jersey2

* update samples

* fix jersey2, okhttp streaming

* update okhttp-gson

* update samples

Co-authored-by: William Cheng <wing328hk@gmail.com>
2022-11-04 17:07:46 +08:00
William Cheng
a68c36e932
Update jackson core and databind to newer versions (#13755)
* update databind to newer version

* update jackson version

* update dep

* revert jersey1
2022-10-21 10:14:37 +08:00
William Cheng
58f817276a Revert to c73704ce0832fc41210652399bfbb5f1668ec98a 2022-10-19 14:55:11 +08:00
William Cheng
de8d7e98c4 update databind to newer version 2022-10-19 14:52:18 +08:00
William Cheng
a34f992c95
update jackson databind to newer version (#12097) 2022-04-10 09:37:44 +08:00
Mikko Maunu
4374a63a4c
maven-compiler-plugin only once, because duplicates cause warnings (#12093) 2022-04-09 22:41:33 +08:00
William Cheng
683984896e
update maven-javadoc-plugin to newer version (#11737) 2022-02-27 16:57:16 +08:00
sullis
f1d0724f2a
[java] junit 4.13.2 (#11733) 2022-02-27 13:18:19 +08:00
William Cheng
8455c1cd23
Remove the option to support JDK7 from Java generator and templates (#11547)
* remove java8 from java client generator and templates

* update tests

* remove threetenbp

* update spring templates to remove java8

* remove java8 from jaxrs template

* fix jaxrs spec

* fix feign

* remove CustomInstantDeserializer.java

* fix jersey1

* fix undertow

* various update

* fix jaxrs jersey1

* fix java inflector

* fix jaxrs cxf

* add new files

* update doc
2022-02-10 10:35:29 +08:00
Maciej Sitarz
2875c7e14d
Improve Apache Httpclient support (#10624)
* Move apache-httpclient templates to proper dir

* Add template for Gradle

* Fix few JavaDoc compile warnings

* Add properly generated samples

* Empty just trigger PR checks rebuild
2021-10-23 14:57:32 +08:00
RomainPruvostMHH
1735ab9d27
[Java] Replace Java EE 8 dependencies by Jakarta EE 8 (#10513)
* Migrate javax.annotation:javax.annotation-api to
jakarta.annotation:jakarta.annotation-api:1.3.5

* Migrate javax.annotation:javax.annotation-api to
jakarta.annotation:jakarta.annotation-api:1.3.5 for sbt

* Migrate javax.annotation:javax.annotation-api to
jakarta.annotation:jakarta.annotation-api:1.3.5 for gradle

* Commit samples files after the execution of the command
"generate-samples.sh for configs java and kotlin

* Delete org.jboss.spec.javax.annotation:jboss-annotations-api_1.2_spec
from the exclusion section of org.jboss.resteasy:resteasy-client in the
resteasy module because jboss-annotations-api_1.2_spec isn't a
transitive dependency

* Migrate javax.validation:validation-api to
jakarta.validation:jakarta.validation-api:2.0.2 for maven

* Migrate javax.validation:validation-api to
jakarta.validation:jakarta.validation-api:2.0.2 for gradle

* Migrate javax.validation:validation-api to
jakarta.validation:jakarta.validation-api:2.0.2 for sbt

* Commit samples files after the execution of the command
"generate-samples.sh for configs java, spring, jaxrs and kotlin

* Migrate javax.ws.rs:javax.ws.rs-api to
jakarta.ws.rs:jakarta.ws.rs-api:2.1.6 for maven

* Commit samples files after the execution of the command
"generate-samples.sh for configs java, spring, jaxrs and kotlin

* Migrate javax.json.bind:javax.json.bind-api to
jakarta.json.bind:jakarta.json.bind-api:1.0.2 for maven

* Commit samples files after the execution of the command
"generate-samples.sh for configs java, spring, jaxrs and kotlin

* Migrate javax.json:javax.json-api to jakarta.json:jakarta.json-api:1.1.6
for maven

* Commit samples files after the execution of the command
"generate-samples.sh for configs java, spring, jaxrs and kotlin

* Migrate javax.xml.bind:jaxb-api to
jakarta.xml.bind:jakarta.xml.bind-api:2.3.3 for maven

* Commit samples files after the execution of the command
"generate-samples.sh for configs java, spring, jaxrs and kotlin

* Migrate javax.el:el-api to jakarta.el:jakarta.el-api:3.0.3 for maven

* Migrate javax.servlet:servlet-api to
jakarta.servlet:jakarta.servlet-api:4.0.4 for maven

* Delete the property servlet-api-version in pom files because it is
useless

* Commit samples files after the execution of the command
"generate-samples.sh for configs java, spring, jaxrs and kotlin

* Migrate javax.activation:activation to
jakarta.activation:jakarta.activation-api:1.2.2 for maven

* Delete javax.activation:activation from the exclusion section of
org.jboss.resteasy:resteasy-client in the resteasy module because
javax.activation:activation isn't a transitive dependency

* Commit samples files after the execution of the command
"generate-samples.sh for configs java, spring, jaxrs and kotlin

* Fix the name of property jakarta.activation-version

* Fix a missing property 'jakarta-annotation-version' in
JavaJaxRS/resteasy/pom.mustache

* generate samples

* Fix version value of jakarta.validation-api artifact in
Java/libraries/rest-assured/pom.mustache

* Fix missing property jakarta-annotation-version in
jaxrs-resteasy/eap/pom.mustache

* generate samples

* Revert changes in sample files after running the command
generate-samples.sh in gitBash

* Fix files in
samples/openapi3/client/extensions/x-auth-id-alias/java/jersey2-java8

* Replace the old dependency javax.validation:validation-api by the new
Jakarta EE 8 jakarta.validation:jakarta.validation-api in
openapi-generator-online

Co-authored-by: rpruvost <rpruvost@ITEM-S78402.emea.msad.sopra>
Co-authored-by: rpruvost <romain.pruvost@soprasteria.com>
2021-10-05 09:47:29 +08:00
William Cheng
3de5483aa0
[JAVA] Add apache httpclient library to java clients (#10218)
* Add apache java client option

* Add sample apache client config

* Switch serialization library, use time formatter

* Add pom template for apache dependencies

* Add initial implementation of ApiClient using apache

* Add apache api template

Plus switch to TypeReference to handle generic types

* Add support for sending json data

* Generate test stubs with @Ignore

* Add accept header

* Remove unnecessary builder assignments

* Set responseHeaders instance variable

* Switch to general serialize / deserialize functions

* Handle sending url encoded form data

* Split response processing into new method

* Allow requests without body

* Use general HttpResponse interface

If the method doesn't need to close it

* Use clients connection timeout

* Add constructor accepting custom client

* Handle multipart and direct file uploads

* Support file downloading

Based on the implementation in the jersey client

* Handle missing content disposition

* Raise error if body given for an unexpected method

* Use try with resources for response handling

* Remove unused url parameter encode method

* Handle content type parse exception

* Improve response content type handling

Would have had issues with content type headers containing a charset

* Make all set methods return client

* Add basic readme

* Send content type with files

* Set domain and path on cookies

Otherwise they will be excluded from the request

* Use consistent quoting in error messages

* Add generated apache sample

* Add generated docs changes

* update samples

* rename library, update samples, docs

* update readme

Co-authored-by: Harry White <hwhite@atlassian.com>
2021-08-22 11:17:31 +08:00