Skip to content

Commit

Permalink
Prepare next development version
Browse files Browse the repository at this point in the history
  • Loading branch information
JakeWharton committed Nov 18, 2018
1 parent 5d6650a commit 8bd6c99
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 15 deletions.
34 changes: 34 additions & 0 deletions CHANGELOG.md
@@ -1,6 +1,40 @@
Change Log
==========

Version 2.5.0 *(2018-11-18)*
============================

* New: Built-in support for Kotlin's `Unit` type. This behaves the same as Java's `Void` where the body
content is ignored and immediately discarded.
* New: Build-in support for Java 8's `Optional` and `CompletableFuture` types. Previously the 'converter-java8'
and 'adapter-java8' dependencies were needed and explicitly adding `Java8OptionalConverterFactory` and/or
`Java8CallAdapterFactory` to your `Retrofit.Builder` in order to use these types. Support is now built-in and
those types and their artifacts are marked as deprecated.
* New: `Invocation` class provides a reference to the invoked method and argument list as a tag on the
underlying OkHttp `Call`. This can be accessed from an OkHttp interceptor for things like logging, analytics,
or metrics aggregation.
* New: Kotlin extension for `Retrofit` which allows you call `create` passing the interface type only as
a generic parameter (e.g., `retrofit.create<MyService>()`).
* New: Added `Response.success` overload which allows specifying a custom 2xx status code.
* New: Added `Call.failure` overload which allows passing any `Throwable` subtype.
* New: Minimal R8 rules now ship inside the jar requiring no client configuration in the common case.
* Fix: Do not propagate fatal errors to the callback. They are sent to the thread's uncaught
exception handler.
* Fix: Do not enqueue/execute an otherwise useless call when the RxJava type is disposed by `onSubscribe`.
* Fix: Call `RxJavaPlugins` assembly hook when creating an RxJava 2 type.
* Fix: Ensure both the Guava and Java 8 `Optional` converters delegate properly. This ensures that converters
registered prior to the optional converter can be used for deserializing the body type.
* Fix: Prevent `@Path` values from participating in path-traversal. This ensures untrusted input passed as
a path value cannot cause you to make a request to an un-intended relative URL.
* Fix: Simple XML converter (which is deprecated) no longer wraps subtypes of `RuntimeException`
or `IOException` when it fails.
* Fix: Prevent JAXB converter from loading remote entities and DTDs.
* Fix: Correctly detect default methods in interfaces on Android (API 24+). These still do not work, but
now a correct exception will be thrown when detected.
* Fix: Report more accurate exceptions when a `@QueryName` or `@QueryMap` precedes a `@Url` parameter.
* Update OkHttp dependency to 3.12.


Version 2.4.0 *(2018-03-14)*
----------------------------

Expand Down
20 changes: 5 additions & 15 deletions README.md
Expand Up @@ -9,18 +9,7 @@ For more information please see [the website][1].
Download
--------

Download [the latest JAR][2] or grab via Maven:
```xml
<dependency>
<groupId>com.squareup.retrofit2</groupId>
<artifactId>retrofit</artifactId>
<version>2.4.0</version>
</dependency>
```
or Gradle:
```groovy
implementation 'com.squareup.retrofit2:retrofit:2.4.0'
```
Download [the latest JAR][2] or grab from Maven central at the coordinates `com.squareup.retrofit2:retrofit:2.5.0`.

Snapshots of the development version are available in [Sonatype's `snapshots` repository][snap].

Expand All @@ -30,10 +19,11 @@ Retrofit requires at minimum Java 7 or Android 2.3.
R8 / ProGuard
-------------

If you are using R8 or ProGuard add the options from
[this file](https://github.com/square/retrofit/blob/master/retrofit/src/main/resources/META-INF/proguard/retrofit2.pro).
If you are using R8 the shrinking and obfuscation rules are included automatically.

You might also need rules for OkHttp and Okio which are dependencies of this library.
ProGuard users must manually add the options from
[this file](https://github.com/square/retrofit/blob/master/retrofit/src/main/resources/META-INF/proguard/retrofit2.pro).

This comment has been minimized.

Copy link
@shiouming

shiouming Mar 23, 2019

Are we supposed to always be using proguard rule from master branch, regardless of retrofit version?

(Note: You might also need rules for OkHttp and Okio which are dependencies of this library)


License
Expand Down

0 comments on commit 8bd6c99

Please sign in to comment.