Skip to content

Commit

Permalink
chore: rename numaflow-grpc to numaflow-pb (#2159)
Browse files Browse the repository at this point in the history
Signed-off-by: Derek Wang <[email protected]>
  • Loading branch information
whynowy authored Oct 16, 2024
1 parent 5e87391 commit f81062c
Show file tree
Hide file tree
Showing 31 changed files with 61 additions and 61 deletions.
24 changes: 12 additions & 12 deletions .codecov.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
ignore:
- "**/*.pb.go"
- "**/*.pb.gw.go"
- "**/*generated.go"
- "**/*generated.deepcopy.go"
- "**/*generated.openapi.go"
- "**/*_test.go"
- "pkg/client/.*"
- "vendor/.*"
- "test/.*"
- "rust/**/error.rs"
- "rust/numaflow-models/**" # ignore generated files
- "rust/numaflow-grpc/**" # ignore generated files
- "**/*.pb.go"
- "**/*.pb.gw.go"
- "**/*generated.go"
- "**/*generated.deepcopy.go"
- "**/*generated.openapi.go"
- "**/*_test.go"
- "pkg/client/.*"
- "vendor/.*"
- "test/.*"
- "rust/**/error.rs"
- "rust/numaflow-models/**" # ignore generated files
- "rust/numaflow-pb/**" # ignore generated files
coverage:
status:
patch: off
Expand Down
26 changes: 13 additions & 13 deletions rust/Cargo.lock

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

4 changes: 2 additions & 2 deletions rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ workspace = { members = [
"servesink",
"serving",
"numaflow-core",
"numaflow-grpc",
"numaflow-pb",
] }

[[bin]]
Expand All @@ -23,6 +23,6 @@ backoff = { path = "backoff" }
servesink = { path = "servesink" }
serving = { path = "serving" }
numaflow-core = { path = "numaflow-core" }
numaflow-grpc = { path = "numaflow-grpc" }
numaflow-pb = { path = "numaflow-pb" }
tracing = "0.1.40"
tracing-subscriber = { version = "0.3.18", features = ["env-filter"] }
2 changes: 1 addition & 1 deletion rust/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ SHELL:=/bin/bash
.PHONY: generate
generate:
$(MAKE) --directory numaflow-models generate
$(MAKE) --directory numaflow-grpc generate
$(MAKE) --directory numaflow-pb generate

.PHONY: build
build:
Expand Down
2 changes: 1 addition & 1 deletion rust/numaflow-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ tower = "0.4.13"
uuid = { version = "1.10.0", features = ["v4"] }
serde_json = "1.0.122"
numaflow-models = { path = "../numaflow-models" }
numaflow-grpc = { path = "../numaflow-grpc" }
numaflow-pb = { path = "../numaflow-pb" }
trait-variant = "0.1.2"
rcgen = "0.13.1"
rustls = { version = "0.23.12", features = ["aws_lc_rs"] }
Expand Down
16 changes: 8 additions & 8 deletions rust/numaflow-core/src/message.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ use chrono::{DateTime, Utc};

use crate::shared::utils::{prost_timestamp_from_utc, utc_from_timestamp};
use crate::Error;
use numaflow_grpc::clients::sink::sink_request::Request;
use numaflow_grpc::clients::sink::Status::{Failure, Fallback, Success};
use numaflow_grpc::clients::sink::{sink_response, SinkRequest, SinkResponse};
use numaflow_grpc::clients::source::{read_response, AckRequest};
use numaflow_grpc::clients::sourcetransformer::SourceTransformRequest;
use numaflow_pb::clients::sink::sink_request::Request;
use numaflow_pb::clients::sink::Status::{Failure, Fallback, Success};
use numaflow_pb::clients::sink::{sink_response, SinkRequest, SinkResponse};
use numaflow_pb::clients::source::{read_response, AckRequest};
use numaflow_pb::clients::sourcetransformer::SourceTransformRequest;

/// A message that is sent from the source to the sink.
#[derive(Debug, Clone)]
Expand Down Expand Up @@ -42,8 +42,8 @@ pub(crate) struct Offset {
impl From<Offset> for AckRequest {
fn from(offset: Offset) -> Self {
Self {
request: Some(numaflow_grpc::clients::source::ack_request::Request {
offset: Some(numaflow_grpc::clients::source::Offset {
request: Some(numaflow_pb::clients::source::ack_request::Request {
offset: Some(numaflow_pb::clients::source::Offset {
offset: BASE64_STANDARD
.decode(offset.offset)
.expect("we control the encoding, so this should never fail"),
Expand All @@ -60,7 +60,7 @@ impl From<Message> for SourceTransformRequest {
fn from(message: Message) -> Self {
Self {
request: Some(
numaflow_grpc::clients::sourcetransformer::source_transform_request::Request {
numaflow_pb::clients::sourcetransformer::source_transform_request::Request {
id: message.id,
keys: message.keys,
value: message.value,
Expand Down
6 changes: 3 additions & 3 deletions rust/numaflow-core/src/monovertex.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ use tokio_util::sync::CancellationToken;
use tonic::transport::Channel;
use tracing::info;

use numaflow_grpc::clients::sink::sink_client::SinkClient;
use numaflow_grpc::clients::source::source_client::SourceClient;
use numaflow_grpc::clients::sourcetransformer::source_transform_client::SourceTransformClient;
use numaflow_pb::clients::sink::sink_client::SinkClient;
use numaflow_pb::clients::source::source_client::SourceClient;
use numaflow_pb::clients::sourcetransformer::source_transform_client::SourceTransformClient;

use crate::config::{config, Settings};
use crate::error::{self, Error};
Expand Down
6 changes: 3 additions & 3 deletions rust/numaflow-core/src/monovertex/forwarder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -538,9 +538,9 @@ mod tests {
use chrono::Utc;
use numaflow::source::{Message, Offset, SourceReadRequest};
use numaflow::{sink, source, sourcetransform};
use numaflow_grpc::clients::sink::sink_client::SinkClient;
use numaflow_grpc::clients::source::source_client::SourceClient;
use numaflow_grpc::clients::sourcetransformer::source_transform_client::SourceTransformClient;
use numaflow_pb::clients::sink::sink_client::SinkClient;
use numaflow_pb::clients::source::source_client::SourceClient;
use numaflow_pb::clients::sourcetransformer::source_transform_client::SourceTransformClient;
use tokio::sync::mpsc;
use tokio::sync::mpsc::Sender;
use tokio_util::sync::CancellationToken;
Expand Down
6 changes: 3 additions & 3 deletions rust/numaflow-core/src/monovertex/metrics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ use tonic::transport::Channel;
use tonic::Request;
use tracing::{debug, error, info};

use numaflow_grpc::clients::sink::sink_client::SinkClient;
use numaflow_grpc::clients::source::source_client::SourceClient;
use numaflow_grpc::clients::sourcetransformer::source_transform_client::SourceTransformClient;
use numaflow_pb::clients::sink::sink_client::SinkClient;
use numaflow_pb::clients::source::source_client::SourceClient;
use numaflow_pb::clients::sourcetransformer::source_transform_client::SourceTransformClient;

use crate::config::config;
use crate::source::SourceHandle;
Expand Down
6 changes: 3 additions & 3 deletions rust/numaflow-core/src/shared/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ use crate::monovertex::metrics::{
use crate::shared::server_info;
use crate::source::SourceHandle;
use crate::Error;
use numaflow_grpc::clients::sink::sink_client::SinkClient;
use numaflow_grpc::clients::source::source_client::SourceClient;
use numaflow_grpc::clients::sourcetransformer::source_transform_client::SourceTransformClient;
use numaflow_pb::clients::sink::sink_client::SinkClient;
use numaflow_pb::clients::source::source_client::SourceClient;
use numaflow_pb::clients::sourcetransformer::source_transform_client::SourceTransformClient;

pub(crate) async fn check_compatibility(
cln_token: &CancellationToken,
Expand Down
2 changes: 1 addition & 1 deletion rust/numaflow-core/src/sink.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use tonic::transport::Channel;

use crate::config::config;
use crate::message::{Message, ResponseFromSink};
use numaflow_grpc::clients::sink::sink_client::SinkClient;
use numaflow_pb::clients::sink::sink_client::SinkClient;
use user_defined::UserDefinedSink;

mod log;
Expand Down
6 changes: 3 additions & 3 deletions rust/numaflow-core/src/sink/user_defined.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ use tokio_stream::wrappers::ReceiverStream;
use tonic::transport::Channel;
use tonic::{Request, Streaming};

use numaflow_grpc::clients::sink::sink_client::SinkClient;
use numaflow_grpc::clients::sink::{Handshake, SinkRequest, SinkResponse, TransmissionStatus};
use numaflow_pb::clients::sink::sink_client::SinkClient;
use numaflow_pb::clients::sink::{Handshake, SinkRequest, SinkResponse, TransmissionStatus};

use crate::error;
use crate::message::{Message, ResponseFromSink};
Expand Down Expand Up @@ -122,7 +122,7 @@ mod tests {
use crate::message::{Message, Offset};
use crate::shared::utils::create_rpc_channel;
use crate::sink::user_defined::UserDefinedSink;
use numaflow_grpc::clients::sink::sink_client::SinkClient;
use numaflow_pb::clients::sink::sink_client::SinkClient;

struct Logger;
#[tonic::async_trait]
Expand Down
8 changes: 4 additions & 4 deletions rust/numaflow-core/src/source/user_defined.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ use tokio_stream::wrappers::ReceiverStream;
use tonic::transport::Channel;
use tonic::{Request, Streaming};

use numaflow_grpc::clients::source;
use numaflow_grpc::clients::source::source_client::SourceClient;
use numaflow_grpc::clients::source::{
use numaflow_pb::clients::source;
use numaflow_pb::clients::source::source_client::SourceClient;
use numaflow_pb::clients::source::{
read_request, AckRequest, AckResponse, ReadRequest, ReadResponse,
};

Expand Down Expand Up @@ -237,7 +237,7 @@ mod tests {
use std::collections::HashSet;

use crate::shared::utils::create_rpc_channel;
use numaflow_grpc::clients::source::source_client::SourceClient;
use numaflow_pb::clients::source::source_client::SourceClient;

use chrono::Utc;
use numaflow::source;
Expand Down
4 changes: 2 additions & 2 deletions rust/numaflow-core/src/transformer/user_defined.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use tonic::transport::Channel;
use tonic::{Request, Streaming};
use tracing::warn;

use numaflow_grpc::clients::sourcetransformer::{
use numaflow_pb::clients::sourcetransformer::{
self, source_transform_client::SourceTransformClient, SourceTransformRequest,
SourceTransformResponse,
};
Expand Down Expand Up @@ -230,7 +230,7 @@ mod tests {
use crate::shared::utils::create_rpc_channel;
use crate::transformer::user_defined::SourceTransformHandle;
use numaflow::sourcetransform;
use numaflow_grpc::clients::sourcetransformer::source_transform_client::SourceTransformClient;
use numaflow_pb::clients::sourcetransformer::source_transform_client::SourceTransformClient;
use tempfile::TempDir;

struct NowCat;
Expand Down
4 changes: 2 additions & 2 deletions rust/numaflow-grpc/Cargo.toml → rust/numaflow-pb/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
[[bin]]
name = "numaflow-grpc"
name = "numaflow-pb"
path = "src/main.rs"

[package]
name = "numaflow-grpc"
name = "numaflow-pb"
version = "0.1.0"
edition = "2021"

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit f81062c

Please sign in to comment.