Skip to content

provides build number for PRs #724

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

Merged
merged 5 commits into from
Dec 5, 2019
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
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ matrix:
- jdk: openjdk8
- jdk: openjdk11
env: SKIP_RELEASE=true
- jdk: openjdk12
- jdk: openjdk13
env: SKIP_RELEASE=true

env:
Expand Down
11 changes: 4 additions & 7 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,11 @@
*/

plugins {
id 'com.gradle.build-scan' version '2.4.2'

id 'com.github.sherter.google-java-format' version '0.8' apply false
id 'com.jfrog.artifactory' version '4.9.10' apply false
id 'com.jfrog.artifactory' version '4.11.0' apply false
id 'com.jfrog.bintray' version '1.8.4' apply false
id 'me.champeau.gradle.jmh' version '0.4.8' apply false
id 'io.spring.dependency-management' version '1.0.7.RELEASE' apply false
id 'me.champeau.gradle.jmh' version '0.5.0' apply false
id 'io.spring.dependency-management' version '1.0.8.RELEASE' apply false
id 'io.morethan.jmhreport' version '0.9.0' apply false
}

Expand All @@ -35,7 +33,7 @@ subprojects {
ext['netty-bom.version'] = '4.1.37.Final'
ext['netty-boringssl.version'] = '2.0.25.Final'
ext['hdrhistogram.version'] = '2.1.10'
ext['mockito.version'] = '2.25.1'
ext['mockito.version'] = '3.2.0'
ext['slf4j.version'] = '1.7.25'
ext['jmh.version'] = '1.21'
ext['junit.version'] = '5.5.2'
Expand Down Expand Up @@ -145,7 +143,6 @@ subprojects {
}
}
}

}

apply from: "${rootDir}/gradle/publications.gradle"
Expand Down
16 changes: 14 additions & 2 deletions ci/travis.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,24 @@ if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then
echo -e "Building PR #$TRAVIS_PULL_REQUEST [$TRAVIS_PULL_REQUEST_SLUG/$TRAVIS_PULL_REQUEST_BRANCH => $TRAVIS_REPO_SLUG/$TRAVIS_BRANCH]"
./gradlew build

elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" == "" ] && [ "$bintrayUser" != "" ] ; then
elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" == "" ] && [ "$bintrayUser" != "" ] && [ "$TRAVIS_BRANCH" == "develop" ] ; then

echo -e "Building Snapshot $TRAVIS_REPO_SLUG/$TRAVIS_BRANCH"
echo -e "Building Develop Snapshot $TRAVIS_REPO_SLUG/$TRAVIS_BRANCH/$TRAVIS_BUILD_NUMBER"
./gradlew \
-PbintrayUser="${bintrayUser}" -PbintrayKey="${bintrayKey}" \
-PsonatypeUsername="${sonatypeUsername}" -PsonatypePassword="${sonatypePassword}" \
-PversionSuffix="-SNAPSHOT" \
-PbuildNumber="$TRAVIS_BUILD_NUMBER" \
build artifactoryPublish --stacktrace

elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" == "" ] && [ "$bintrayUser" != "" ] ; then

echo -e "Building Branch Snapshot $TRAVIS_REPO_SLUG/$TRAVIS_BRANCH/$TRAVIS_BUILD_NUMBER"
./gradlew \
-PbintrayUser="${bintrayUser}" -PbintrayKey="${bintrayKey}" \
-PsonatypeUsername="${sonatypeUsername}" -PsonatypePassword="${sonatypePassword}" \
-PversionSuffix="-$TRAVIS_BRANCH-SNAPSHOT" \
-PbuildNumber="$TRAVIS_BUILD_NUMBER" \
build artifactoryPublish --stacktrace

elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" != "" ] && [ "$bintrayUser" != "" ] ; then
Expand All @@ -21,6 +32,7 @@ elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" != "" ] && [ "$bin
-Pversion="$TRAVIS_TAG" \
-PbintrayUser="${bintrayUser}" -PbintrayKey="${bintrayKey}" \
-PsonatypeUsername="${sonatypeUsername}" -PsonatypePassword="${sonatypePassword}" \
-PbuildNumber="$TRAVIS_BUILD_NUMBER" \
build bintrayUpload --stacktrace

