Skip to content

Commit

Permalink
Fix fields naming (#15)
Browse files Browse the repository at this point in the history
* correct message field naming 🎉
  • Loading branch information
Tochemey authored Sep 28, 2020
1 parent 5253891 commit 0080d39
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 22 deletions.
8 changes: 4 additions & 4 deletions chief_of_state/v1/common.proto
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ syntax = "proto3";

package chief_of_state.v1;

option java_package = "com.namely.protobuf.chiefofstate.v1";
option csharp_namespace = "Namely.ChiefOfState.V1";
option go_package = "chiefofstatev1";
option java_multiple_files = true;
option java_outer_classname = "CosCommonProto";
option go_package = "chiefofstatev1";
option csharp_namespace = "Namely.ChiefOfState.V1";
option java_package = "com.namely.protobuf.chiefofstate.v1";

import "google/protobuf/timestamp.proto";
import "google/protobuf/any.proto";
import "google/protobuf/timestamp.proto";

message MetaData {
string entity_id = 1;
Expand Down
9 changes: 5 additions & 4 deletions chief_of_state/v1/readside.proto
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,14 @@ syntax = "proto3";

package chief_of_state.v1;

option java_package = "com.namely.protobuf.chiefofstate.v1";
option csharp_namespace = "Namely.ChiefOfState.V1";
option go_package = "chiefofstatev1";
option java_multiple_files = true;
option java_outer_classname = "CosReadSideHandlerProto";
option go_package = "chiefofstatev1";
option csharp_namespace = "Namely.ChiefOfState.V1";
import "google/protobuf/any.proto";
option java_package = "com.namely.protobuf.chiefofstate.v1";

import "chief_of_state/v1/common.proto";
import "google/protobuf/any.proto";

// Defines the readSide handler service interface that will be implemented by
// any application that needs to build a readSide from the events persisted.
Expand Down
9 changes: 5 additions & 4 deletions chief_of_state/v1/service.proto
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,14 @@ syntax = "proto3";

package chief_of_state.v1;

option java_package = "com.namely.protobuf.chiefofstate.v1";
option csharp_namespace = "Namely.ChiefOfState.V1";
option go_package = "chiefofstatev1";
option java_multiple_files = true;
option java_outer_classname = "CosServiceProto";
option go_package = "chiefofstatev1";
option csharp_namespace = "Namely.ChiefOfState.V1";
import "google/protobuf/any.proto";
option java_package = "com.namely.protobuf.chiefofstate.v1";

import "chief_of_state/v1/common.proto";
import "google/protobuf/any.proto";

// Service definition
service ChiefOfStateService {
Expand Down
21 changes: 11 additions & 10 deletions chief_of_state/v1/writeside.proto
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ syntax = "proto3";

package chief_of_state.v1;

option java_package = "com.namely.protobuf.chiefofstate.v1";
option csharp_namespace = "Namely.ChiefOfState.V1";
option go_package = "chiefofstatev1";
option java_multiple_files = true;
option java_outer_classname = "CosWriteSideHandlerProto";
option go_package = "chiefofstatev1";
option csharp_namespace = "Namely.ChiefOfState.V1";
option java_package = "com.namely.protobuf.chiefofstate.v1";

import "google/protobuf/any.proto";
import "chief_of_state/v1/common.proto";
import "google/protobuf/any.proto";

// Defines the interface that will be implemented by any application that
// wants to keeps its events and state with ChiefOfState. So an application will
Expand All @@ -30,9 +30,10 @@ message HandleCommandRequest {
google.protobuf.Any command = 1;
// the aggregate state at the moment of handling the command. This is the
// state before the command being handled.
google.protobuf.Any current_state = 2;
// additional meta data.
chief_of_state.v1.MetaData meta = 3;
google.protobuf.Any prior_state = 2;
// the prior event meta data. This is the event meta data of the last event
// before this command
chief_of_state.v1.MetaData prior_event_meta = 3;
}

// HandleCommandResponse
Expand All @@ -47,9 +48,9 @@ message HandleEventRequest {
// the event to handle
google.protobuf.Any event = 1;
// the state before the event is being handled.
google.protobuf.Any current_state = 2;
// additional meta data
chief_of_state.v1.MetaData meta = 3;
google.protobuf.Any prior_state = 2;
// the meta data of this event
chief_of_state.v1.MetaData event_meta = 3;
}

// HandleEventResponse contains the resulting state
Expand Down

0 comments on commit 0080d39

Please sign in to comment.