Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
ryber committed Jul 5, 2023
1 parent dd532cf commit bfb8cbe
Showing 1 changed file with 52 additions and 29 deletions.
81 changes: 52 additions & 29 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,48 +6,71 @@
[![Javadocs](http://www.javadoc.io/badge/com.konghq/unirest-java.svg)](http://www.javadoc.io/doc/com.konghq/unirest-java)
[![Twitter Follow](https://img.shields.io/twitter/follow/UnirestJava.svg?style=social)](https://twitter.com/UnirestJava)

## Install With [Maven](https://mvnrepository.com/artifact/com.konghq/unirest-java)[:](https://repo.maven.apache.org/maven2/com/konghq/unirest-java/)
### 🚨 Attention JSON users 🚨
Unirest now uses a modular json system. If you want to use JSON you MUST include in the pom the JSON implementation you wish to use. This can be either Jackson or Gson.
## Unirest 4
Unirest 4 is build on modern Java standards, and as such requires at least Java 11.

Unirest 4's dependencies are fully modular, and have been moved to new Maven coordinates to avoid conflicts with the previous versions.
You can use a maven bom to manage the modules:

### Install With Maven

```xml
<dependencyManagement>
<dependencies>
<!-- https://mvnrepository.com/artifact/com.konghq/unirest-java-bom -->
<dependency>
<groupId>com.konghq</groupId>
<artifactId>unirest-java-bom</artifactId>
<version>4.0.0</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

<dependencies>
<!-- https://mvnrepository.com/artifact/com.konghq/unirest-java-core -->
<dependency>
<groupId>com.konghq</groupId>
<artifactId>unirest-java-core</artifactId>
</dependency>
<!-- https://mvnrepository.com/artifact/com.konghq/unirest-object-mappers-gson -->
<dependency>
<groupId>com.konghq</groupId>
<artifactId>unirest-object-mappers-gson</artifactId>
</dependency>
</dependencies>
```

#### 🚨 Attention JSON users 🚨
Under Unirest 4, core no longer comes with ANY transient dependencies, and because Java itself lacks a JSON parser you MUST declare a JSON implementation if you wish to do object mappings or use Json objects.


## Upgrading from Previous Versions
See the [Upgrade Guide](UPGRADE_GUIDE.md)

## ChangeLog
See the [Change Log](CHANGELOG.md) for recent changes.

## Documentation
Our [Documentation](http://kong.github.io/unirest-java/)

## Unirest 3
### Maven
```xml
<!-- Pull in as a traditional dependency -->
<dependency>
<groupId>com.konghq</groupId>
<artifactId>unirest-java</artifactId>
<version>4.0.0-RC3</version>
<version>3.14.1</version>
</dependency>

<!-- OR as a snazzy new standalone jar with shaded dependencies -->
<dependency>
<groupId>com.konghq</groupId>
<artifactId>unirest-java</artifactId>
<version>4.0.0-RC3</version>
<version>3.14.1</version>
<classifier>standalone</classifier>
</dependency>

<!-- ONE of the following, if BOTH are on the path Unirest will pick the first it finds -->
<!-- GSON -->
<dependency>
<groupId>com.konghq</groupId>
<artifactId>unirest-object-mappers-gson</artifactId>
<version>4.0.0-RC3</version>
</dependency>

<!-- Jackson -->
<dependency>
<groupId>com.konghq</groupId>
<artifactId>unirest-object-mappers-jackson</artifactId>
<version>$4.0.0-RC3</version>
</dependency>

```

## Upgrading from Previous Versions
See the [Upgrade Guide](UPGRADE_GUIDE.md)

## ChangeLog
See the [Change Log](CHANGELOG.md) for recent changes.

## Documentation
Our [Documentation](http://kong.github.io/unirest-java/)

0 comments on commit bfb8cbe

Please sign in to comment.