Skip to content

Non stale querying of aggregate projections running asynchronously #1143

Non stale querying of aggregate projections running asynchronously

Non stale querying of aggregate projections running asynchronously #1143

name: build_net7.0 pg12-plv8 Json.NET
on:
push:
branches:
- master
paths-ignore:
- 'documentation/**'
- 'docs/**'
- 'azure-pipelines.yml'
pull_request:
branches:
- master
paths-ignore:
- 'documentation/**'
- 'docs/**'
- 'azure-pipelines.yml'
env:
DOTNET_CLI_TELEMETRY_OPTOUT: 1
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1
node_version: 16.x
pg_db: marten_testing
pg_user: postgres
CONFIGURATION: Release
FRAMEWORK: net9.0
DISABLE_TEST_PARALLELIZATION: true
DEFAULT_SERIALIZER: "Newtonsoft"
NUKE_TELEMETRY_OPTOUT: true
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 20
services:
postgres:
image: ionx/postgres-plv8:12.8
ports:
- 5432:5432
env:
POSTGRES_HOST_AUTH_METHOD: trust
POSTGRES_DB: ${{ env.pg_db }}
NAMEDATALEN: 150
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
--user postgres
steps:
- uses: actions/checkout@v4
- name: Install .NET 6.0.x
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
- name: Install .NET 7.0.x
uses: actions/setup-dotnet@v3
with:
dotnet-version: 7.0.x
- name: Install .NET 8.0.x
uses: actions/setup-dotnet@v3
with:
dotnet-version: 8.0.x
- name: Install .NET 9.0.x
uses: actions/setup-dotnet@v3
with:
dotnet-version: 9.0.x
- name: Install .NET Aspire workload
run: |
dotnet workload update
dotnet workload install aspire
- name: Install Node.js
uses: actions/setup-node@v3
with:
node-version: ${{ env.node_version }}
- name: Check and install plv8 extension
run: |
PG_CONTAINER_NAME=$(docker ps --filter expose=5432/tcp --format {{.Names}})
docker exec $PG_CONTAINER_NAME psql -U ${{ env.pg_user }} -d ${{ env.pg_db }} -c "CREATE EXTENSION IF NOT EXISTS plv8;"
docker exec $PG_CONTAINER_NAME psql -U ${{env.pg_user}} -d ${{ env.pg_db }} -c "DO 'plv8.elog(NOTICE, plv8.version);' LANGUAGE plv8;"
shell: bash
- name: Optimize database for running tests faster
run: |
PG_CONTAINER_NAME=$(docker ps --filter expose=5432/tcp --format {{.Names}})
docker exec $PG_CONTAINER_NAME bash -c "echo -e '\nfsync = off' >> /var/lib/postgresql/data/postgresql.conf"
docker exec $PG_CONTAINER_NAME bash -c "echo -e '\nfull_page_writes = off' >> /var/lib/postgresql/data/postgresql.conf"
docker exec $PG_CONTAINER_NAME bash -c "echo -e '\nsynchronous_commit = off' >> /var/lib/postgresql/data/postgresql.conf"
docker container restart $PG_CONTAINER_NAME
shell: bash
- name: compile
run: ./build.sh compile
shell: bash
- name: mocha
if: ${{ success() || failure() }}
run: ./build.sh mocha
shell: bash
- name: test-base-lib
if: ${{ success() || failure() }}
run: ./build.sh test-base-lib
shell: bash
- name: test-core
if: ${{ success() || failure() }}
run: ./build.sh test-core
shell: bash
- name: test-document-db
if: ${{ success() || failure() }}
run: ./build.sh test-document-db
shell: bash
- name: test-event-sourcing
if: ${{ success() || failure() }}
run: ./build.sh test-event-sourcing
shell: bash
- name: test-cli
if: ${{ success() || failure() }}
run: ./build.sh test-cli
shell: bash
- name: test-linq
if: ${{ success() || failure() }}
run: ./build.sh test-linq
shell: bash
# - name: test-multi-tenancy
# if: ${{ success() || failure() }}
# run: ./build.sh test-multi-tenancy
# shell: bash
- name: test-patching
if: ${{ success() || failure() }}
run: ./build.sh test-patching
shell: bash
- name: test-value-types
if: ${{ success() || failure() }}
run: ./build.sh test-value-types
shell: bash
- name: test-code-gen
if: ${{ success() || failure() }}
run: ./build.sh test-code-gen
shell: bash
- name: test-noda-time
if: ${{ success() || failure() }}
run: ./build.sh test-noda-time
shell: bash
- name: test-aspnet-core
if: ${{ success() || failure() }}
run: ./build.sh test-aspnet-core
shell: bash
- name: test-plv8
if: ${{ success() || failure() }}
run: ./build.sh test-plv8
shell: bash