-
Notifications
You must be signed in to change notification settings - Fork 547
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow both @extension and @grpcExtension extensions in schema validat…
…ion (#1009) * Allow both @extension and @grpcExtension to bridge rest.li with gRpc * Update CHANGELOG.md to 29.58.0 * Add message to CHANGELOG.md
- Loading branch information
1 parent
0d3b91c
commit b49908d
Showing
5 changed files
with
61 additions
and
17 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
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
10 changes: 10 additions & 0 deletions
10
restli-tools/src/test/extensions/validCase/BazExtensions.pdl
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,10 @@ | ||
/** | ||
* Valid extension schema: | ||
* The co-existence of @extension and @grpcExtension is allowed | ||
*/ | ||
record BazExtensions includes Baz { | ||
@extension.using = "finder: test" | ||
@grpcExtension.rpc = "get" | ||
@grpcExtension.versionSuffix = "V2" | ||
testField: array[DummyKeyWithGrpc] | ||
} |
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,42 @@ | ||
/** | ||
* A test schema which is used as a field type in extension schema. | ||
*/ | ||
@resourceKey = [ { | ||
"keyConfig" : { | ||
"keys" : { | ||
"profilesId" : { | ||
"assocKey" : { | ||
"authorId" : "fabricName", | ||
"objectId" : "sessionId" | ||
} | ||
} | ||
} | ||
}, | ||
"entity" : "Profile", | ||
"resourcePath" : "/profiles/{profilesId}" | ||
}, { | ||
"keyConfig" : { | ||
"keys" : { | ||
"profilesId" : { | ||
"assocKey" : { | ||
"authorId" : "fabricName", | ||
"objectId" : "sessionId" | ||
} | ||
} | ||
} | ||
}, | ||
"entity" : "ProfileV2", | ||
"resourcePath" : "/profilesV2/{profilesId}", | ||
"versionSuffix" : "V2" | ||
} ] | ||
@grpcService = [ { | ||
"entity" : "proto.com.linkedin.Profile" | ||
"rpc" : "get", | ||
"service" : "proto.com.linkedin.ProfileService" | ||
}, { | ||
"entity" : "proto.com.linkedin.ProfileV2" | ||
"rpc" : "get", | ||
"service" : "proto.com.linkedin.ProfileServiceV2" | ||
"versionSuffix": "V2" | ||
} ] | ||
typeref DummyKeyWithGrpc = string |