Skip to content

[maven-release-plugin] prepare release thirdeye-1.303.0 #1236

[maven-release-plugin] prepare release thirdeye-1.303.0

[maven-release-plugin] prepare release thirdeye-1.303.0 #1236

# This workflow will build a Java project with Maven
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
name: Run backend tests
on:
push:
branches: [ master ]
paths-ignore:
- thirdeye-ui/**
- kubernetes/**
pull_request:
branches: [ master ]
paths-ignore:
- thirdeye-ui/**
- kubernetes/**
jobs:
build:
name: Build and run tests
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- uses: actions/checkout@v2
- name: Install java and setup artifactory
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
server-id: startree-releases
server-username: ARTIFACTORY_USERNAME_REF
server-password: ARTIFACTORY_TOKEN_REF
# don't use setup-java cache - hash file pattern has issues
- name: Cache - restore local Maven repository
id: cache-restore
uses: actions/cache/restore@v3
with:
path: |
~/.m2/repository
~/.m2/wrapper
key: tests-${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: tests-${{ runner.os }}-maven-
- name: Build with Maven
run: ./mvnw -U -T 1C -B clean verify
env:
ARTIFACTORY_USERNAME_REF: ${{ secrets.MVN_ARTIFACTORY_USERNAME }}
ARTIFACTORY_TOKEN_REF: ${{ secrets.MVN_ARTIFACTORY_TOKEN }}
- name: Cache - save local Maven repository
uses: actions/cache/save@v3
# save to cache only if necessary + cache even if tests failed (for faster flaky tests)
if: steps.cache-restore.outputs.cache-hit != 'true' && ( failure() || success())
with:
path: |
~/.m2/repository
~/.m2/wrapper
key: tests-${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
- name: Slack - Notify Failure
uses: rtCamp/action-slack-notify@v2
if: github.ref == 'refs/heads/master' && failure()
env:
SLACK_COLOR: ${{ job.status }}
SLACK_MESSAGE: "@here - ThirdEye backend tests failed."
SLACK_TITLE: FAILURE
SLACK_LINK_NAMES: true
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}