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

Restructure Chariott repo to show the separation between intent brokering and service discovery #247

Merged
merged 13 commits into from
Jan 19, 2024
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
6 changes: 3 additions & 3 deletions .github/workflows/containerize.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ on:
branches:
- main
paths:
- "src/**"
- "proto/**"
- "Dockerfile"
- "intent_brokering/src/**"
- "intent_brokering/proto/**"
- "Dockerfile.intent_brokering"
- ".github/workflows/containerize.yaml"
- "rust-toolchain.toml"

Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/dotnet-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
branches:
- main
paths:
- 'examples/applications/dog-mode-ui/**'
- 'intent_brokering/examples/applications/dog-mode-ui/**'
- '.github/workflows/dotnet-ci.yml'

concurrency:
Expand All @@ -24,8 +24,8 @@ jobs:
- uses: actions/setup-dotnet@v2
with:
dotnet-version: 6.0.403
global-json-file: examples/applications/dog-mode-ui/global.json
global-json-file: intent_brokering/examples/applications/dog-mode-ui/global.json

- run: dotnet --info

- run: dotnet build examples/applications/dog-mode-ui
- run: dotnet build intent_brokering/examples/applications/dog-mode-ui
19 changes: 10 additions & 9 deletions .github/workflows/e2e-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ on:
branches:
- main
paths:
- "common/**"
- "ess/**"
- "examples/**"
- "keyvalue/**"
- "proto/**"
- 'proto.rs/**'
- "src/**"
- "tests/**"
- "intent_brokering/common/**"
- "intent_brokering/ess/**"
- "intent_brokering/examples/**"
- "intent_brokering/keyvalue/**"
- "intent_brokering/proto/**"
- 'intent_brokering/proto.rs/**'
- "intent_brokering/src/**"
- "intent_brokering/tests/**"
- ".github/workflows/e2e.yaml"
- 'Cargo.lock'
- 'Cargo.toml'
Expand Down Expand Up @@ -50,14 +50,15 @@ jobs:
uses: docker/build-push-action@v3
with:
context: .
file: ./Dockerfile.intent_brokering
load: true
tags: chariott:1

- name: Build KV-App Container
uses: docker/build-push-action@v3
with:
context: .
file: ./examples/applications/Dockerfile.kv-app.ci
file: ./intent_brokering/examples/applications/Dockerfile.kv-app.ci
build-args: APP_NAME=kv-app
load: true
tags: kv-app:1
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/ess-bench.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ on:
branches:
- main
paths:
- 'common/**'
- 'ess/**'
- 'intent_brokering/common/**'
- 'intent_brokering/ess/**'
- '.github/workflows/ess-bench.yml'

concurrency:
Expand All @@ -25,7 +25,7 @@ env:
AUTO_PUSH: ${{ github.event_name == 'push' }}
# Comment the performance numbers of the load tests only on PRs and if the PR
# comes from within the Eclipse organization.
COMMENT_ALWAYS: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == 'eclipse/chariott' }}
COMMENT_ALWAYS: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == 'eclipse-chariott/chariott' }}

jobs:
benchmark:
Expand All @@ -41,7 +41,7 @@ jobs:
run: sudo apt-get install -y protobuf-compiler

- name: Run benchmark
run: cargo bench --manifest-path ess/Cargo.toml --bench load_bench -- --output-format bencher | tee output.txt
run: cargo bench --manifest-path intent_brokering/ess/Cargo.toml --bench load_bench -- --output-format bencher | tee output.txt

- name: Store benchmark result
env:
Expand Down
19 changes: 10 additions & 9 deletions .github/workflows/lt-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ on:
branches:
- main
paths:
- 'common/**'
- 'src/**'
- 'tests/**'
- 'proto/**'
- 'proto.rs/**'
- 'examples/**'
- 'intent_brokering/common/**'
- 'intent_brokering/src/**'
- 'intent_brokering/tests/**'
- 'intent_brokering/proto/**'
- 'intent_brokering/proto.rs/**'
- 'intent_brokering/examples/**'
- '.github/workflows/lt-ci.yml'
- 'Cargo.lock'
- 'Cargo.toml'
Expand All @@ -32,7 +32,7 @@ env:
AUTO_PUSH: ${{ github.event_name == 'push' }}
# Comment the performance numbers of the load tests only on PRs and if the PR
# comes from within the Eclipse organization.
COMMENT_ALWAYS: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == 'eclipse/chariott' }}
COMMENT_ALWAYS: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == 'eclipse-chariott/chariott' }}

jobs:
benchmark:
Expand All @@ -57,22 +57,23 @@ jobs:
uses: docker/build-push-action@v3
with:
context: .
file: Dockerfile.intent_brokering
load: true
tags: chariott:1

- name: Build valgrind enabled chariott container
uses: docker/build-push-action@v3
with:
context: .
file: ./Dockerfile.valgrind
file: ./Dockerfile.intent_brokering.valgrind
load: true
tags: val-chariott:1

