Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KAFKA-17542: Use actions/labeler for automatic PR labeling #17208

Merged
merged 13 commits into from
Sep 19, 2024
130 changes: 130 additions & 0 deletions .github/configs/labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
# 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.

build:
- changed-files:
- any-glob-to-any-file:
- '.github/**'
- 'gradle/**'
- '*gradlew*'

clients:
- changed-files:
- any-glob-to-any-file:
- 'clients/**'


tests:
- all:
- changed-files:
- any-glob-to-all-files:
- 'tests/**'
- '**/test/**'


connect:
- all:
- changed-files:
- any-glob-to-any-file:
- 'connect/**/*'
- all-globs-to-all-files:
- '!connect/mirror/*'

mirror-maker-2:
- changed-files:
- any-glob-to-any-file:
- 'connect/mirror/**'


core:
- changed-files:
- any-glob-to-any-file:
- 'core/**'
- '*server*/**'

storage:
- changed-files:
- any-glob-to-any-file:
- 'storage/**'

streams:
- changed-files:
- any-glob-to-any-file:
- 'streams/**'

tools:
- changed-files:
- any-glob-to-any-file:
- 'tools/**'
- 'trogdor/**'
- 'vagrant/**'
- 'committer-tools/**'
- 'log4j-appender/**'
- 'shell/**'

docs:
- changed-files:
- any-glob-to-all-files:
- 'docs/**'
- '**/*.md'
- 'examples/**'

generator:
- changed-files:
- any-glob-to-any-file:
- 'generator/**'

transaction:
TaiJuWu marked this conversation as resolved.
Show resolved Hide resolved
- changed-files:
- any-glob-to-any-file:
- 'transaction*/**'
mumrah marked this conversation as resolved.
Show resolved Hide resolved

share:
mumrah marked this conversation as resolved.
Show resolved Hide resolved
- changed-files:
- any-glob-to-any-file:
- '*share*/**'

docker:
mumrah marked this conversation as resolved.
Show resolved Hide resolved
- changed-files:
- any-glob-to-any-file:
- 'docker/**'


coordinator:
mumrah marked this conversation as resolved.
Show resolved Hide resolved
- changed-files:
- any-glob-to-any-file:
- 'group-coordinator/**'
- 'coordinator-common/**'

performance:
- changed-files:
- any-glob-to-any-file:
- 'jmh-benchmarks/**'

consumer:
- changed-files:
- any-glob-to-any-file:
- 'clients/src/main/java/org/apache/kafka/clients/consumer/**'

producer:
- changed-files:
- any-glob-to-any-file:
- 'clients/src/main/java/org/apache/kafka/clients/producer/**'

kraft:
- changed-files:
- any-glob-to-any-file:
- 'metadata/**'
- 'raft/**'
31 changes: 31 additions & 0 deletions .github/workflows/labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# 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: "Pull Request Labeler"
on:
pull_request_target:
types: [opened, reopened, synchronize]


jobs:
label_PRs:
permissions:
contents: read
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@v5
TaiJuWu marked this conversation as resolved.
Show resolved Hide resolved
with:
configuration-path: .github/configs/labeler.yml