Skip to content
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

[Java] Update ApiClient.mustache for retrofit2 + rxJava3 #19266

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import retrofit2.Retrofit;
import retrofit2.adapter.rxjava2.RxJava2CallAdapterFactory;
{{/useRxJava2}}
{{#useRxJava3}}
import hu.akarnokd.rxjava3.retrofit.RxJava3CallAdapterFactory;
import retrofit2.adapter.rxjava3.RxJava3CallAdapterFactory;
{{/useRxJava3}}
{{#gson}}
import retrofit2.converter.gson.GsonConverterFactory;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ if(hasProperty('target') && target == 'android') {

ext {
oltu_version = "1.0.1"
retrofit_version = "2.3.0"
retrofit_version = "2.11.0"
{{#jackson}}
jackson_version = "2.17.1"
jackson_databind_version = "2.17.1"
Expand Down Expand Up @@ -134,7 +134,7 @@ dependencies {
implementation "io.reactivex.rxjava2:rxjava:$rx_java_version"
{{/useRxJava2}}
{{#useRxJava3}}
implementation 'com.github.akarnokd:rxjava3-retrofit-adapter:3.0.0'
implementation 'com.squareup.retrofit2:adapter-rxjava3:$$retrofit_version'
implementation "io.reactivex.rxjava3:rxjava:$rx_java_version"
{{/useRxJava3}}
implementation "io.swagger:swagger-annotations:$swagger_annotations_version"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,25 +9,25 @@ lazy val root = (project in file(".")).
publishArtifact in (Compile, packageDoc) := false,
resolvers += Resolver.mavenLocal,
libraryDependencies ++= Seq(
"com.squareup.retrofit2" % "retrofit" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-scalars" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "retrofit" % "2.11.0" % "compile",
"com.squareup.retrofit2" % "converter-scalars" % "2.11.0" % "compile",
{{^usePlayWS}}
"com.squareup.retrofit2" % "converter-gson" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-gson" % "2.11.0" % "compile",
{{/usePlayWS}}
{{#usePlayWS}}
"com.typesafe.play" % "play-ahc-ws_2.12" % "2.6.7" % "compile",
"jakarta.validation" % "jakarta.validation-api" % "3.0.2" % "compile",
"com.squareup.retrofit2" % "converter-jackson" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-jackson" % "2.11.0" % "compile",
"com.fasterxml.jackson.core" % "jackson-core" % "2.17.1" % "compile",
"com.fasterxml.jackson.core" % "jackson-annotations" % "2.17.1" % "compile",
"com.fasterxml.jackson.core" % "jackson-databind" % "2.17.1" % "compile",
{{/usePlayWS}}
{{#useRxJava2}}
"com.squareup.retrofit2" % "adapter-rxjava2" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "adapter-rxjava2" % "2.11.0" % "compile",
"io.reactivex.rxjava2" % "rxjava" % "2.1.1" % "compile",
{{/useRxJava2}}
{{#useRxJava3}}
"com.github.akarnokd" % "rxjava3-retrofit-adapter" % "3.0.0" % "compile",
"com.squareup.retrofit2" % "adapter-rxjava3" % "2.11.0" % "compile",
"io.reactivex.rxjava3" % "rxjava" % "3.0.4" % "compile",
{{/useRxJava3}}
"io.swagger" % "swagger-annotations" % "1.5.21" % "compile",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -278,9 +278,9 @@
<version>${rxjava-version}</version>
</dependency>
<dependency>
<groupId>com.github.akarnokd</groupId>
<artifactId>rxjava3-retrofit-adapter</artifactId>
<version>3.0.0</version>
<groupId>com.squareup.retrofit2</groupId>
<artifactId>adapter-rxjava3</artifactId>
<version>${retrofit-version}</version>
</dependency>
{{/useRxJava3}}
{{#jackson}}
Expand Down Expand Up @@ -393,7 +393,7 @@
{{#usePlayWS}}
<play-version>2.6.7</play-version>
{{/usePlayWS}}
<retrofit-version>2.5.0</retrofit-version>
<retrofit-version>2.11.0</retrofit-version>
{{#useRxJava2}}
<rxjava-version>2.1.1</rxjava-version>
{{/useRxJava2}}
Expand Down
2 changes: 1 addition & 1 deletion samples/client/petstore/java/retrofit2-play26/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ if(hasProperty('target') && target == 'android') {

ext {
oltu_version = "1.0.1"
retrofit_version = "2.3.0"
retrofit_version = "2.11.0"
jackson_version = "2.17.1"
jackson_databind_version = "2.17.1"
javax_ws_rs_api_version = "2.1.1"
Expand Down
6 changes: 3 additions & 3 deletions samples/client/petstore/java/retrofit2-play26/build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ lazy val root = (project in file(".")).
publishArtifact in (Compile, packageDoc) := false,
resolvers += Resolver.mavenLocal,
libraryDependencies ++= Seq(
"com.squareup.retrofit2" % "retrofit" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-scalars" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "retrofit" % "2.11.0" % "compile",
"com.squareup.retrofit2" % "converter-scalars" % "2.11.0" % "compile",
"com.typesafe.play" % "play-ahc-ws_2.12" % "2.6.7" % "compile",
"jakarta.validation" % "jakarta.validation-api" % "3.0.2" % "compile",
"com.squareup.retrofit2" % "converter-jackson" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-jackson" % "2.11.0" % "compile",
"com.fasterxml.jackson.core" % "jackson-core" % "2.17.1" % "compile",
"com.fasterxml.jackson.core" % "jackson-annotations" % "2.17.1" % "compile",
"com.fasterxml.jackson.core" % "jackson-databind" % "2.17.1" % "compile",
Expand Down
2 changes: 1 addition & 1 deletion samples/client/petstore/java/retrofit2-play26/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@
<jackson-databind-nullable-version>0.2.6</jackson-databind-nullable-version>
<javax.ws.rs-api-version>2.1.1</javax.ws.rs-api-version>
<play-version>2.6.7</play-version>
<retrofit-version>2.5.0</retrofit-version>
<retrofit-version>2.11.0</retrofit-version>
<jakarta-annotation-version>2.1.1</jakarta-annotation-version>
<beanvalidation-version>3.0.2</beanvalidation-version>
<oltu-version>1.0.1</oltu-version>
Expand Down
2 changes: 1 addition & 1 deletion samples/client/petstore/java/retrofit2/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ if(hasProperty('target') && target == 'android') {

ext {
oltu_version = "1.0.1"
retrofit_version = "2.3.0"
retrofit_version = "2.11.0"
jakarta_annotation_version = "1.3.5"
swagger_annotations_version = "1.5.22"
junit_version = "5.10.3"
Expand Down
6 changes: 3 additions & 3 deletions samples/client/petstore/java/retrofit2/build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ lazy val root = (project in file(".")).
publishArtifact in (Compile, packageDoc) := false,
resolvers += Resolver.mavenLocal,
libraryDependencies ++= Seq(
"com.squareup.retrofit2" % "retrofit" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-scalars" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-gson" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "retrofit" % "2.11.0" % "compile",
"com.squareup.retrofit2" % "converter-scalars" % "2.11.0" % "compile",
"com.squareup.retrofit2" % "converter-gson" % "2.11.0" % "compile",
"io.swagger" % "swagger-annotations" % "1.5.21" % "compile",
"org.apache.oltu.oauth2" % "org.apache.oltu.oauth2.client" % "1.0.1" % "compile",
"io.gsonfire" % "gson-fire" % "1.9.0" % "compile",
Expand Down
2 changes: 1 addition & 1 deletion samples/client/petstore/java/retrofit2/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@
<maven.compiler.target>${java.version}</maven.compiler.target>
<gson-fire-version>1.9.0</gson-fire-version>
<swagger-annotations-version>1.6.3</swagger-annotations-version>
<retrofit-version>2.5.0</retrofit-version>
<retrofit-version>2.11.0</retrofit-version>
<jakarta-annotation-version>1.3.5</jakarta-annotation-version>
<oltu-version>1.0.1</oltu-version>
<junit-version>5.10.3</junit-version>
Expand Down
2 changes: 1 addition & 1 deletion samples/client/petstore/java/retrofit2rx2/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ if(hasProperty('target') && target == 'android') {

ext {
oltu_version = "1.0.1"
retrofit_version = "2.3.0"
retrofit_version = "2.11.0"
jakarta_annotation_version = "1.3.5"
swagger_annotations_version = "1.5.22"
junit_version = "5.10.3"
Expand Down
8 changes: 4 additions & 4 deletions samples/client/petstore/java/retrofit2rx2/build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ lazy val root = (project in file(".")).
publishArtifact in (Compile, packageDoc) := false,
resolvers += Resolver.mavenLocal,
libraryDependencies ++= Seq(
"com.squareup.retrofit2" % "retrofit" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-scalars" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-gson" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "adapter-rxjava2" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "retrofit" % "2.11.0" % "compile",
"com.squareup.retrofit2" % "converter-scalars" % "2.11.0" % "compile",
"com.squareup.retrofit2" % "converter-gson" % "2.11.0" % "compile",
"com.squareup.retrofit2" % "adapter-rxjava2" % "2.11.0" % "compile",
"io.reactivex.rxjava2" % "rxjava" % "2.1.1" % "compile",
"io.swagger" % "swagger-annotations" % "1.5.21" % "compile",
"org.apache.oltu.oauth2" % "org.apache.oltu.oauth2.client" % "1.0.1" % "compile",
Expand Down
2 changes: 1 addition & 1 deletion samples/client/petstore/java/retrofit2rx2/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@
<maven.compiler.target>${java.version}</maven.compiler.target>
<gson-fire-version>1.9.0</gson-fire-version>
<swagger-annotations-version>1.6.3</swagger-annotations-version>
<retrofit-version>2.5.0</retrofit-version>
<retrofit-version>2.11.0</retrofit-version>
<rxjava-version>2.1.1</rxjava-version>
<jakarta-annotation-version>1.3.5</jakarta-annotation-version>
<oltu-version>1.0.1</oltu-version>
Expand Down
4 changes: 2 additions & 2 deletions samples/client/petstore/java/retrofit2rx3/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ if(hasProperty('target') && target == 'android') {

ext {
oltu_version = "1.0.1"
retrofit_version = "2.3.0"
retrofit_version = "2.11.0"
jakarta_annotation_version = "1.3.5"
swagger_annotations_version = "1.5.22"
junit_version = "5.10.3"
Expand All @@ -110,7 +110,7 @@ dependencies {
implementation "com.squareup.retrofit2:retrofit:$retrofit_version"
implementation "com.squareup.retrofit2:converter-scalars:$retrofit_version"
implementation "com.squareup.retrofit2:converter-gson:$retrofit_version"
implementation 'com.github.akarnokd:rxjava3-retrofit-adapter:3.0.0'
implementation 'com.squareup.retrofit2:adapter-rxjava3:$$retrofit_version'
implementation "io.reactivex.rxjava3:rxjava:$rx_java_version"
implementation "io.swagger:swagger-annotations:$swagger_annotations_version"
implementation "com.google.code.findbugs:jsr305:3.0.2"
Expand Down
8 changes: 4 additions & 4 deletions samples/client/petstore/java/retrofit2rx3/build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ lazy val root = (project in file(".")).
publishArtifact in (Compile, packageDoc) := false,
resolvers += Resolver.mavenLocal,
libraryDependencies ++= Seq(
"com.squareup.retrofit2" % "retrofit" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-scalars" % "2.3.0" % "compile",
"com.squareup.retrofit2" % "converter-gson" % "2.3.0" % "compile",
"com.github.akarnokd" % "rxjava3-retrofit-adapter" % "3.0.0" % "compile",
"com.squareup.retrofit2" % "retrofit" % "2.11.0" % "compile",
"com.squareup.retrofit2" % "converter-scalars" % "2.11.0" % "compile",
"com.squareup.retrofit2" % "converter-gson" % "2.11.0" % "compile",
"com.squareup.retrofit2" % "adapter-rxjava3" % "2.11.0" % "compile",
"io.reactivex.rxjava3" % "rxjava" % "3.0.4" % "compile",
"io.swagger" % "swagger-annotations" % "1.5.21" % "compile",
"org.apache.oltu.oauth2" % "org.apache.oltu.oauth2.client" % "1.0.1" % "compile",
Expand Down
8 changes: 4 additions & 4 deletions samples/client/petstore/java/retrofit2rx3/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -247,9 +247,9 @@
<version>${rxjava-version}</version>
</dependency>
<dependency>
<groupId>com.github.akarnokd</groupId>
<artifactId>rxjava3-retrofit-adapter</artifactId>
<version>3.0.0</version>
<groupId>com.squareup.retrofit2</groupId>
<artifactId>adapter-rxjava3</artifactId>
<version>${retrofit-version}</version>
</dependency>
<dependency>
<groupId>jakarta.annotation</groupId>
Expand All @@ -272,7 +272,7 @@
<maven.compiler.target>${java.version}</maven.compiler.target>
<gson-fire-version>1.9.0</gson-fire-version>
<swagger-annotations-version>1.6.3</swagger-annotations-version>
<retrofit-version>2.5.0</retrofit-version>
<retrofit-version>2.11.0</retrofit-version>
<rxjava-version>3.0.4</rxjava-version>
<jakarta-annotation-version>1.3.5</jakarta-annotation-version>
<oltu-version>1.0.1</oltu-version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import org.apache.oltu.oauth2.client.request.OAuthClientRequest.TokenRequestBuilder;
import retrofit2.Converter;
import retrofit2.Retrofit;
import hu.akarnokd.rxjava3.retrofit.RxJava3CallAdapterFactory;
import retrofit2.adapter.rxjava3.RxJava3CallAdapterFactory;
import retrofit2.converter.gson.GsonConverterFactory;
import retrofit2.converter.scalars.ScalarsConverterFactory;
import org.openapitools.client.auth.HttpBasicAuth;
Expand Down
Loading