Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# This should match the owning team set up in https://github.com/orgs/opensearch-project/teams
* @opensearch-project/search-request-processor-team
31 changes: 31 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
name: 🐛 Bug report
about: Create a report to help us improve
title: '[BUG]'
labels: 'bug, untriaged'
assignees: ''
---

**What is the bug?**
A clear and concise description of the bug.

**How can one reproduce the bug?**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**What is the expected behavior?**
A clear and concise description of what you expected to happen.

**What is your host/environment?**
- OS: [e.g. iOS]
- Version [e.g. 22]
- Plugins

**Do you have any screenshots?**
If applicable, add screenshots to help explain your problem.

**Do you have any additional context?**
Add any other context about the problem.
7 changes: 7 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
contact_links:
- name: OpenSearch Community Support
url: https://discuss.opendistrocommunity.dev/
about: Please ask and answer questions here.
- name: AWS/Amazon Security
url: https://aws.amazon.com/security/vulnerability-reporting/
about: Please report security vulnerabilities here.
11 changes: 11 additions & 0 deletions .github/ISSUE_TEMPLATE/documentation-issue.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
**Is your feature request related to a problem?**
A new feature has been added.

**What solution would you like?**
Document the usage of the new feature.

**What alternatives have you considered?**
N/A

**Do you have any additional context?**
See please
18 changes: 18 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
name: 🎆 Feature request
about: Request a feature in this project
title: '[FEATURE]'
labels: 'enhancement, untriaged'
assignees: ''
---
**Is your feature request related to a problem?**
A clear and concise description of what the problem is, e.g. _I'm always frustrated when [...]_

**What solution would you like?**
A clear and concise description of what you want to happen.

**What alternatives have you considered?**
A clear and concise description of any alternative solutions or features you've considered.

**Do you have any additional context?**
Add any other context or screenshots about the feature request here.
15 changes: 15 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
### Description
[Describe what this change achieves]

### Issues Resolved
[List any issues this PR will resolve]

### Check List
- [ ] New functionality includes testing.
- [ ] All tests pass
- [ ] New functionality has been documented.
- [ ] New functionality has javadoc added
- [ ] Commits are signed as per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check [here](https://github.com/opensearch-project/k-NN/blob/main/CONTRIBUTING.md#developer-certificate-of-origin).
40 changes: 40 additions & 0 deletions .github/draft-release-notes-config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# The overall template of the release notes
template: |
Compatible with OpenSearch (**set version here**).
$CHANGES

# Setting the formatting and sorting for the release notes body
name-template: Version (set version here)
change-template: '* $TITLE (#$NUMBER)'
sort-by: merged_at
sort-direction: ascending
replacers:
- search: '##'
replace: '###'

# Organizing the tagged PRs into categories
categories:
- title: 'Breaking Changes'
labels:
- 'Breaking Changes'
- title: 'Features'
labels:
- 'Features'
- title: 'Enhancements'
labels:
- 'Enhancements'
- title: 'Bug Fixes'
labels:
- 'Bug Fixes'
- title: 'Infrastructure'
labels:
- 'Infrastructure'
- title: 'Documentation'
labels:
- 'Documentation'
- title: 'Maintenance'
labels:
- 'Maintenance'
- title: 'Refactoring'
labels:
- 'Refactoring'
63 changes: 63 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
name: Build & Test Search Request Processor
on:
schedule:
- cron: '0 0 * * *' # every night
push:
branches:
- "*"
- "feature/**"
pull_request:
branches:
- "*"
- "feature/**"

jobs:
Build-search-request-processor:
strategy:
matrix:
java: [11, 17]
os: [ubuntu-latest, macos-latest] # want to get the build running first; fixing windows build after- windows-latest]

name: Build and Test Search Request Processor Plugin
runs-on: ${{ matrix.os }}

steps:
- name: Checkout Search Request Processor
uses: actions/checkout@v1

- name: Setup Java ${{ matrix.java }}
uses: actions/setup-java@v1
with:
java-version: ${{ matrix.java }}

- name: Run build
run: |
./gradlew build

- name: Upload Coverage Report
if: startsWith(matrix.os,'ubuntu')
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}

# Build-search-request-processor-Windows:
# strategy:
# matrix:
# java: [ 11, 17 ]
#
# name: Build and Test Search Request Processor Plugin on Windows
# runs-on: windows-latest

# steps:
# - name: Checkout Search Request Processor
# uses: actions/checkout@v1

# - name: Setup Java ${{ matrix.java }}
# uses: actions/setup-java@v1
# with:
# java-version: ${{ matrix.java }}
#
# - name: Run build
# run: |
# ./gradlew.bat build

28 changes: 28 additions & 0 deletions .github/workflows/backport.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Backport
on:
pull_request_target:
types:
- closed
- labeled

jobs:
backport:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
name: Backport
steps:
- name: GitHub App token
id: github_app_token
uses: tibdex/github-app-token@v1.5.0
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.APP_PRIVATE_KEY }}
installation_id: 22958780

