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

Merge 0.16 #244

Draft
wants to merge 37 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
d0b6490
feat: conversation api initial implementation
mikeee Nov 7, 2024
01d2214
fix(ci): trim blank spaces from version strings
mikeee Nov 7, 2024
78ad9fd
Merge pull request #235 from mikeee/remove-version-spaces
mikeee Nov 7, 2024
f70a18f
Merge branch 'release-0.16' into conversation-api
mikeee Nov 7, 2024
8f00930
fix(ci): fix installer bundle creation logic (#237)
mikeee Nov 7, 2024
7322ec4
Merge branch 'release-0.16' into conversation-api
mikeee Nov 7, 2024
5fd49f1
fix(ci): fix installer bundle creation logic (#238)
mikeee Nov 7, 2024
981340a
Merge branch 'release-0.16' into conversation-api
mikeee Nov 7, 2024
0f29428
fix(ci): fix installer bundle creation logic (#239)
mikeee Nov 7, 2024
12dd8af
Merge branch 'release-0.16' into conversation-api
mikeee Nov 7, 2024
dbc7a80
fix(test): close step token
mikeee Nov 7, 2024
fbb81bf
fix(test): example run
mikeee Nov 7, 2024
80a3a90
fix(test): example validation
mikeee Nov 7, 2024
04375f4
Merge pull request #234 from mikeee/conversation-api
mikeee Nov 7, 2024
df0bf88
Merge branch 'main' into release-0.16
mikeee Nov 16, 2024
b81f8f3
docs: fix typo
mikeee Nov 21, 2024
e04157d
docs: address #240 - update to 0.16.0 in anticipation of the release
mikeee Nov 21, 2024
580b88f
docs: address #241 with updated guidance on instantiating a client
mikeee Nov 21, 2024
0183be5
feat(state)!: add state and bulk state methods
mikeee Nov 24, 2024
597aa46
chore(lint): fmt
mikeee Nov 25, 2024
b1cacef
docs(state): update daprdocs
mikeee Nov 25, 2024
709c67e
Merge pull request #246 from mikeee/226-state_metadata
mikeee Nov 25, 2024
e78cab4
Merge branch 'release-0.16' into dapr-docs
mikeee Nov 25, 2024
4cfa9a3
Merge pull request #245 from mikeee/dapr-docs
mikeee Nov 25, 2024
b2be904
chore: bump rc versions
mikeee Nov 25, 2024
851abca
feat: add proto check and make directives
mikeee Nov 25, 2024
ae9bcda
ci: rename steps
mikeee Nov 25, 2024
fcff470
Merge pull request #247 from mikeee/rc3
mikeee Nov 25, 2024
e15f65b
ci: refactor doc test
mikeee Nov 25, 2024
95b009b
chore: remove macro dep from main crate
mikeee Nov 25, 2024
85ed911
chore: add macro dev-dependency and bump axum-test crate version
mikeee Nov 25, 2024
c4675a6
Merge branch 'release-0.16' into check-proto-diff
mikeee Nov 25, 2024
1ac0191
Merge pull request #248 from mikeee/check-proto-diff
mikeee Nov 25, 2024
1d88e20
Merge branch 'release-0.16' into rm-macro-dep
mikeee Nov 25, 2024
4da565c
Merge pull request #249 from mikeee/rm-macro-dep
mikeee Nov 25, 2024
abecc5c
ci: add dry publish test
mikeee Nov 25, 2024
f0498dc
Merge pull request #250 from mikeee/dry-publish
mikeee Nov 25, 2024
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
65 changes: 48 additions & 17 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ env:

jobs:
lint:
name: Lint
name: Check and Lint
runs-on: ubuntu-latest

steps:
Expand All @@ -37,14 +37,20 @@ jobs:
repo-token: ${{ secrets.GITHUB_TOKEN }}
version: ${{ env.PROTOC_VERSION }}
- uses: actions/checkout@v4

- name: Check compiled protos for a diff
run: |
make proto-gen check-diff-proto

- name: cargo fmt
run: cargo fmt -- --check --color ${{ env.CARGO_TERM_COLOR }}

- name: cargo clippy
run: cargo clippy


build:
name: Build on rust-${{ matrix.rust-version}}
name: Test and Build on rust-${{ matrix.rust-version }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand All @@ -71,33 +77,60 @@ jobs:
- name: Run Tests
run: cargo test --workspace --all-targets --all-features

test-docs-sdk:
name: Docs SDK
test-docs:
name: Check Docs - ${{ matrix.crate }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
crate:
- dapr
- dapr-macros
env:
RUSTDOCFLAGS: -Dwarnings
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly
- uses: dtolnay/install@cargo-docs-rs
- run: cargo docs-rs -p dapr
- run: cargo docs-rs -p ${{ matrix.crate }}

test-docs-macros:
name: Docs Macros
publish-dry:
name: Publish Test
runs-on: ubuntu-latest
env:
RUSTDOCFLAGS: -Dwarnings
strategy:
fail-fast: false
matrix:
crate:
- dapr
- dapr-macros

steps:
- name: Install Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
components: clippy, rustfmt
- name: Install Protoc
uses: arduino/setup-protoc@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
version: ${{ env.PROTOC_VERSION }}
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly
- uses: dtolnay/install@cargo-docs-rs
- run: cargo docs-rs -p dapr-macros
- name: cargo publish - ${{ matrix.crate }}
run: cargo publish --manifest-path ${{ matrix.crate }}/Cargo.toml --dry-run


publish:
name: Publish
runs-on: ubuntu-latest
needs: [test-docs-sdk, test-docs-macros, lint, build]
needs: [test-docs, lint, build, publish-dry]
if: startswith(github.ref, 'refs/tags/v')
strategy:
fail-fast: false
matrix:
crate:
- dapr
- dapr-macros

steps:
- name: Install Rust
Expand All @@ -111,7 +144,5 @@ jobs:
repo-token: ${{ secrets.GITHUB_TOKEN }}
version: ${{ env.PROTOC_VERSION }}
- uses: actions/checkout@v4
- name: cargo publish dapr-macros
run: cargo publish --manifest-path dapr-macros/Cargo.toml --token ${{ env.CARGO_TOKEN }}
- name: cargo publish dapr
run: cargo publish --manifest-path dapr/Cargo.toml --token ${{ env.CARGO_TOKEN }}
- name: cargo publish - ${{ matrix.crate }}
run: cargo publish --manifest-path ${{ matrix.crate }}/Cargo.toml --token ${{ env.CARGO_TOKEN }}
17 changes: 9 additions & 8 deletions .github/workflows/validate-examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
DAPR_INSTALL_URL: https://raw.githubusercontent.com/dapr/cli/master/install/install.sh
DAPR_CLI_REF: ${{ github.event.inputs_daprcli_commit }}
DAPR_CLI_VERSION: ${{ github.event.inputs_daprcli_version }}
DAPR_REF: ${{ github.event.inputs.dapr_commit }}
DAPR_REF: 334ae9eea43d487a7b29a0e4aef904e3eba57a10
DAPR_RUNTIME_VERSION: ${{ github.event.inputs.dapr_version }}
CHECKOUT_REPO: ${{ github.repository }}
CHECKOUT_REF: ${{ github.ref }}
Expand Down Expand Up @@ -76,14 +76,14 @@ jobs:
- name: Determine latest Dapr Runtime version
if: env.DAPR_RUNTIME_VERSION == ''
run: |
RUNTIME_VERSION=$(curl -s "https://api.github.com/repos/dapr/dapr/releases/latest" | grep '"tag_name"' | cut -d ':' -f2 | tr -d '",v')
RUNTIME_VERSION=$(curl -s "https://api.github.com/repos/dapr/dapr/releases/latest" | grep '"tag_name"' | cut -d ':' -f2 | tr -d ' ",v')
echo "DAPR_RUNTIME_VERSION=$RUNTIME_VERSION" >> $GITHUB_ENV
echo "Found $RUNTIME_VERSION"

- name: Determine latest Dapr Cli version
if: env.DAPR_CLI_VERSION == ''
run: |
CLI_VERSION=$(curl -s "https://api.github.com/repos/dapr/cli/releases/latest" | grep '"tag_name"' | cut -d ':' -f2 | tr -d '",v')
CLI_VERSION=$(curl -s "https://api.github.com/repos/dapr/cli/releases/latest" | grep '"tag_name"' | cut -d ':' -f2 | tr -d ' ",v')
echo "DAPR_CLI_VERSION=$CLI_VERSION" >> $GITHUB_ENV
echo "Found $CLI_VERSION"

Expand Down Expand Up @@ -127,6 +127,7 @@ jobs:
cd dapr_runtime
make
echo "artifactPath=~/artifacts/$GITHUB_SHA/" >> $GITHUB_ENV
mkdir -p $HOME/artifacts/$GITHUB_SHA/
RUNTIME_VERSION=edge
echo "DAPR_RUNTIME_VERSION=$RUNTIME_VERSION" >> $GITHUB_ENV

Expand All @@ -135,7 +136,7 @@ jobs:
run: |
mkdir ~/dapr_docker
cd dapr_runtime
docker build --build-arg "PKG_FILES=*" -f ./docker/Dockerfile ./dist/linux_amd64/release -t daprio/dapr:0.0.0-dev
docker build --build-arg "PKG_FILES=*" -f ./docker/Dockerfile ./dist/linux_amd64/release -t daprio/dapr:9.0.0-dev

- name: Download Install Bundle CLI
if: env.DAPR_REF != '' && env.DAPR_CLI_REF == ''
Expand All @@ -147,14 +148,14 @@ jobs:
ls -la

- name: Build Custom Install Bundle
if: env.DAPR_REF != '' && env.DAPR_CLI_REF != ''
if: env.DAPR_REF != '' || env.DAPR_CLI_REF != ''
run: |
: # Create daprbundle directory
mkdir ~/daprbundle
cp .github/workflows/validate-examples/details.json ~/daprbundle/

: # Add cli
cp ~/artifacts/$GITHUB_SHA/dapr ~/daprbundle/dapr
cp cli/dist/linux_amd64/release/dapr ~/daprbundle/dapr

: # Compress executables to /dist/ appending _linux_amd64 to the name
mkdir ~/daprbundle/dist
Expand All @@ -169,7 +170,7 @@ jobs:

: # Add docker image
mkdir ~/daprbundle/docker
docker save daprio/dapr:0.0.0-dev | gzip > ~/daprbundle/docker/daprio-dapr-0.0.0-dev.tar.gz
docker save daprio/dapr:9.0.0-dev | gzip > ~/daprbundle/docker/daprio-dapr-9.0.0-dev.tar.gz

: # Bundle
cd ~/daprbundle
Expand Down Expand Up @@ -219,7 +220,7 @@ jobs:
fail-fast: false
matrix:
examples:
[ "actors", "bindings", "client", "configuration", "crypto", "invoke/grpc", "invoke/grpc-proxying", "jobs", "pubsub", "query_state", "secrets-bulk" ]
[ "actors", "bindings", "client", "configuration", "conversation", "crypto", "invoke/grpc", "invoke/grpc-proxying", "jobs", "pubsub", "query_state", "secrets-bulk" ]
steps:
- name: Check out code
uses: actions/checkout@v4
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/validate-examples/details.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"daprd": "0.0.0-dev",
"dashboard": "0.0.0-dev",
"cli": "0.0.0-dev",
"daprd": "9.0.0-dev",
"dashboard": "9.0.0-dev",
"cli": "9.0.0-dev",
"daprBinarySubDir": "dist",
"dockerImageSubDir": "docker",
"daprImageName": "daprio/dapr:0.0.0-dev",
"daprImageFileName": "daprio-dapr-0.0.0-dev.tar.gz"
"daprImageName": "daprio/dapr:9.0.0-dev",
"daprImageFileName": "daprio-dapr-9.0.0-dev.tar.gz"
}
5 changes: 1 addition & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@ resolver = "2"

[workspace.dependencies]
async-trait = "0.1"

dapr-macros = { version = "0.16.0-rc.2", path = "./dapr-macros" }

prost = "0.13.1"
prost-build = "0.13.1"
prost-types = "0.13.1"
Expand All @@ -31,7 +28,7 @@ tonic = "0.12.1"
tonic-build = "0.12.1"

[workspace.package]
version = "0.16.0-rc.2"
version = "0.16.0-rc.3"
authors = [
"Mike Nguyen <[email protected]>",
"The Dapr Authors <[email protected]>"
Expand Down
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.PHONY: proto-gen
proto-gen:
cargo run --bin proto-gen

.PHONY: check-diff-proto
check-diff-proto:
git diff --exit-code ./proto/
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ Add the following to your `Cargo.toml` file:

```toml
[dependencies]
dapr = "0.16.0-rc.2"
dapr = "0.16.0-rc.3"
```

Here's a basic example to create a client:
Expand Down
4 changes: 2 additions & 2 deletions dapr/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ async-trait = { workspace = true }
axum = "0.7"
bytes = "1.7"
chrono = "0.4"
dapr-macros = { workspace = true }
futures = "0.3"
log = "0.4"
prost = { workspace = true }
Expand All @@ -28,9 +27,10 @@ tokio-util = { workspace = true, features = ["io"] }


[dev-dependencies]
axum-test = "15.3"
axum-test = "16.4.0"
once_cell = "1.19"
dapr = { path = "./" }
dapr-macros = { path = "../dapr-macros" }
tokio = { workspace = true, features = ["full"] }
uuid = { version = "1.10", features = ["v4"] }
tokio-test = { workspace = true }
Expand Down
Loading
Loading