Fixes for service.md.

- getInstances needs a param for isolateId. Without this param, we see runtime errors.
- InstanceSet needs instances to have type @Object[]. We see types of objects here other than
  InstanceRefs (ObjRef, FieldRef, etc.), and we need to be able to handle all types. If we do
  not, we see runtime errors.
- getVMTimeline params should be optional. Before this method was made public, you did not
  have to specify origin / extent times to pull the timeline.

Fixes https://github.com/dart-lang/sdk/issues/37349.
Fixes https://github.com/dart-lang/sdk/issues/37351.


Change-Id: Icb9874cfb102268cc561978a74c11cac02bcfc0c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/107190
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Kenzie Schmoll <kenzieschmoll@google.com>
diff --git a/runtime/vm/service/service.md b/runtime/vm/service/service.md
index 56f3bd7..89e580b 100644
--- a/runtime/vm/service/service.md
+++ b/runtime/vm/service/service.md
@@ -643,7 +643,8 @@
 ### getInstances
 
 ```
-InstanceSet getInstances(string objectId,
+InstanceSet getInstances(string isolateId,
+                         string objectId,
                          int limit)
 ```
 
@@ -806,8 +807,8 @@
 ### getVMTimeline
 
 ```
-Timeline getVMTimeline(int timeOriginMicros,
-                       int timeExtentMicros)
+Timeline getVMTimeline(int timeOriginMicros [optional],
+                       int timeExtentMicros [optional])
 ```
 
 The _getVMTimeline_ RPC is used to retrieve an object which contains VM timeline
@@ -2318,7 +2319,7 @@
   int totalCount;
 
   // An array of instances of the requested type.
-  @Instance[] instances;
+  @Object[] instances;
 }
 ```
 
diff --git a/runtime/vm/service/service_dev.md b/runtime/vm/service/service_dev.md
index 4985682..ccf44c1 100644
--- a/runtime/vm/service/service_dev.md
+++ b/runtime/vm/service/service_dev.md
@@ -643,7 +643,8 @@
 ### getInstances
 
 ```
-InstanceSet getInstances(string objectId,
+InstanceSet getInstances(string isolateId,
+                         string objectId,
                          int limit)
 ```
 
@@ -806,8 +807,8 @@
 ### getVMTimeline
 
 ```
-Timeline getVMTimeline(int timeOriginMicros,
-                       int timeExtentMicros)
+Timeline getVMTimeline(int timeOriginMicros [optional],
+                       int timeExtentMicros [optional])
 ```
 
 The _getVMTimeline_ RPC is used to retrieve an object which contains VM timeline
@@ -2318,7 +2319,7 @@
   int totalCount;
 
   // An array of instances of the requested type.
-  @Instance[] instances;
+  @Object[] instances;
 }
 ```