- name: Backport
uses: VachaShah/backport@v1.1.4
with:
github_token: ${{ steps.github_app_token.outputs.token }}
branch_name: backport/backport-${{ github.event.number }}
69 changes: 69 additions & 0 deletions .github/workflows/backwards_compatibility_tests_workflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
name: Backwards Compatibility Tests Search Request Processor
on:
push:
branches:
- "*"
- "feature/**"
pull_request:
branches:
- "*"
- "feature/**"

jobs:
Restart-Upgrade-BWCTests-k-NN:
strategy:
matrix:
java: [ 11, 17 ]
bwc_version : [ "2.4.0" ]
opensearch_version : [ "3.0.0-SNAPSHOT" ]

name: SRP Restart-Upgrade BWC Tests
runs-on: ubuntu-latest
env:
BWC_VERSION_RESTART_UPGRADE: ${{ matrix.bwc_version }}

steps:
- name: Checkout SRP
uses: actions/checkout@v1

- name: Setup Java ${{ matrix.java }}
uses: actions/setup-java@v1
with:
java-version: ${{ matrix.java }}

# Comments intentional; these workflow scripts are copied from k-NN and we are reverse engineering them; missing qa directory fails the workflow here
# - name: Run SRP Restart-Upgrade BWC Tests from BWCVersion-${{ matrix.bwc_version }} to OpenSearch Version-${{ matrix.opensearch_version }}
# run: |
# echo "Running restart-upgrade backwards compatibility tests ..."
# ./gradlew :qa:restart-upgrade:testRestartUpgrade -Dtests.bwc.version=$BWC_VERSION_RESTART_UPGRADE


Rolling-Upgrade-BWCTests-SRP:
strategy:
matrix:
java: [ 11, 17 ]
bwc_version: [ "2.4.0" ]
opensearch_version: [ "3.0.0-SNAPSHOT" ]

name: SRP Rolling-Upgrade BWC Tests
runs-on: ubuntu-latest
env:
BWC_VERSION_ROLLING_UPGRADE: ${{ matrix.bwc_version }}

steps:
- name: Checkout SRP
uses: actions/checkout@v1

- name: Setup Java ${{ matrix.java }}
uses: actions/setup-java@v1
with:
java-version: ${{ matrix.java }}

# - name: Install dependencies
# run: |
# sudo apt-get install libopenblas-dev gfortran -y

# - name: Run SRP Rolling-Upgrade BWC Tests from BWCVersion-${{ matrix.bwc_version }} to OpenSearch Version-${{ matrix.opensearch_version }}
# run: |
# echo "Running rolling-upgrade backwards compatibility tests ..."
# ./gradlew :qa:rolling-upgrade:testRollingUpgrade -Dtests.bwc.version=$BWC_VERSION_ROLLING_UPGRADE
41 changes: 41 additions & 0 deletions .github/workflows/create-documentation-issue.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Create Documentation Issue
on:
pull_request:
types:
- labeled
env:
PR_NUMBER: ${{ github.event.number }}

jobs:
create-issue:
if: ${{ github.event.label.name == 'needs-documentation' }}
runs-on: ubuntu-latest
name: Create Documentation Issue
steps:
- name: GitHub App token
id: github_app_token
uses: tibdex/github-app-token@v1.5.0
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.APP_PRIVATE_KEY }}
installation_id: 22958780

- name: Checkout code
uses: actions/checkout@v2

- name: Edit the issue template
run: |
echo "https://github.com/opensearch-project/k-NN/pull/${{ env.PR_NUMBER }}." >> ./.github/ISSUE_TEMPLATE/documentation-issue.md

- name: Create Issue From File
id: create-issue
uses: peter-evans/create-issue-from-file@v4
with:
title: Add documentation related to new feature
content-filepath: ./.github/ISSUE_TEMPLATE/documentation-issue.md
labels: documentation
repository: opensearch-project/documentation-website
token: ${{ steps.github_app_token.outputs.token }}

- name: Print Issue
run: echo Created related documentation issue ${{ steps.create-issue.outputs.issue-number }}
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ jobs:
- name: DCO Check
uses: tim-actions/dco@v1.1.0
with:
commits: ${{ steps.get-pr-commits.outputs.commits }}
commits: ${{ steps.get-pr-commits.outputs.commits }}
15 changes: 15 additions & 0 deletions .github/workflows/delete_backport_branch.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Delete merged branch of the backport PRs
on:
pull_request:
types:
- closed

jobs:
delete-branch:
runs-on: ubuntu-latest
if: startsWith(github.event.pull_request.head.ref,'backport-')
steps:
- name: Delete merged branch
uses: SvanBoxel/delete-merged-branch@main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
20 changes: 20 additions & 0 deletions .github/workflows/draft-release-notes-workflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Release Drafter

on:
push:
branches:
- main

jobs:
update_release_draft:
name: Update draft release notes
runs-on: ubuntu-latest
steps:
- name: Update draft release notes
uses: release-drafter/release-drafter@v5
with:
config-name: draft-release-notes-config.yml
name: Version (set here)
tag: (None)
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Loading