Skip to content

Commit 665937f

Browse files
Merge pull request #153 from SpineEventEngine/bump-dependencies
Bump dependencies
2 parents 1c71f67 + b9232ec commit 665937f

File tree

21 files changed

+550
-338
lines changed

21 files changed

+550
-338
lines changed

.gitignore

Lines changed: 78 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,99 @@
1+
#
2+
# Copyright 2020, TeamDev. All rights reserved.
3+
#
4+
# Redistribution and use in source and/or binary forms, with or without
5+
# modification, must retain the above copyright notice and the following
6+
# disclaimer.
7+
#
8+
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
9+
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
10+
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
11+
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
12+
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
13+
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
14+
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
15+
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
16+
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
17+
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
18+
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
19+
#
20+
21+
#
22+
# This file is used for two purposes:
23+
# 1. ignoring files in the `config` project.
24+
# 2. ignoring files in the projects that import `config` as a sub-module.
25+
#
26+
# Therefore, instructions below are superset of instructions required for all the projects.
27+
128
# IntelliJ IDEA modules and interim config files.
229
*.iml
3-
.idea/libraries
430
.idea/*.xml
31+
.idea/.name
32+
.idea/artifacts
33+
.idea/libraries
34+
.idea/modules
35+
.idea/shelf
536

6-
# Do not ignore code style settings.
7-
!/.idea/codeStyleSettings.xml
37+
# Do not ignore the following IDEA settings
38+
!.idea/misc.xml
39+
!.idea/codeStyleSettings.xml
40+
!.idea/codeStyles/
41+
!.idea/copyright/
842

943
# Gradle interim configs
10-
*/.gradle/*
44+
**/.gradle/**
1145

1246
# Generated source code
13-
*/generated/*
47+
**/generated/**
1448

1549
# Gradle build files
16-
build/*
17-
*/build/*
50+
**/build/**
51+
52+
# Build files produced by the IDE
53+
**/out/**
54+
55+
# Ignore Gradle GUI config
56+
gradle-app.setting
57+
58+
# Avoid ignoring Gradle wrapper jar file (.jar files are usually ignored)
59+
!gradle-wrapper.jar
1860

19-
.spine/
61+
# Cache of project
62+
.gradletasknamecache
2063

21-
# Credentials to Maven repositories and Google Cloud Storage used for Travis build reports
64+
# # Work around https://youtrack.jetbrains.com/issue/IDEA-116898
65+
# gradle/wrapper/gradle-wrapper.properties
66+
67+
# Spine internal directory for storing intermediate artifacts
68+
**/.spine/**
69+
70+
# Spine model compiler auto-generated resources
71+
/tools/gradle-plugins/model-compiler/src/main/resources/spine-protoc.gradle
72+
73+
# Login details to Maven repository.
74+
# Each workstation should have developer's login defined in this file.
2275
credentials.tar
2376
credentials.properties
2477
cloudrepo.properties
2578
deploy_key_rsa
2679
gcs-auth-key.json
2780

81+
# Log files
82+
*.log
83+
84+
# Package Files #
85+
*.war
86+
*.ear
87+
*.zip
88+
*.tar.gz
89+
*.rar
90+
91+
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
92+
hs_err_pid*
93+
94+
.packages
95+
pubspec.lock
96+
2897
# Credentials to the test Datastore environment.
2998
# They are stored in the encrypted file and are decrypted on the CI server only.
3099

CODE_OF_CONDUCT.md

Lines changed: 128 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,128 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
We as members, contributors, and leaders pledge to make participation in our
6+
community a harassment-free experience for everyone, regardless of age, body
7+
size, visible or invisible disability, ethnicity, sex characteristics, gender
8+
identity and expression, level of experience, education, socio-economic status,
9+
nationality, personal appearance, race, religion, or sexual identity
10+
and orientation.
11+
12+
We pledge to act and interact in ways that contribute to an open, welcoming,
13+
diverse, inclusive, and healthy community.
14+
15+
## Our Standards
16+
17+
Examples of behavior that contributes to a positive environment for our
18+
community include:
19+
20+
* Demonstrating empathy and kindness toward other people
21+
* Being respectful of differing opinions, viewpoints, and experiences
22+
* Giving and gracefully accepting constructive feedback
23+
* Accepting responsibility and apologizing to those affected by our mistakes,
24+
and learning from the experience
25+
* Focusing on what is best not just for us as individuals, but for the
26+
overall community
27+
28+
Examples of unacceptable behavior include:
29+
30+
* The use of sexualized language or imagery, and sexual attention or
31+
advances of any kind
32+
* Trolling, insulting or derogatory comments, and personal or political attacks
33+
* Public or private harassment
34+
* Publishing others' private information, such as a physical or email
35+
address, without their explicit permission
36+
* Other conduct which could reasonably be considered inappropriate in a
37+
professional setting
38+
39+
## Enforcement Responsibilities
40+
41+
Community leaders are responsible for clarifying and enforcing our standards of
42+
acceptable behavior and will take appropriate and fair corrective action in
43+
response to any behavior that they deem inappropriate, threatening, offensive,
44+
or harmful.
45+
46+
Community leaders have the right and responsibility to remove, edit, or reject
47+
comments, commits, code, wiki edits, issues, and other contributions that are
48+
not aligned to this Code of Conduct, and will communicate reasons for moderation
49+
decisions when appropriate.
50+
51+
## Scope
52+
53+
This Code of Conduct applies within all community spaces, and also applies when
54+
an individual is officially representing the community in public spaces.
55+
Examples of representing our community include using an official e-mail address,
56+
posting via an official social media account, or acting as an appointed
57+
representative at an online or offline event.
58+
59+
## Enforcement
60+
61+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
62+
reported to the community leaders responsible for enforcement at
63+
64+
All complaints will be reviewed and investigated promptly and fairly.
65+
66+
All community leaders are obligated to respect the privacy and security of the
67+
reporter of any incident.
68+
69+
## Enforcement Guidelines
70+
71+
Community leaders will follow these Community Impact Guidelines in determining
72+
the consequences for any action they deem in violation of this Code of Conduct:
73+
74+
### 1. Correction
75+
76+
**Community Impact**: Use of inappropriate language or other behavior deemed
77+
unprofessional or unwelcome in the community.
78+
79+
**Consequence**: A private, written warning from community leaders, providing
80+
clarity around the nature of the violation and an explanation of why the
81+
behavior was inappropriate. A public apology may be requested.
82+
83+
### 2. Warning
84+
85+
**Community Impact**: A violation through a single incident or series
86+
of actions.
87+
88+
**Consequence**: A warning with consequences for continued behavior. No
89+
interaction with the people involved, including unsolicited interaction with
90+
those enforcing the Code of Conduct, for a specified period of time. This
91+
includes avoiding interactions in community spaces as well as external channels
92+
like social media. Violating these terms may lead to a temporary or
93+
permanent ban.
94+
95+
### 3. Temporary Ban
96+
97+
**Community Impact**: A serious violation of community standards, including
98+
sustained inappropriate behavior.
99+
100+
**Consequence**: A temporary ban from any sort of interaction or public
101+
communication with the community for a specified period of time. No public or
102+
private interaction with the people involved, including unsolicited interaction
103+
with those enforcing the Code of Conduct, is allowed during this period.
104+
Violating these terms may lead to a permanent ban.
105+
106+
### 4. Permanent Ban
107+
108+
**Community Impact**: Demonstrating a pattern of violation of community
109+
standards, including sustained inappropriate behavior, harassment of an
110+
individual, or aggression toward or disparagement of classes of individuals.
111+
112+
**Consequence**: A permanent ban from any sort of public interaction within
113+
the community.
114+
115+
## Attribution
116+
117+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
118+
version 2.0, available at
119+
https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
120+
121+
Community Impact Guidelines were inspired by [Mozilla's code of conduct
122+
enforcement ladder](https://github.com/mozilla/diversity).
123+
124+
[homepage]: https://www.contributor-covenant.org
125+
126+
For answers to common questions about this code of conduct, see the FAQ at
127+
https://www.contributor-covenant.org/faq. Translations are available at
128+
https://www.contributor-covenant.org/translations.

CONTRIBUTING.md

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
How to contribute
2+
==================
3+
Thank you for wanting to contribute to Spine. The following links will help you get started:
4+
* [Wiki home][wiki-home] — the home of the framework developer's documentation.
5+
* [Getting started with Spine in Java][quick-start] — this guide will walk you through
6+
a minimal client-server “Hello World!” application in Java.
7+
* [Introduction][docs-intro] — this section of the Spine Documentation will help you understand
8+
the foundation of the framework.
9+
10+
Pull requests
11+
-------------
12+
The work on an improvement starts with creating an issue that describes a bug or a feature. The issue will be used for communications on the proposed improvements.
13+
If code changes are going to be introduced, the issue should also have a link to the corresponding Pull Request.
14+
15+
Code contributions should:
16+
* Be accompanied by tests.
17+
* Be licensed under the Apache v2.0 license with the appropriate copyright header for each file.
18+
* Formatted according to the code style. See [Wiki home][wiki-home] for the links to
19+
style guides of the programming languages used in the framework.
20+
21+
Contributor License Agreement
22+
-----------------------------
23+
Contributions to the code of Spine Event Engine framework and its libraries must be accompanied by
24+
Contributor License Agreement (CLA).
25+
26+
* If you are an individual writing original source code and you're sure you own
27+
the intellectual property, then you'll need to sign an individual CLA.
28+
29+
* If you work for a company which wants you to contribute your work,
30+
then an authorized person from your company will need to sign a corporate CLA.
31+
32+
Please [contact us][legal-email] for arranging the paper formalities.
33+
34+
[wiki-home]: https://github.com/SpineEventEngine/SpineEventEngine.github.io/wiki
35+
[quick-start]: https://spine.io/docs/quick-start
36+
[docs-intro]: https://spine.io/docs/introduction
37+
[legal-email]: mailto:[email protected]

build.gradle.kts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020

2121
import io.spine.gradle.internal.DependencyResolution
2222
import io.spine.gradle.internal.Deps
23+
import io.spine.gradle.internal.IncrementGuard
2324
import io.spine.gradle.internal.PublishingRepos
2425

2526
buildscript {
@@ -210,4 +211,5 @@ apply {
210211
from(Deps.scripts.publish(project))
211212
from(Deps.scripts.repoLicenseReport(project))
212213
from(Deps.scripts.generatePom(project))
214+
plugin(IncrementGuard::class)
213215
}

buildSrc/src/main/kotlin/io/spine/gradle/internal/IncrementGuard.kt

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,41 @@ class IncrementGuard : Plugin<Project> {
3434
const val taskName = "checkVersionIncrement"
3535
}
3636

37+
/**
38+
* Adds the [CheckVersionIncrement] task to the project.
39+
*
40+
* Only adds the check if the project is built on Travis CI and the job is a pull request.
41+
*
42+
* The task will never run outside of Travis CI or when building individual branches. This is
43+
* done to prevent unexpected CI fails when re-building `master` multiple times, creating git
44+
* tags, and in other cases that go outside of the "usual" development cycle.
45+
*/
3746
override fun apply(target: Project) {
3847
val tasks = target.tasks
3948
tasks.register(taskName, CheckVersionIncrement::class.java) {
4049
repository = PublishingRepos.cloudRepo
4150
tasks.getByName("check").dependsOn(this)
4251

4352
shouldRunAfter("test")
53+
if (!isTravisPullRequest()) {
54+
logger.info("The build does not represent a Travis pull request job, the " +
55+
"`checkVersionIncrement` task is disabled.")
56+
this.enabled = false
57+
}
4458
}
4559
}
60+
61+
/**
62+
* Returns `true` if the current build is a Travis job which represents a GitHub pull request.
63+
*
64+
* Implementation note: the `TRAVIS_PULL_REQUEST` environment variable contains the pull
65+
* request number rather than `"true"` in positive case, hence the check.
66+
*
67+
* @see <a href="https://docs.travis-ci.com/user/environment-variables/#default-environment-variables">
68+
* List of default environment variables provided for Travis builds</a>
69+
*/
70+
private fun isTravisPullRequest(): Boolean {
71+
val isPullRequest = System.getenv("TRAVIS_PULL_REQUEST")
72+
return isPullRequest != null && isPullRequest != "false"
73+
}
4674
}

