Skip to content
111 changes: 111 additions & 0 deletions .github/autolabeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,111 @@
#
# 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
#
# https://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.
#

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, I pushed some more changes. I double checked manually by eyes but I didn't really run this plugin by myself. @nchammas can you double check the list please?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BTW, the tags here are same as JIRA components. There's one exception Documentation which should be usually DOCS per the contribution guide (the tag in the PR title).

# Bot page: https://github.com/apps/probot-autolabeler
# The matching patterns follow the .gitignore spec.
# See: https://git-scm.com/docs/gitignore#_pattern_format
# Also, note that the plugin uses 'ignore' package. See also
# https://github.com/kaelzhang/node-ignore
INFRA:
- ".github/"
- "appveyor.yml"
- "/tools/"
- "/dev/create-release/"
- ".asf.yaml"
- ".gitattributes"
- ".gitignore"
BUILD:
- "/dev/"
- "/build/"
- "/project/"
- "/assembly/"
- "*pom.xml"
- "/bin/docker-image-tool.sh"
- "/bin/find-spark-home*"
- "scalastyle-config.xml"
DOCS:
- "docs/"
- "/README.md"
- "/CONTRIBUTING.md"
EXAMPLES:
- "examples/"
- "/bin/run-example*"
CORE:
- "/core/"
- "/common/kvstore"
- "/common/network-common"
- "/common/network-shuffle"
- "/python/pyspark/*.py"
- "/python/pyspark/tests/*.py"
- "/sbin/*master*.sh"
- "/sbin/*slave*.sh"
- "/sbin/spark-config.sh"
- "/sbin/*daemon*.sh"
- "/sbin/*history*.sh"
- "/sbin/*mesos*.sh"
SPARK SUBMIT:
- "/bin/spark-submit*"
SPARK SHELL:
- "/repl"
SQL:
- "sql/"
- "/common/unsafe"
- "/python/pyspark/sql"
- "!/python/pyspark/sql/avro"
- "!/python/pyspark/sql/streaming.py"
- "!/python/pyspark/sql/tests/test_streaming.py"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think these ! lines will do what you want.

From https://git-scm.com/docs/gitignore#_pattern_format:

It is not possible to re-include a file if a parent directory of that file is excluded.

But we can try it out and see what happens.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, actually this way is from node-ignore package which the plugin uses. Hopefully it works..

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's see if it works or not.

- "/bin/spark-sql*"
- "/bin/beeline*"
- "/sbin/*thriftserver*.sh"
AVRO:
- "/external/avro"
- "/python/pyspark/sql/avro"
DSTREAM:
- "/streaming/"
- "/data/streaming"
- "/external/flume*"
- "/external/kinesis*"
- "/external/kafka*"
- "/python/pyspark/streaming"
GRAPHX:
- "/graphx/"
- "/data/graphx"
ML:
- "ml/"
- "/python/pyspark/ml"
MLLIB:
- "spark/mllib/"
- "/mllib-local"
- "/python/pyspark/mllib"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can collapse both this line and L91 into a single rule, mllib/.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, let me add another commit. Feel free to edit @nchammas meanwhile :).

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, I think we shouldn't collapse to mllib/ because /mllib/ contains both ML and MLlib.

STRUCTURED STREAMING:
- "sql/**/streaming/"
- "/external/kafka-0-10-sql/"
- "/python/pyspark/sql/streaming.py"
- "/python/pyspark/sql/tests/test_streaming.py"
PYTHON:
- "/bin/pyspark*"
- "python/"
R:
- "r/"
- "R/"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to https://github.com/kaelzhang/node-ignore#optionsignorecase-since-400 which the plugin uses, seems it's case-insensitive by default but I just kept it.

- "/bin/sparkR*"
YARN:
- "/resource-managers/yarn/"
MESOS:
- "/resource-managers/mesos/"
KUBERNETES:
- "/resource-managers/kubernetes/"