Skip to content
This repository has been archived by the owner on Jan 12, 2024. It is now read-only.

Commit

Permalink
Merge pull request #96 from Nike-Inc/fix/integration-tests
Browse files Browse the repository at this point in the history
Fix/integration tests
  • Loading branch information
slichlyter12 authored Oct 1, 2021
2 parents a5f9468 + 148e274 commit 9b320c6
Show file tree
Hide file tree
Showing 19 changed files with 153 additions and 225 deletions.
10 changes: 7 additions & 3 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,17 @@ updates:
# Look for `build.gradle` files in the `root` directory
directory: "/"
target-branch: "dep/dependency_upgrade_staging"
open-pull-requests-limit: 30
open-pull-requests-limit: 20
schedule:
interval: "daily"
interval: "monthly"
time: "08:00"
timezone: "America/Los_Angeles"
- package-ecosystem: "github-actions"
# Look for `package.json` and `lock` files in the `cerberus-dashboard` directory
directory: "/"
target-branch: "dep/dependency_upgrade_staging"
# Check the npm registry for updates every day (weekdays)
schedule:
interval: "daily"
interval: "monthly"
time: "08:00"
timezone: "America/Los_Angeles"
47 changes: 0 additions & 47 deletions .github/workflows/release.yml

This file was deleted.

17 changes: 15 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# Cerberus Spring Boot Client

