This patch makes mojo:debugger automatically connect to window_manager
only when run by skydb, so that running the debugger for tracing and
profiling doesn't bring the side-effect of spawning window_manager.
Note that we might in the future change this to make the connection to
window_manager lazy when load() or reload() is requested, but this would
require a more involved change to skydb. The way taken in this patch
doesn't change the skydb codepath while enabling usage of debugger for
interactive tracing / profiling.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/1157253007
Sky debugger is a native mojo app that puts up an http server and talks
to other mojo apps in response to http requests, allowing to
interactively start/stop tracing, profile, etc.
This is generally useful also when one does not run mojo_shell through
skydb, hence this patch pulls the debugger into services/debugger.
We can then add plumbing for running with the debugger in devtools.
Bug: domokit/devtools/#4.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/1151573010
Right now I'm storing a SHA1 in a folder in /sdcard since
that seems likely to work on non-rooted devices, but
I haven't tested it.
This cuts build times from 6.5 seconds to 1.5 seconds for
me. You can save another 0.5sec by passing the --no_install
flag to avoid the SHA1 check altogether if you're sure
that nothing has changed.
R=eseidel@chromium.org, eseidel, hixie
Review URL: https://codereview.chromium.org/1149113005
NOTE: This CL appears far larger than it actually is for two reasons:
1) Many files were moved around to use the Dart package directory structure.
2) Many .dart files had to have import paths updated.
- Organize mojo/public/dart so that it uses standard Dart package layout
- Organize mojo/dart/apptest so that it uses a standard Dart package layout
- Organize sky/sdk so that it uses a standard Dart package layout
- Create a mojo/testing package (used by unittests)
- Introduce the 'dart_pkg' gn rule which populates gen/Config/dart-pkg
- All internally vended Dart packages must have a corresponding dart_pkg rule
- It is now possible to use dependency_overrides: in pubspec.yaml to mix internal and external package dependencies (enables analyzer, editor, webstorm usage for internal developers).
- Package root for dart content handler ends with "packages/"
- Imports of mojo package uris no longer need the "public/dart"
- mojo/public/tools/dart_package.py is a clone of mojo/public/tools/gn/zip.py
- Sky tests no longer run 'deploy_sdk' script.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1132063007
Creates generate.dart script that installs generated .mojom.dart files into
the mojom pub package.
Updates Sky's deploy_sdk.py script to put mojom.dart files in locations where
they can be consumed by the generate.dart script once the SDK is published and
obtained via "pub get".
This CL is adapted from a patch by zra@google.com; most of the work here is his.
R=iposva@google.com
Review URL: https://codereview.chromium.org/1106383006
- Bump Dart and Observatory DEPS to 45576 and 45565 respectively.
- Include 'dart:io' in snapshot
- Add 'dart:io' native bindings to sky bindings.
- Initialize 'dart:io' in sky dart_controller.
- Include Observatory and service isolate resources in build.
- Bring up service isolate.
- Start handle watcher isolate from service isolate (hides handle watcher isolate from debugger and Observatory).
- Hook up debugger.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1107803002
At present there is a special case in Dart bindings generation which
makes the Mojo SDK and things under mojo/services portable. However,
we must not require things under mojo/services to be next to the
Mojo SDK under mojo/public/... in client repos. Further, other
collections of mojoms should also be portable.
To fix this, instead of using the path in the host repo as the
canonical package: import URI for the generated Dart code, this CL
uses the mojom module name.
BUG=https://github.com/domokit/mojo/issues/73R=blundell@chromium.org, johnmccutchan@google.com, tonyg@chromium.org
Review URL: https://codereview.chromium.org/1071693003
Having the output of the tracing service be a list of json objects
instead of one json object makes it much easier to combine multiple
sources. This teaches skydb (which wants to format the output into a
json file loadable by trace-viewer) to emit the tracing header/footer
itself. This will make it possible to combine data from the tracing
service with data collected by the shell itself.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1065093003
This flag to mojo_shell is gaining the ability to produce tracing info
starting very early in process startup. This allows the skydb 'start'
command to pass this command through to mojo_shell.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1065723003
Until now, we were saving downloaded file to the temporary directory
with a name being the hash of the file content. It means there is a race
when the same content is downloaded from 2 different URLs.
To fix this, we now create an intermediary directory that is the hash of
the URL.
Also, because this is only needed for debugging with gdb, and this is
inefficient in term of both CPU and storage (we do not know when to
delete the temporary directory), we control this with a command line
flag.
R=ncbray@chromium.org, eseidel@chromium.org
BUG=https://github.com/domokit/mojo/issues/61
Review URL: https://codereview.chromium.org/1011333003
Before this change Sky would hit 404s when trying to
load examples from domokit.github.io.
I also added a separate sky_home and updated the default
url to point to sky_home instead of home.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/1016143002
Dart actually expects package: to work. This CL makes package:foo
map to /packages/foo, similar to how Dartium or bin/dart would expect.
This also means overlaying the /gen directory over the actual package
outputs (as consumers of an SDK would expect) as well as adding
an additional /lib indirection for the actual package source as
the Dart pub tool will expect.
This is far from perfect, but it unlocks us actually producing a
sky SDK.
I expect there may be some fallout from this change as I'm sure I
missed some package: uses. We also don't have a general solution
for all /foo/bar/baz includes which randomly included parts
of mojo's source directory. Those will need to be updated to use
a package: and deploy_sdk.py taught how to build a package for them.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/990493002