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

Scraper flaky3 onlywindows #8

Open
wants to merge 51 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
777a37e
sleep for a while
ZenoCC-Peng Jul 26, 2023
2308c6c
sleep for a while
ZenoCC-Peng Jul 26, 2023
cc272f6
sleep for a while
ZenoCC-Peng Jul 26, 2023
813b01a
try sleep
ZenoCC-Peng Jul 26, 2023
594c751
try sleep
ZenoCC-Peng Jul 26, 2023
b2e7f0f
try sleep
ZenoCC-Peng Jul 26, 2023
1428183
Fix waiting logic
ZenoCC-Peng Jul 27, 2023
19f2213
fix with cpu
ZenoCC-Peng Jul 27, 2023
91df040
Change as for-loop
ZenoCC-Peng Jul 27, 2023
41ef7ab
Change to sleep
ZenoCC-Peng Jul 27, 2023
fa7f59d
Change
ZenoCC-Peng Jul 27, 2023
fef08ab
Change
ZenoCC-Peng Jul 27, 2023
871993a
Using time
ZenoCC-Peng Jul 27, 2023
ed685ca
Using load
ZenoCC-Peng Jul 27, 2023
ebc6d28
Using load
ZenoCC-Peng Jul 27, 2023
18fc4af
Merge branch 'main' into scraper-flaky2
ZenoCC-Peng Jul 27, 2023
f48dadf
fix code to latest version
ZenoCC-Peng Jul 27, 2023
bec1290
fix code to latest version
ZenoCC-Peng Jul 28, 2023
592b9e1
fix code to latest version
ZenoCC-Peng Jul 28, 2023
4b410eb
Refactor collectd from opensus to pdata
ZenoCC-Peng Jul 30, 2023
71d15c5
Make crosslink
ZenoCC-Peng Jul 30, 2023
0824410
Update tag
ZenoCC-Peng Jul 30, 2023
99b61b3
Update tag
ZenoCC-Peng Jul 31, 2023
1f16bb5
Merge branch 'main' into scraper-flaky2
ZenoCC-Peng Jul 31, 2023
fa52662
test for all
ZenoCC-Peng Jul 31, 2023
4985886
change lint
ZenoCC-Peng Jul 31, 2023
38fd9e5
change lint
ZenoCC-Peng Jul 31, 2023
fecbf10
change time format
ZenoCC-Peng Jul 31, 2023
f80b7d4
change time format
ZenoCC-Peng Jul 31, 2023
0e10f8c
change the way
ZenoCC-Peng Jul 31, 2023
0ae85c0
change the way
ZenoCC-Peng Jul 31, 2023
5cafd52
change the way
ZenoCC-Peng Jul 31, 2023
e89c45d
change the way
ZenoCC-Peng Jul 31, 2023
e2d6fb6
change the way
ZenoCC-Peng Aug 1, 2023
4c3be43
change the way
ZenoCC-Peng Aug 1, 2023
16cff3e
change the way
ZenoCC-Peng Aug 1, 2023
3b7c67a
change the way
ZenoCC-Peng Aug 1, 2023
ca7f7d5
only windows
ZenoCC-Peng Aug 1, 2023
7820f45
Merge branch 'main' into collectd-pdata-v3
ZenoCC-Peng Aug 1, 2023
656ba6a
Refactor from opensus to pdata
ZenoCC-Peng Aug 1, 2023
d35429e
Merge pull request #9 from ZenoCC-Peng/collectd-pdata-v3
ZenoCC-Peng Aug 1, 2023
c4b81a1
Merge branch 'main' into main
ZenoCC-Peng Aug 1, 2023
a6a2659
Update .chloggen/collectdreceiver-migrate-from-opensus-to-pdata.yaml
ZenoCC-Peng Aug 1, 2023
1fe7187
Remove redundant number
ZenoCC-Peng Aug 1, 2023
8e26866
Merge pull request #10 from ZenoCC-Peng/collectd-pdata-v3
ZenoCC-Peng Aug 1, 2023
55897dc
Remove redundant number
ZenoCC-Peng Aug 1, 2023
711fb03
Merge pull request #11 from ZenoCC-Peng/collectd-pdata-v3
ZenoCC-Peng Aug 1, 2023
bc032a9
Modify const variable in collectd
ZenoCC-Peng Aug 2, 2023
b24d1fc
Merge branch 'open-telemetry:main' into main
ZenoCC-Peng Aug 2, 2023
33f997f
Merge branch 'main' into collectd-pdata-v3
ZenoCC-Peng Aug 2, 2023
7f970ff
Merge branch 'main' into scraper-flaky3-onlywindows
ZenoCC-Peng Aug 3, 2023
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
15 changes: 15 additions & 0 deletions .chloggen/collectdreceiver-migrate-from-opensus-to-pdata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Use this changelog template to create an entry for release notes.
# If your change doesn't affect end users, such as a test fix or a tooling change,
# you should instead start your pull request title with [chore] or use the "Skip Changelog" label.

# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: enhancement

# The name of the component, or a single word describing the area of concern, (e.g. filelogreceiver)
component: receiver/collectdreceiver

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Migrate from opencensus to pdata, change collectd, test to match pdata format.

# Mandatory: One or more tracking issues related to the change. You can use the PR number here if no issue exists.
issues: [20760]
40 changes: 20 additions & 20 deletions .github/workflows/add-codeowners-to-pr.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
name: 'Add code owners to a PR'
on:
pull_request_target:
types:
- opened
- synchronize

jobs:
add-owners-to-pr:
runs-on: ubuntu-latest
if: ${{ github.actor != 'dependabot[bot]' && github.repository_owner == 'open-telemetry' }}
steps:
- uses: actions/checkout@v3

- name: Run add-codeowners-to-pr.sh
run: ./.github/workflows/scripts/add-codeowners-to-pr.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPO: ${{ github.repository }}
PR: ${{ github.event.number }}
#name: 'Add code owners to a PR'
#on:
# pull_request_target:
# types:
# - opened
# - synchronize
#
#jobs:
# add-owners-to-pr:
# runs-on: ubuntu-latest
# if: ${{ github.actor != 'dependabot[bot]' && github.repository_owner == 'open-telemetry' }}
# steps:
# - uses: actions/checkout@v3
#
# - name: Run add-codeowners-to-pr.sh
# run: ./.github/workflows/scripts/add-codeowners-to-pr.sh
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# REPO: ${{ github.repository }}
# PR: ${{ github.event.number }}
46 changes: 23 additions & 23 deletions .github/workflows/add-labels.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
name: 'Add Labels'
on:
issue_comment:
types: [created]

jobs:
add-labels:
if: ${{ !github.event.issue.pull_request && startsWith(github.event.comment.body, '/label') && github.repository_owner == 'open-telemetry' }}

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Run update permissions
run: chmod +x ./.github/workflows/scripts/add-labels.sh

- name: Run add-labels.sh
run: ./.github/workflows/scripts/add-labels.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
ISSUE: ${{ github.event.issue.number }}
COMMENT: ${{ github.event.comment.body }}
SENDER: ${{ github.event.sender.login }}
#name: 'Add Labels'
#on:
# issue_comment:
# types: [created]
#
#jobs:
# add-labels:
# if: ${{ !github.event.issue.pull_request && startsWith(github.event.comment.body, '/label') && github.repository_owner == 'open-telemetry' }}
#
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3
#
# - name: Run update permissions
# run: chmod +x ./.github/workflows/scripts/add-labels.sh
#
# - name: Run add-labels.sh
# run: ./.github/workflows/scripts/add-labels.sh
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# ISSUE: ${{ github.event.issue.number }}
# COMMENT: ${{ github.event.comment.body }}
# SENDER: ${{ github.event.sender.login }}
38 changes: 19 additions & 19 deletions .github/workflows/auto-assign-owners.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
name: 'Auto Assign'
on:
pull_request_target:
types: [opened, ready_for_review]

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true

jobs:
add-owner:
runs-on: ubuntu-latest
if: ${{ github.actor != 'dependabot[bot]' }}
steps:
- name: run
uses: kentaro-m/[email protected]
with:
configuration-path: ".github/auto_assign.yml"
repo-token: '${{ secrets.GITHUB_TOKEN }}'
#name: 'Auto Assign'
#on:
# pull_request_target:
# types: [opened, ready_for_review]
#
#concurrency:
# group: ${{ github.workflow }}-${{ github.head_ref }}
# cancel-in-progress: true
#
#jobs:
# add-owner:
# runs-on: ubuntu-latest
# if: ${{ github.actor != 'dependabot[bot]' }}
# steps:
# - name: run
# uses: kentaro-m/[email protected]
# with:
# configuration-path: ".github/auto_assign.yml"
# repo-token: '${{ secrets.GITHUB_TOKEN }}'
232 changes: 116 additions & 116 deletions .github/workflows/auto-update-jmx-metrics-component.yml
Original file line number Diff line number Diff line change
@@ -1,116 +1,116 @@
name: Auto-update JMX metrics component

