blob: 3ed675f68de5032efe76792e3c380c6a5926cfc5 [file]
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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
#
# http://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.
name: CI
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-26.04
steps:
- uses: actions/checkout@v6
# FLINK-39787: GitHub-hosted Azure runners assign a VM hostname whose
# reverse DNS returns an internal cloudapp.net FQDN. The SSL benchmarks
# rely on flink-runtime's local127.keystore, whose SAN list only contains
# 'localhost', '127.0.0.1', and '::1'. Map the runner hostname to the
# loopback interface so InetAddress.getLocalHost() (used to bind the
# benchmark NettyServer) returns 127.0.0.1 and the SSL handshake matches
# the certificate. The real fix belongs in apache/flink's
# StreamNetworkBenchmarkEnvironment (use getLoopbackAddress instead of
# getLocalHost); track separately.
- name: Map runner hostname to loopback
run: |
sudo sed -i "/$(hostname)/d" /etc/hosts
echo "127.0.0.1 localhost $(hostname -f) $(hostname)" | sudo tee -a /etc/hosts
echo "After shim:"
getent hosts "$(hostname)"
getent hosts 127.0.0.1
- name: Set JDK
uses: actions/setup-java@v5
with:
java-version: 17
distribution: 'temurin'
cache: 'maven'
- name: Set Maven 3.8.6
uses: stCarolas/setup-maven@v5
with:
maven-version: 3.8.6
- name: Install prerequisites
run: |
sudo apt-get update
sudo apt-get install -y libssl3 libapr1
- name: Compile
# https.protocols is a workaround for https://bugs.openjdk.java.net/browse/JDK-8213202
run: mvn install -P test-java17 -DskipTests=true -Dmaven.javadoc.skip=true -Dhttps.protocols=TLSv1,TLSv1.1,TLSv1.2 -B -V
- name: Test
run: mvn test -P test-java17 -B