Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(152)

Issue 2013343002: Move server-side service stubs to .pbserver.dart (Closed)

Created:
4 years, 6 months ago by skybrian
Modified:
4 years, 6 months ago
Reviewers:
Søren Gjesse
CC:
reviews_dartlang.org
Base URL:
git@github.com:dart-lang/dart-protoc-plugin.git@cleanup
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Move server-side service stubs to .pbserver.dart This should break all dependencies on .pbjson.dart files for client-side code, reducing the number of files loaded into Dartium. However, it is a breaking API change: server-side code needs to be modified to import .pbserver.dart files as well as .pb.dart files. BUG= R=sgjesse@google.com Committed: https://github.com/dart-lang/dart-protoc-plugin/commit/35b7464412cab501bf63b908cf9367e9a8fde306

Patch Set 1 #

Patch Set 2 : bump version #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+183 lines, -94 lines) Patch
M Makefile View 1 chunk +7 lines, -2 lines 0 comments Download
M lib/file_generator.dart View 9 chunks +89 lines, -87 lines 0 comments Download
M pubspec.yaml View 1 1 chunk +1 line, -1 line 0 comments Download
M test/file_generator_test.dart View 3 chunks +85 lines, -4 lines 2 comments Download
M test/service_test.dart View 1 chunk +1 line, -0 lines 2 comments Download

Depends on Patchset:

Messages

Total messages: 6 (2 generated)
skybrian
4 years, 6 months ago (2016-05-27 03:04:54 UTC) #2
Søren Gjesse
lgtm https://codereview.chromium.org/2013343002/diff/20001/test/file_generator_test.dart File test/file_generator_test.dart (right): https://codereview.chromium.org/2013343002/diff/20001/test/file_generator_test.dart#newcode335 test/file_generator_test.dart:335: class TestApi { Have you considered to also ...
4 years, 6 months ago (2016-05-27 07:34:35 UTC) #3
skybrian
Committed patchset #2 (id:20001) manually as 35b7464412cab501bf63b908cf9367e9a8fde306 (presubmit successful).
4 years, 6 months ago (2016-05-27 18:26:21 UTC) #5
skybrian
4 years, 6 months ago (2016-05-27 18:27:50 UTC) #6
Message was sent while issue was closed.
https://codereview.chromium.org/2013343002/diff/20001/test/file_generator_tes...
File test/file_generator_test.dart (right):

https://codereview.chromium.org/2013343002/diff/20001/test/file_generator_tes...
test/file_generator_test.dart:335: class TestApi {
On 2016/05/27 07:34:35, Søren Gjesse wrote:
> Have you considered to also split out the client side API to a .pbclient.dart
> file? For the use-cases where the client side API is not used. The
> .pbclient.dart could re-export some of the other stuff so that only one import
> is required when using the client side API.

I considered it but I'm not sure it would accomplish that much? Normally the
requests and responses are in the same .proto file, so the client-side stub
doesn't require any additional imports.

https://codereview.chromium.org/2013343002/diff/20001/test/service_test.dart
File test/service_test.dart (right):

https://codereview.chromium.org/2013343002/diff/20001/test/service_test.dart#...
test/service_test.dart:9: import '../out/protos/service.pbserver.dart' as pb;
On 2016/05/27 07:34:35, Søren Gjesse wrote:
> If .pbserver.dart re-exported .pd.dart you only need one import.

Done.

Powered by Google App Engine
This is Rietveld 408576698