on:
schedule:
# Daily at 01:30 (UTC)
- cron: '30 1 * * *'
workflow_dispatch:

jobs:
check-versions:
runs-on: ubuntu-latest
outputs:
latest-version: ${{ steps.check-versions.outputs.latest-version }}
already-added: ${{ steps.check-versions.outputs.already-added }}
already-opened: ${{ steps.check-versions.outputs.already-opened }}
steps:
- uses: actions/checkout@v3

- id: check-versions
name: Check versions
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
latest_version=$(gh release view \
--repo open-telemetry/opentelemetry-java-contrib \
--json tagName \
--jq .tagName \
| sed 's/^v//')

# jmx metric gatherer is currently alpha
latest_version=$latest_version-alpha

if grep -Pzo "version: \"$latest_version\",\s*jar:\s*\"JMX metrics gatherer\"" receiver/jmxreceiver/supported_jars.go; then
already_added=true
fi

matches=$(gh pr list \
--author opentelemetrybot \
--state open \
--search "in:title \"Add JMX metrics gatherer version $latest_version\"")
if [ ! -z "$matches" ]
then
already_opened=true
fi

echo "latest-version=$latest_version" >> $GITHUB_OUTPUT
echo "already-added=$already_added" >> $GITHUB_OUTPUT
echo "already-opened=$already_opened" >> $GITHUB_OUTPUT

update-jmx-metrics-component:
runs-on: ubuntu-latest
if: |
needs.check-versions.outputs.already-added != 'true' &&
needs.check-versions.outputs.already-opened != 'true'
needs:
- check-versions
steps:
- uses: actions/checkout@v3

- name: Update version
env:
VERSION: ${{ needs.check-versions.outputs.latest-version }}
run: |
if [[ ! $VERSION =~ -alpha$ ]]; then
echo currently expecting jmx metrics version to end with "-alpha"
exit 1
fi