[ ![Download](https://api.bintray.com/packages/nike/maven/cerberus-spring-boot-client/images/download.svg) ](https://bintray.com/nike/maven/cerberus-spring-boot-client/_latestVersion)
![][gh actions img]
[![codecov](https://codecov.io/gh/Nike-Inc/cerberus-spring-boot-client/branch/master/graph/badge.svg)](https://codecov.io/gh/Nike-Inc/cerberus-spring-boot-client)
[![][license img]][license]
Expand All @@ -9,10 +8,24 @@ A Spring Boot client library for Cerberus for Spring Boot applications.

To learn more about Cerberus, please see the [Cerberus website](http://engineering.nike.com/cerberus/).

## Publishing Notice 3/17/2021
As of spring 2021, JFrog has decided to sunset Bintray and JCenter.
Due to this decision, we are pausing our open source publishing of the Cerberus Spring Boot Client.
However, we will still be updating the source code and making new GitHub releases.

In order to build the jar yourself, run this command:
```bash
./gradlew assemble
```

The jar will be located in `./build/libs/`.

For any questions or concerns, create a Github issue [here](https://github.com/Nike-Inc/cerberus-spring-boot-client/issues/new).

## Quickstart for EC2

1. Start with the [quick start guide](http://engineering.nike.com/cerberus/docs/user-guide/quick-start).
2. Add the [Cerberus Spring Boot Client dependency](https://bintray.com/nike/maven/cerberus-spring-boot-client) to your build (e.g. Maven, Gradle)
2. Add the Cerberus Spring Boot Client dependency to your build (e.g. Artifactory) or build the jar
3. Provide an authentication mechanism.
- For local development it is easiest to export a `CERBERUS_TOKEN` that you copied from the Cerberus dashboard.
When running in AWS, your application will not need this environmetal variable, instead it will automatically
Expand Down
2 changes: 0 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ buildscript {

apply plugin: 'java'
apply plugin: 'maven'
apply plugin: 'com.jfrog.bintray'
apply plugin: 'maven-publish'
apply plugin: "com.diffplug.gradle.spotless"

Expand All @@ -41,7 +40,6 @@ targetCompatibility = 1.8
apply from: 'gradle/dependencies.gradle'
apply from: 'gradle/check.gradle'
apply from: 'gradle/integration.gradle'
apply from: 'gradle/bintray.gradle'
apply from: 'gradle/owasp-dependency-check.gradle'

group = groupId
3 changes: 3 additions & 0 deletions dependency-check-supressions.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
<?xml version="1.0" encoding="UTF-8"?>
<suppressions xmlns="https://jeremylong.github.io/DependencyCheck/dependency-suppression.1.3.xsd">
</suppressions>
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
version=3.2.3
version=3.2.5
groupId=com.nike
artifactId=cerberus-spring-boot-client
75 changes: 0 additions & 75 deletions gradle/bintray.gradle

This file was deleted.

10 changes: 5 additions & 5 deletions gradle/buildscript.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@

repositories {
jcenter()
mavenCentral()
}

dependencies {
classpath "org.owasp:dependency-check-gradle:5.3.2"
classpath "net.saliman:gradle-cobertura-plugin:2.6.1"
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.5'
classpath 'org.kt3k.gradle.plugin:coveralls-gradle-plugin:2.6.3'
classpath "com.diffplug.spotless:spotless-plugin-gradle:3.30.0"
classpath "org.owasp:dependency-check-gradle:6.3.2"
classpath "net.saliman:gradle-cobertura-plugin:3.0.0"
classpath "org.kt3k.gradle.plugin:coveralls-gradle-plugin:2.8.3"
classpath "com.diffplug.spotless:spotless-plugin-gradle:4.5.1"
}
22 changes: 11 additions & 11 deletions gradle/dependencies.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,16 @@ repositories {

configurations.all {
resolutionStrategy {
force "ch.qos.logback:logback-core:1.2.3"
force "ch.qos.logback:logback-classic:1.2.3"
force "net.sourceforge.pmd:pmd-core:6.21.0"
force "net.sourceforge.pmd:pmd-java:6.21.0"
force "ch.qos.logback:logback-core:1.2.6"
force "ch.qos.logback:logback-classic:1.2.6"
force "net.sourceforge.pmd:pmd-core:6.39.0"
force "net.sourceforge.pmd:pmd-java:6.39.0"
force "com.fasterxml.jackson.core:jackson-databind:2.12.1"

dependencySubstitution {
substitute module("org.mortbay.jetty:jetty") with module("org.eclipse.jetty:jetty-server:9.4.33.v20201020")
substitute module("org.mortbay.jetty:jetty-util") with module("org.eclipse.jetty:jetty-util:9.4.33.v20201020")
substitute module("org.mortbay.jetty:jetty-http") with module("org.eclipse.jetty:jetty-http:11.0.0")
substitute module("org.mortbay.jetty:jetty") with module("org.eclipse.jetty:jetty-server:11.0.6")
substitute module("org.mortbay.jetty:jetty-util") with module("org.eclipse.jetty:jetty-util:11.0.6")
substitute module("org.mortbay.jetty:jetty-http") with module("org.eclipse.jetty:jetty-http:11.0.6")
substitute module("dom4j:dom4j:1.6.1") with module("org.dom4j:dom4j:2.1.3")
}
}
Expand All @@ -39,15 +40,14 @@ configurations.all {
dependencies {

// Spring dependencies
compile "org.springframework.boot:spring-boot-autoconfigure:2.4.2"
compile "org.springframework.boot:spring-boot-autoconfigure:2.5.5"

// Cerberus dependencies
compile "com.nike:cerberus-client:7.4.0"
compile 'com.nike:cerberus-client:v7.4.6'

// Test dependencies
testRuntime 'org.slf4j:slf4j-simple:1.7.30'
testCompile "org.junit.jupiter:junit-jupiter:5.7.0"
testCompile ("org.mockito:mockito-core:3.7.7") {
testCompile ("org.mockito:mockito-core:3.12.4") {
exclude group: 'org.hamcrest'
}
}
Expand Down
8 changes: 6 additions & 2 deletions gradle/integration.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,24 @@ sourceSets {
}

task integration(type: Test, description: 'Runs integration tests') {
testClassesDir = sourceSets.integration.output.classesDir
testClassesDirs = sourceSets.integration.output.classesDirs
classpath = sourceSets.integration.runtimeClasspath
outputs.upToDateWhen { false }
}

dependencies {
integrationCompile sourceSets.main.output
integrationCompile configurations.testCompile
integrationCompile sourceSets.test.output
integrationCompile 'com.fieldju:commons:1.1.0'
integrationCompile group: 'org.projectlombok', name: 'lombok', version: '1.18.8'
integrationCompile group: 'org.projectlombok', name: 'lombok', version: '1.18.20'
integrationRuntime configurations.testRuntime

integrationAnnotationProcessor "org.projectlombok:lombok:1.18.20"
}

integration {
useJUnitPlatform()
testLogging {
showStandardStreams = true
}
Expand Down
1 change: 1 addition & 0 deletions gradle/owasp-dependency-check.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ allprojects {
failOnError = false
format = 'ALL'
failBuildOnCVSS = 7
suppressionFile = "${rootProject.projectDir}/dependency-check-supressions.xml"
}
}

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-4.8.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-5.3.1-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading

0 comments on commit 9b320c6

Please sign in to comment.