- name: Build lt-provider-app container
uses: docker/build-push-action@v3
with:
context: .
file: ./examples/applications/Dockerfile.lt-provider-app.ci
file: ./intent_brokering/examples/applications/Dockerfile.lt-provider-app.ci
build-args: APP_NAME=lt-provider-app
load: true
tags: lt-provider-app:1
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/rust-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ on:
branches:
- main
paths:
- 'common/**'
- 'src/**'
- 'tests/**'
- 'proto/**'
- 'proto.rs/**'
- 'ess/**'
- 'keyvalue/**'
- 'examples/**'
- 'intent_brokering/common/**'
- 'intent_brokering/src/**'
- 'intent_brokering/tests/**'
- 'intent_brokering/proto/**'
- 'intent_brokering/proto.rs/**'
- 'intent_brokering/ess/**'
- 'intent_brokering/keyvalue/**'
- 'intent_brokering/examples/**'
- '.github/workflows/rust-ci.yml'
- 'Cargo.lock'
- 'Cargo.toml'
Expand Down
2 changes: 0 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

77 changes: 18 additions & 59 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,60 +4,32 @@

[workspace]
members = [
"common",
"ess",
"examples/applications/cloud-object-detection",
"examples/applications/dog-mode-logic",
"examples/applications/kv-app",
"examples/applications/invoke-command",
"examples/applications/local-object-detection",
"examples/applications/lt-consumer",
"examples/applications/lt-provider",
"examples/applications/mock-vas",
"examples/applications/simple-provider",
"examples/applications/simulated-camera",
"examples/common",
"keyvalue",
"proto.rs",
"intent_brokering",
"intent_brokering/common",
"intent_brokering/ess",
"intent_brokering/examples/applications/cloud-object-detection",
"intent_brokering/examples/applications/dog-mode-logic",
"intent_brokering/examples/applications/kv-app",
"intent_brokering/examples/applications/invoke-command",
"intent_brokering/examples/applications/local-object-detection",
"intent_brokering/examples/applications/lt-consumer",
"intent_brokering/examples/applications/lt-provider",
"intent_brokering/examples/applications/mock-vas",
"intent_brokering/examples/applications/simple-provider",
"intent_brokering/examples/applications/simulated-camera",
"intent_brokering/examples/common",
"intent_brokering/keyvalue",
"intent_brokering/proto.rs",
"service_discovery/core",
"service_discovery/samples/simple-discovery/consumer",
"service_discovery/samples/simple-discovery/provider"
]

[package]
name = "chariott"
version = "0.1.0"
edition = "2021"
license = "MIT"

[[test]]
name = "store-e2e"
test = false

[[test]]
name = "registry-e2e"
test = false

[dependencies]
async-recursion = "1.0"
async-trait = { workspace = true }
chariott-common = { workspace = true }
chariott-proto = { workspace = true }
prost = { workspace = true }
prost-types = { workspace = true }
tokio = { workspace = true, features = ["rt-multi-thread", "time"] }
tokio-util = { workspace = true }
tonic = { workspace = true }
tonic-reflection = "0.10"
tracing = { workspace = true }
tracing-subscriber = { workspace = true }
url = { workspace = true }

[workspace.dependencies]
anyhow = "1.0"
async-trait = "0.1"
chariott-common = { path = "./common/" }
chariott-proto = { path = "./proto.rs/" }
chariott-common = { path = "./intent_brokering/common/" }
chariott-proto = { path = "./intent_brokering/proto.rs/" }
futures = { version = "0.3" }
lazy_static = "1.4.0"
parking_lot = "0.12.1"
Expand All @@ -77,19 +49,6 @@ uuid = { version = "1.6.1", features = ["v4"] }
url = "2.5"
test-case = "2.2.2"

[build-dependencies]
tonic-build = { workspace = true }

[dev-dependencies]
anyhow = { workspace = true }
async-trait = { workspace = true }
examples-common = { path = "./examples/common" }
futures = { workspace = true }
tokio-util = { workspace = true }
uuid = { workspace = true }
tokio-stream = { workspace = true }
test-case = { workspace = true }

[profile.release]
strip = true
opt-level = "z"
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile → Dockerfile.intent_brokering
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ COPY ./ .

RUN rustup target add x86_64-unknown-linux-musl

RUN cargo build --release --target=x86_64-unknown-linux-musl
RUN cargo build --release --target=x86_64-unknown-linux-musl -p chariott

####################################################################################################
## Final image
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.arm64 → Dockerfile.intent_brokering.arm64
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ COPY ./ .

RUN rustup target add aarch64-unknown-linux-musl

RUN cargo build --release --target=aarch64-unknown-linux-musl
RUN cargo build --release --target=aarch64-unknown-linux-musl -p chariott

#############################################################x#######################################
## Final image
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ WORKDIR /sdv

COPY ./ .

RUN cargo build --release
RUN cargo build --release -p chariott

#############################################################x#######################################
## Final image
Expand Down
Loading
Loading