Skip to content

Commit

Permalink
Merge pull request #602 from ably/release/1.2.2
Browse files Browse the repository at this point in the history
Release/1.2.2
  • Loading branch information
Quintin Willison authored Sep 17, 2020
2 parents 2afb487 + 644300b commit 4abf926
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 13 deletions.
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
# Change Log

## [v1.2.2](https://github.com/ably/ably-java/tree/v1.2.2) (2020-09-17)

[Full Changelog](https://github.com/ably/ably-java/compare/v1.2.1...v1.2.2)

**Fixed bugs:**

- Restoral of ActivationStateMachine events fails because not all event types have a no-argument constructor [\#598](https://github.com/ably/ably-java/issues/598) fixed by:
- Discard persisted events with non-nullary constructors [\#599](https://github.com/ably/ably-java/pull/599) ([tcard](https://github.com/tcard))
- Fatal Exception on API level below 19 [\#596](https://github.com/ably/ably-java/issues/596) fixed by:
- Replace use of StandardCharsets [\#601](https://github.com/ably/ably-java/pull/601) ([QuintinWillison](https://github.com/QuintinWillison))

**Other merged pull requests:**

- Rename master to main [\#592](https://github.com/ably/ably-java/pull/592) ([QuintinWillison](https://github.com/QuintinWillison))
- Bump protocol version to 1.2 [\#591](https://github.com/ably/ably-java/pull/591) ([QuintinWillison](https://github.com/QuintinWillison))

## [v1.2.1](https://github.com/ably/ably-java/tree/v1.2.1) (2020-06-15)

[Full Changelog](https://github.com/ably/ably-java/compare/v1.2.0...v1.2.1)
Expand Down
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@ Reference the library by including a compile dependency reference in your gradle
For [Java](https://bintray.com/ably-io/ably/ably-java/_latestVersion):

```
compile 'io.ably:ably-java:1.2.1'
compile 'io.ably:ably-java:1.2.2'
```

For [Android](https://bintray.com/ably-io/ably/ably-android/_latestVersion):

```
compile 'io.ably:ably-android:1.2.1'
compile 'io.ably:ably-android:1.2.2'
```

The library is hosted on the [Jcenter repository](https://bintray.com/ably-io/ably), so you need to ensure that the repo is referenced also; IDEs will typically include this by default:
Expand Down Expand Up @@ -586,15 +586,15 @@ Configuration of Run/Debug configurations for running the unit tests on Android

This library uses [semantic versioning](http://semver.org/). For each release, the following needs to be done:

1. Create a branch for the release, named like `release/1.2.1`
1. Create a branch for the release, named like `release/1.2.2`
2. Replace all references of the current version number with the new version number (check this file [README.md](./README.md) and [common.gradle](./common.gradle)) and commit the changes
3. Run [`github_changelog_generator`](https://github.com/skywinder/Github-Changelog-Generator) to update the [CHANGELOG](./CHANGELOG.md):
* This might work: `github_changelog_generator -u ably -p ably-java --header-label="# Changelog" --release-branch=release/1.2.1 --future-release=v1.2.1`
* But your mileage may vary as it can error. Perhaps more reliable is something like: `github_changelog_generator -u ably -p ably-java --since-tag v1.2.0 --output delta.md` and then manually merge the delta contents in to the main change log
* This might work: `github_changelog_generator -u ably -p ably-java --header-label="# Changelog" --release-branch=release/1.2.2 --future-release=v1.2.2`
* But your mileage may vary as it can error. Perhaps more reliable is something like: `github_changelog_generator -u ably -p ably-java --since-tag v1.2.1 --output delta.md` and then manually merge the delta contents in to the main change log
4. Commit [CHANGELOG](./CHANGELOG.md)
5. Make a PR against `main`
6. Once the PR is approved, merge it into `main`
7. Add a tag and push to origin - e.g.: `git tag v1.2.1 && git push origin v1.2.1`
7. Add a tag and push to origin - e.g.: `git tag v1.2.2 && git push origin v1.2.2`
8. Create the release on Github including populating the release notes (needed so JFrog can pull them in)
9. Assemble and Upload ([see below](#publishing-to-jcenter-and-maven-central) for details) - but the overall order to follow is:
1. Upload to Bintray and use the pushed tag, which will pull in the associated release notes
Expand Down Expand Up @@ -622,18 +622,18 @@ We publish to:

The `java` release process goes as follows:

* Go to the home page for the package; eg https://bintray.com/ably-io/ably/ably-java. Select Add a version, enter the new version such as "1.2.1" in name and save
* Go to the home page for the package; eg https://bintray.com/ably-io/ably/ably-java. Select Add a version, enter the new version such as "1.2.2" in name and save
* Run `./gradlew java:assembleRelease` locally to generate the files
* Open local relative folder in Finder, such as `./java/build/release/1.2.1/io/ably/ably-java/1.2.1`
* Go to the new version in JFrog Bintray; eg https://bintray.com/ably-io/ably/ably-java/1.2.1, then click on the link to upload via the UI in the "Upload files" section
* Open local relative folder in Finder, such as `./java/build/release/1.2.2/io/ably/ably-java/1.2.2`
* Go to the new version in JFrog Bintray; eg https://bintray.com/ably-io/ably/ably-java/1.2.2, then click on the link to upload via the UI in the "Upload files" section
* Drag in the files from Finder, just the `.jar` files and the `.pom` file. JFrog will fill in the "Target Path" box after you drop the files in. Click the "Upload" button.
* You will see a notice something like "4 unpublished files in your version. Will be deleted in 6 days and 22 hours. Publish all or Delete all unpublished files.", make sure you click "Publish all". Wait a few minutes and check that what's uploaded looks like what was uploaded for previous releases. The `maven-metadata` files are created by JFrog.
* Update the README text in Bintray (version number needs incrementing).

Similarly for the `android` release at https://bintray.com/ably-io/ably/ably-android:

* Run `./gradlew android:assembleRelease` locally to generate the files, and drag in the files in
`./android/build/release/1.2.1/io/ably/ably-android/1.2.1`.
`./android/build/release/1.2.2/io/ably/ably-android/1.2.2`.
* In this case upload the `.jar` files, the `.pom` file and the `.aar` file.

#### Releasing to Maven Central (Sonatype Nexus)
Expand Down
2 changes: 1 addition & 1 deletion common.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repositories {
}

group = 'io.ably'
version = '1.2.1'
version = '1.2.2'
description = """Ably java client library"""

tasks.withType(Javadoc) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ public void realtime_websocket_param_test() {
* Defaults.ABLY_LIB_PARAM, as ultimately the request param has been derived from those values.
*/
assertEquals("Verify correct lib version", requestParameters.get("lib"),
Collections.singletonList("java-1.2.1"));
Collections.singletonList("java-1.2.2"));

/* Spec RTN2a */
assertEquals("Verify correct format", requestParameters.get("format"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public void header_lib_channel_publish() {
*/
Assert.assertNotNull("Expected headers", headers);
Assert.assertEquals(headers.get("x-ably-version"), "1.2");
Assert.assertEquals(headers.get("x-ably-lib"), "java-1.2.1");
Assert.assertEquals(headers.get("x-ably-lib"), "java-1.2.2");
} catch (AblyException e) {
e.printStackTrace();
Assert.fail("header_lib_channel_publish: Unexpected exception");
Expand Down

0 comments on commit 4abf926

Please sign in to comment.