else
Expand Down
4 changes: 4 additions & 0 deletions gradle/artifactory.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,10 @@ if (project.hasProperty('bintrayUser') && project.hasProperty('bintrayKey')) {
defaults {
publications(publishing.publications.maven)
}

if (project.hasProperty('buildNumber')) {
clientConfig.info.setBuildNumber(project.property('buildNumber').toString())
}
}
}
tasks.named("artifactoryPublish").configure {
Expand Down
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.3-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-6.0.1-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
22 changes: 19 additions & 3 deletions gradlew
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
#!/usr/bin/env sh

#
# Copyright 2015 the original author or authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

##############################################################################
##
## Gradle start up script for UN*X
Expand Down Expand Up @@ -28,7 +44,7 @@ APP_NAME="Gradle"
APP_BASE_NAME=`basename "$0"`

# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS=""
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD="maximum"
Expand Down Expand Up @@ -109,8 +125,8 @@ if $darwin; then
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
fi

# For Cygwin, switch paths to Windows format before running java
if $cygwin ; then
# For Cygwin or MSYS, switch paths to Windows format before running java
if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
JAVACMD=`cygpath --unix "$JAVACMD"`
Expand Down
18 changes: 17 additions & 1 deletion gradlew.bat
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
@rem
@rem Copyright 2015 the original author or authors.
@rem
@rem Licensed under the Apache License, Version 2.0 (the "License");
@rem you may not use this file except in compliance with the License.
@rem You may obtain a copy of the License at
@rem
@rem https://www.apache.org/licenses/LICENSE-2.0
@rem
@rem Unless required by applicable law or agreed to in writing, software
@rem distributed under the License is distributed on an "AS IS" BASIS,
@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@rem See the License for the specific language governing permissions and
@rem limitations under the License.
@rem

@if "%DEBUG%" == "" @echo off
@rem ##########################################################################
@rem
Expand All @@ -14,7 +30,7 @@ set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%

@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS=
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"

@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
Expand Down
6 changes: 0 additions & 6 deletions rsocket-bom/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,6 @@ publishing {
publications {
maven(MavenPublication) {
from components.javaPlatform
// remove scope information from published BOM
pom.withXml {
asNode().dependencyManagement.first().dependencies.first().each {
it.remove(it.scope.first())
}
}
}
}
}
20 changes: 10 additions & 10 deletions rsocket-core/src/main/java/io/rsocket/DuplexConnection.java
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ public interface DuplexConnection extends Availability, Closeable {
* Sends the source of Frames on this connection and returns the {@code Publisher} representing
* the result of this send.
*
* <h2>Flow control</h2>
* <p><strong>Flow control</strong>
*
* The passed {@code Publisher} must
* <p>The passed {@code Publisher} must
*
* @param frames Stream of {@code Frame}s to send on the connection.
* @return {@code Publisher} that completes when all the frames are written on the connection
Expand All @@ -56,20 +56,20 @@ default Mono<Void> sendOne(ByteBuf frame) {
/**
* Returns a stream of all {@code Frame}s received on this connection.
*
* <h2>Completion</h2>
* <p><strong>Completion</strong>
*
* Returned {@code Publisher} <em>MUST</em> never emit a completion event ({@link
* <p>Returned {@code Publisher} <em>MUST</em> never emit a completion event ({@link
* Subscriber#onComplete()}.
*
* <h2>Error</h2>
* <p><strong>Error</strong>
*
* Returned {@code Publisher} can error with various transport errors. If the underlying physical
* connection is closed by the peer, then the returned stream from here <em>MUST</em> emit an
* {@link ClosedChannelException}.
* <p>Returned {@code Publisher} can error with various transport errors. If the underlying
* physical connection is closed by the peer, then the returned stream from here <em>MUST</em>
* emit an {@link ClosedChannelException}.
*
* <h2>Multiple Subscriptions</h2>
* <p><strong>Multiple Subscriptions</strong>
*
* Returned {@code Publisher} is not required to support multiple concurrent subscriptions.
* <p>Returned {@code Publisher} is not required to support multiple concurrent subscriptions.
* RSocket will never have multiple subscriptions to this source. Implementations <em>MUST</em>
* emit an {@link IllegalStateException} for subsequent concurrent subscriptions, if they do not
* support multiple concurrent subscriptions.
Expand Down
13 changes: 13 additions & 0 deletions settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id 'com.gradle.enterprise' version '3.1'
}

rootProject.name = 'rsocket-java'

Expand All @@ -26,3 +29,13 @@ include 'rsocket-bom'

include 'rsocket-examples'
include 'benchmarks'



gradleEnterprise {
buildScan {
termsOfServiceUrl = 'https://gradle.com/terms-of-service'
termsOfServiceAgree = 'yes'
}
}