Skip to content

Commit 717db82

Browse files
lidavidmkou
andauthored
apacheGH-6: Add Linux test CI (apache#339)
Fixes apache#6. --------- Co-authored-by: Sutou Kouhei <[email protected]>
1 parent 61f7b1e commit 717db82

File tree

25 files changed

+4646
-20
lines changed

25 files changed

+4646
-20
lines changed

.env

+50
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
18+
# All of the following environment variables are required to set default values
19+
# for the parameters in docker-compose.yml.
20+
21+
# empty prefix means that the docker-compose configuration will use named
22+
# volumes which potentially improves the performance on docker for macos and
23+
# docker for windows, it also prevents the contamination of the source
24+
# directory
25+
# a non-empty prefix means that directories from the host are bind-mounted
26+
# into the container, it should be set to ".docker/" on github actions to keep
27+
# the cache plugin functional
28+
DOCKER_VOLUME_PREFIX=
29+
30+
# turn on inline build cache, this is a docker buildx feature documented
31+
# at https://github.com/docker/buildx#--cache-tonametypetypekeyvalue
32+
BUILDKIT_INLINE_CACHE=1
33+
COMPOSE_DOCKER_CLI_BUILD=1
34+
DOCKER_BUILDKIT=1
35+
36+
# different architecture notations
37+
ARCH=amd64
38+
ARCH_ALIAS=x86_64
39+
ARCH_SHORT=amd64
40+
41+
# Default repository to pull and push images from
42+
REPO=ghcr.io/apache/arrow-java-dev
43+
44+
# The setup attempts to generate coredumps by default, in order to disable the
45+
# coredump generation set it to 0
46+
ULIMIT_CORE=-1
47+
48+
# Default versions for various dependencies
49+
JDK=11
50+
MAVEN=3.9.6

.github/workflows/test.yml

+74
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
18+
name: Test
19+
20+
on:
21+
push:
22+
branches:
23+
- '**'
24+
- '!dependabot/**'
25+
tags:
26+
- '**'
27+
pull_request:
28+
29+
concurrency:
30+
group: ${{ github.repository }}-${{ github.head_ref || github.sha }}-${{ github.workflow }}
31+
cancel-in-progress: true
32+
33+
permissions:
34+
contents: read
35+
36+
env:
37+
DOCKER_VOLUME_PREFIX: ".docker/"
38+
39+
jobs:
40+
ubuntu:
41+
name: AMD64 Ubuntu 22.04 JDK ${{ matrix.jdk }} Maven ${{ matrix.maven }}
42+
runs-on: ubuntu-latest
43+
if: ${{ !contains(github.event.pull_request.title, 'WIP') }}
44+
timeout-minutes: 30
45+
strategy:
46+
fail-fast: false
47+
matrix:
48+
jdk: [11, 17, 21, 22]
49+
maven: [3.9.6]
50+
image: [java]
51+
env:
52+
JDK: ${{ matrix.jdk }}
53+
MAVEN: ${{ matrix.maven }}
54+
steps:
55+
- name: Checkout Arrow
56+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
57+
with:
58+
fetch-depth: 0
59+
submodules: recursive
60+
- name: Cache Docker Volumes
61+
uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4.1.2
62+
with:
63+
path: .docker
64+
key: maven-${{ matrix.jdk }}-${{ matrix.maven }}-${{ hashFiles('**/docker-compose.yml') }}
65+
restore-keys: maven-${{ matrix.jdk }}-${{ matrix.maven }}-
66+
- name: Execute Docker Build
67+
env:
68+
# Enables build caching, but not strictly required
69+
DEVELOCITY_ACCESS_KEY: ${{ secrets.GE_ACCESS_TOKEN }}
70+
run: |
71+
docker compose run \
72+
-e CI=true \
73+
-e "DEVELOCITY_ACCESS_KEY=$DEVELOCITY_ACCESS_KEY" \
74+
${{ matrix.image }}

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -26,3 +26,4 @@ cmake_install.cmake
2626
dependency-reduced-pom.xml
2727
install_manifest.txt
2828
target/
29+
/.mvn/.develocity/

.gitmodules

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[submodule "testing"]
2+
path = testing
3+
url = https://github.com/apache/arrow-testing.git

arrow-format/File.fbs

+52
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
// Licensed to the Apache Software Foundation (ASF) under one
2+
// or more contributor license agreements. See the NOTICE file
3+
// distributed with this work for additional information
4+
// regarding copyright ownership. The ASF licenses this file
5+
// to you under the Apache License, Version 2.0 (the
6+
// "License"); you may not use this file except in compliance
7+
// with the License. You may obtain a copy of the License at
8+
//
9+
// http://www.apache.org/licenses/LICENSE-2.0
10+
//
11+
// Unless required by applicable law or agreed to in writing,
12+
// software distributed under the License is distributed on an
13+
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
// KIND, either express or implied. See the License for the
15+
// specific language governing permissions and limitations
16+
// under the License.
17+
18+
include "Schema.fbs";
19+
20+
namespace org.apache.arrow.flatbuf;
21+
22+
/// ----------------------------------------------------------------------
23+
/// Arrow File metadata
24+
///
25+
26+
table Footer {
27+
version: org.apache.arrow.flatbuf.MetadataVersion;
28+
29+
schema: org.apache.arrow.flatbuf.Schema;
30+
31+
dictionaries: [ Block ];
32+
33+
recordBatches: [ Block ];
34+
35+
/// User-defined metadata
36+
custom_metadata: [ KeyValue ];
37+
}
38+
39+
struct Block {
40+
41+
/// Index to the start of the RecordBlock (note this is past the Message header)
42+
offset: long;
43+
44+
/// Length of the metadata
45+
metaDataLength: int;
46+
47+
/// Length of the data (this is aligned so there can be a gap between this and
48+
/// the metadata).
49+
bodyLength: long;
50+
}
51+
52+
root_type Footer;

0 commit comments

Comments
 (0)