forked from quarkusio/quarkus
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix missing include statements in the proto compilation and also improve the syntax of the proto include/exclude clauses (comma-separated list accepting spaces)
- Loading branch information
1 parent
485d812
commit 686e8af
Showing
6 changed files
with
93 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
integration-tests/grpc-external-proto-test/src/main/proto/extended.proto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
syntax = "proto3"; | ||
|
||
option java_package = "org.acme.protos.extended"; | ||
option java_outer_classname = "ExtendedProtos"; | ||
|
||
option optimize_for = CODE_SIZE; | ||
|
||
package org.acme.proto.extended; | ||
|
||
// Import the base proto file | ||
import "base.proto"; | ||
|
||
// A message representing detailed user information | ||
message DetailedUser { | ||
org.acme.protos.base.User user = 1; // Use the User message from base.proto | ||
org.acme.protos.base.Address address = 2; // Use the Address message from base.proto | ||
string phone_number = 3; | ||
} | ||
|
||
// Another message using the base Address message | ||
message Company { | ||
string name = 1; | ||
org.acme.protos.base.Address company_address = 2; | ||
} | ||
|
4 changes: 2 additions & 2 deletions
4
integration-tests/grpc-external-proto-test/src/main/resources/application.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
integration-tests/grpc-external-proto/src/main/resources/protobuf/base.proto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
syntax = "proto3"; | ||
|
||
option java_package = "org.acme.protos.base"; | ||
option java_outer_classname = "BASEProtos"; | ||
|
||
option optimize_for = CODE_SIZE; | ||
|
||
// Import the extra proto file | ||
import "role.proto"; | ||
|
||
package org.acme.protos.base; | ||
|
||
// A basic message representing user information | ||
message User { | ||
int32 id = 1; | ||
string name = 2; | ||
string email = 3; | ||
org.acme.protos.role.Role role = 4; // Use the Role message from extra.proto | ||
} | ||
|
||
// A basic message representing an address | ||
message Address { | ||
string street = 1; | ||
string city = 2; | ||
string state = 3; | ||
string zip = 4; | ||
} | ||
|
15 changes: 15 additions & 0 deletions
15
integration-tests/grpc-external-proto/src/main/resources/protobuf/role.proto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
syntax = "proto3"; | ||
|
||
option java_package = "org.acme.protos.role"; | ||
option java_outer_classname = "RoleProtos"; | ||
|
||
option optimize_for = CODE_SIZE; | ||
|
||
package org.acme.protos.role; | ||
|
||
// A basic message representing a role | ||
message Role { | ||
int32 role_id = 1; | ||
string role_name = 2; | ||
} | ||
|