version=${VERSION//-alpha/}
hash=$(curl -L https://github.com/open-telemetry/opentelemetry-java-contrib/releases/download/v$version/opentelemetry-jmx-metrics.jar \
| sha256sum \
| cut -d ' ' -f 1)

# NOTE there are intentional tab characters in the line below
sed -i "/^var jmxMetricsGathererVersions/a \ \"$hash\": {\n version: \"$VERSION\",\n jar: \"JMX metrics gatherer\",\n }," receiver/jmxreceiver/supported_jars.go
git diff

- name: Use CLA approved github bot
run: |
git config user.name opentelemetrybot
git config user.email [email protected]

- name: Create pull request against main
env:
VERSION: ${{ needs.check-versions.outputs.latest-version }}
# not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows
GH_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
run: |
message="Add JMX metrics gatherer version $VERSION"
body="Add JMX metrics gatherer version \`$VERSION\`.

cc @open-telemetry/java-contrib-approvers
"
branch="opentelemetrybot/add-jmx-metrics-gatherer-${VERSION}"

git checkout -b $branch
git commit -a -m "$message"
git push --set-upstream origin $branch
url=$(gh pr create --title "$message" \
--body "$body" \
--base main)

pull_request_number=${url//*\//}
# see the template for change log entry file at blob/main/.chloggen/TEMPLATE.yaml
cat > .chloggen/add-jmx-metrics-gatherer-$VERSION.yaml << EOF
change_type: enhancement
component: jmxreceiver
note: Add the JMX metrics gatherer version $VERSION to the supported jars hash list
issues: [ $pull_request_number ]
EOF

git add .chloggen/add-jmx-metrics-gatherer-$VERSION.yaml

git commit -m "Add change log entry"
git push
#name: Auto-update JMX metrics component
#
#on:
# schedule:
# # Daily at 01:30 (UTC)
# - cron: '30 1 * * *'
# workflow_dispatch:
#
#jobs:
# check-versions:
# runs-on: ubuntu-latest
# outputs:
# latest-version: ${{ steps.check-versions.outputs.latest-version }}
# already-added: ${{ steps.check-versions.outputs.already-added }}
# already-opened: ${{ steps.check-versions.outputs.already-opened }}
# steps:
# - uses: actions/checkout@v3
#
# - id: check-versions
# name: Check versions
# env:
# GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# run: |
# latest_version=$(gh release view \
# --repo open-telemetry/opentelemetry-java-contrib \
# --json tagName \
# --jq .tagName \
# | sed 's/^v//')
#
# # jmx metric gatherer is currently alpha
# latest_version=$latest_version-alpha
#
# if grep -Pzo "version: \"$latest_version\",\s*jar:\s*\"JMX metrics gatherer\"" receiver/jmxreceiver/supported_jars.go; then
# already_added=true
# fi
#
# matches=$(gh pr list \
# --author opentelemetrybot \
# --state open \
# --search "in:title \"Add JMX metrics gatherer version $latest_version\"")
# if [ ! -z "$matches" ]
# then
# already_opened=true
# fi
#
# echo "latest-version=$latest_version" >> $GITHUB_OUTPUT
# echo "already-added=$already_added" >> $GITHUB_OUTPUT
# echo "already-opened=$already_opened" >> $GITHUB_OUTPUT
#
# update-jmx-metrics-component:
# runs-on: ubuntu-latest
# if: |
# needs.check-versions.outputs.already-added != 'true' &&
# needs.check-versions.outputs.already-opened != 'true'
# needs:
# - check-versions
# steps:
# - uses: actions/checkout@v3
#
# - name: Update version
# env:
# VERSION: ${{ needs.check-versions.outputs.latest-version }}
# run: |
# if [[ ! $VERSION =~ -alpha$ ]]; then
# echo currently expecting jmx metrics version to end with "-alpha"
# exit 1
# fi
#
# version=${VERSION//-alpha/}
# hash=$(curl -L https://github.com/open-telemetry/opentelemetry-java-contrib/releases/download/v$version/opentelemetry-jmx-metrics.jar \
# | sha256sum \
# | cut -d ' ' -f 1)
#
# # NOTE there are intentional tab characters in the line below
# sed -i "/^var jmxMetricsGathererVersions/a \ \"$hash\": {\n version: \"$VERSION\",\n jar: \"JMX metrics gatherer\",\n }," receiver/jmxreceiver/supported_jars.go
# git diff
#
# - name: Use CLA approved github bot
# run: |
# git config user.name opentelemetrybot
# git config user.email [email protected]
#
# - name: Create pull request against main
# env:
# VERSION: ${{ needs.check-versions.outputs.latest-version }}
# # not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows
# GH_TOKEN: ${{ secrets.OPENTELEMETRYBOT_GITHUB_TOKEN }}
# run: |
# message="Add JMX metrics gatherer version $VERSION"
# body="Add JMX metrics gatherer version \`$VERSION\`.
#
# cc @open-telemetry/java-contrib-approvers
# "
# branch="opentelemetrybot/add-jmx-metrics-gatherer-${VERSION}"
#
# git checkout -b $branch
# git commit -a -m "$message"
# git push --set-upstream origin $branch
# url=$(gh pr create --title "$message" \
# --body "$body" \
# --base main)
#
# pull_request_number=${url//*\//}
#
# # see the template for change log entry file at blob/main/.chloggen/TEMPLATE.yaml
# cat > .chloggen/add-jmx-metrics-gatherer-$VERSION.yaml << EOF
# change_type: enhancement
# component: jmxreceiver
# note: Add the JMX metrics gatherer version $VERSION to the supported jars hash list
# issues: [ $pull_request_number ]
# EOF
#
# git add .chloggen/add-jmx-metrics-gatherer-$VERSION.yaml
#
# git commit -m "Add change log entry"
# git push
4 changes: 2 additions & 2 deletions .github/workflows/build-and-test-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
- pkg
- other
runs-on: windows-latest
if: ${{ github.actor != 'dependabot[bot]' && (contains(github.event.pull_request.labels.*.name, 'Run Windows') || github.event_name == 'push') }}
#if: ${{ github.actor != 'dependabot[bot]' && (contains(github.event.pull_request.labels.*.name, 'Run Windows') || github.event_name == 'push') }}
steps:
- uses: actions/checkout@v3
- if: matrix.group == 'receiver-0'
Expand All @@ -57,7 +57,7 @@ jobs:
- name: Run Unit tests
run: make -j2 gotest GROUP=${{ matrix.group }}
windows-unittest:
if: ${{ github.actor != 'dependabot[bot]' && (contains(github.event.pull_request.labels.*.name, 'Run Windows') || github.event_name == 'push') }}
#if: ${{ github.actor != 'dependabot[bot]' && (contains(github.event.pull_request.labels.*.name, 'Run Windows') || github.event_name == 'push') }}
runs-on: windows-latest
needs: [windows-unittest-matrix]
steps:
Expand Down
Loading