buildSrc/src/main/kotlin/io/spine/gradle/internal/deps.kt

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,10 +94,14 @@ object Versions {
9494
val javaPoet = "1.12.1"
9595
val autoService = "1.0-rc6"
9696
val autoCommon = "0.10"
97-
val jackson = "2.9.10.4"
97+
val jackson = "2.9.10.5"
9898
val animalSniffer = "1.18"
9999
val apiguardian = "1.1.0"
100100
val javaxAnnotation = "1.3.2"
101+
val klaxon = "5.4"
102+
val ouathJwt = "3.10.3"
103+
val bouncyCastlePkcs = "1.66"
104+
val assertK = "0.22"
101105

102106
/**
103107
* Version of the SLF4J library.
@@ -159,7 +163,7 @@ object Build {
159163

160164
object AutoService {
161165
val annotations = "com.google.auto.service:auto-service-annotations:${Versions.autoService}"
162-
val processor = "com.google.auto.service:auto-service:${Versions.autoService}"
166+
val processor = "com.google.auto.service:auto-service:${Versions.autoService}"
163167
}
164168
}
165169

@@ -168,6 +172,13 @@ object Gen {
168172
val javaxAnnotation = "javax.annotation:javax.annotation-api:${Versions.javaxAnnotation}"
169173
}
170174

175+
object Publishing {
176+
val klaxon = "com.beust:klaxon:${Versions.klaxon}"
177+
val oauthJwt = "com.auth0:java-jwt:${Versions.ouathJwt}"
178+
val bouncyCastlePkcs = "org.bouncycastle:bcpkix-jdk15on:${Versions.bouncyCastlePkcs}"
179+
val assertK = "com.willowtreeapps.assertk:assertk-jvm:${Versions.assertK}"
180+
}
181+
171182
object Grpc {
172183
val core = "io.grpc:grpc-core:${Versions.grpc}"
173184
val stub = "io.grpc:grpc-stub:${Versions.grpc}"
@@ -275,6 +286,7 @@ object Deps {
275286
val test = Test
276287
val versions = Versions
277288
val scripts = Scripts
289+
val publishing = Publishing
278290
}
279291

280292
object DependencyResolution {

0 commit comments

Comments
 (0)