diff options
Diffstat (limited to 'apex/statsd/aidl/android')
-rw-r--r-- | apex/statsd/aidl/android/os/IPendingIntentRef.aidl | 46 | ||||
-rw-r--r-- | apex/statsd/aidl/android/os/IPullAtomCallback.aidl | 31 | ||||
-rw-r--r-- | apex/statsd/aidl/android/os/IPullAtomResultReceiver.aidl | 32 | ||||
-rw-r--r-- | apex/statsd/aidl/android/os/IStatsCompanionService.aidl | 57 | ||||
-rw-r--r-- | apex/statsd/aidl/android/os/IStatsManagerService.aidl | 136 | ||||
-rw-r--r-- | apex/statsd/aidl/android/os/IStatsd.aidl | 230 | ||||
-rw-r--r-- | apex/statsd/aidl/android/os/StatsDimensionsValueParcel.aidl | 21 | ||||
-rw-r--r-- | apex/statsd/aidl/android/util/StatsEventParcel.aidl | 8 |
8 files changed, 0 insertions, 561 deletions
diff --git a/apex/statsd/aidl/android/os/IPendingIntentRef.aidl b/apex/statsd/aidl/android/os/IPendingIntentRef.aidl deleted file mode 100644 index 000a69992a49..000000000000 --- a/apex/statsd/aidl/android/os/IPendingIntentRef.aidl +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright (C) 2019 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package android.os; - -import android.os.StatsDimensionsValueParcel; - -/** - * Binder interface to hold a PendingIntent for StatsCompanionService. - * {@hide} - */ -interface IPendingIntentRef { - - /** - * Sends a broadcast to the specified PendingIntent that it should getData now. - * This should be only called from StatsCompanionService. - */ - oneway void sendDataBroadcast(long lastReportTimeNs); - - /** - * Send a broadcast to the specified PendingIntent notifying it that the list of active configs - * has changed. This should be only called from StatsCompanionService. - */ - oneway void sendActiveConfigsChangedBroadcast(in long[] configIds); - - /** - * Send a broadcast to the specified PendingIntent, along with the other information - * specified. This should only be called from StatsCompanionService. - */ - oneway void sendSubscriberBroadcast(long configUid, long configId, long subscriptionId, - long subscriptionRuleId, in String[] cookies, - in StatsDimensionsValueParcel dimensionsValueParcel); -} diff --git a/apex/statsd/aidl/android/os/IPullAtomCallback.aidl b/apex/statsd/aidl/android/os/IPullAtomCallback.aidl deleted file mode 100644 index ff0b97bb5b84..000000000000 --- a/apex/statsd/aidl/android/os/IPullAtomCallback.aidl +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (C) 2019 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package android.os; - -import android.os.IPullAtomResultReceiver; - -/** - * Binder interface to pull atoms for the stats service. - * {@hide} - */ -interface IPullAtomCallback { - /** - * Initiate a request for a pull for an atom. - */ - oneway void onPullAtom(int atomTag, IPullAtomResultReceiver resultReceiver); - -} diff --git a/apex/statsd/aidl/android/os/IPullAtomResultReceiver.aidl b/apex/statsd/aidl/android/os/IPullAtomResultReceiver.aidl deleted file mode 100644 index 00d026e25df3..000000000000 --- a/apex/statsd/aidl/android/os/IPullAtomResultReceiver.aidl +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (C) 2019 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package android.os; - -import android.util.StatsEventParcel; - -/** - * Binder interface to pull atoms for the stats service. - * {@hide} - */ -interface IPullAtomResultReceiver { - - /** - * Indicate that a pull request for an atom is complete. - */ - oneway void pullFinished(int atomTag, boolean success, in StatsEventParcel[] output); - -} diff --git a/apex/statsd/aidl/android/os/IStatsCompanionService.aidl b/apex/statsd/aidl/android/os/IStatsCompanionService.aidl deleted file mode 100644 index d56a4bd0a8e5..000000000000 --- a/apex/statsd/aidl/android/os/IStatsCompanionService.aidl +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright (C) 2017 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package android.os; - -/** - * Binder interface to communicate with the Java-based statistics service helper. - * {@hide} - */ -interface IStatsCompanionService { - /** - * Tell statscompanion that stastd is up and running. - */ - oneway void statsdReady(); - - /** - * Register a repeating alarm for pulling to fire at the given timestamp and every - * intervalMs thereafter (in ms since epoch). - * If polling alarm had already been registered, it will be replaced by new one. - * Uses AlarmManager.setRepeating API, so if the timestamp is in past, alarm fires immediately, - * and alarm is inexact. - */ - oneway void setPullingAlarm(long nextPullTimeMs); - - /** Cancel any repeating pulling alarm. */ - oneway void cancelPullingAlarm(); - - /** - * Register an alarm when we want to trigger subscribers at the given - * timestamp (in ms since epoch). - * If an alarm had already been registered, it will be replaced by new one. - */ - oneway void setAlarmForSubscriberTriggering(long timestampMs); - - /** Cancel any alarm for the purpose of subscriber triggering. */ - oneway void cancelAlarmForSubscriberTriggering(); - - /** - * Ask StatsCompanionService if the given permission is allowed for a particular process - * and user ID. statsd is incapable of doing this check itself because checkCallingPermission - * is not currently supported by libbinder_ndk. - */ - boolean checkPermission(String permission, int pid, int uid); -} diff --git a/apex/statsd/aidl/android/os/IStatsManagerService.aidl b/apex/statsd/aidl/android/os/IStatsManagerService.aidl deleted file mode 100644 index b59a97e25bd0..000000000000 --- a/apex/statsd/aidl/android/os/IStatsManagerService.aidl +++ /dev/null @@ -1,136 +0,0 @@ -/** - * Copyright (c) 2019, The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package android.os; - -import android.app.PendingIntent; -import android.os.IPullAtomCallback; - -/** - * Binder interface to communicate with the Java-based statistics service helper. - * Contains parcelable objects available only in Java. - * {@hide} - */ -interface IStatsManagerService { - - /** - * Registers the given pending intent for this config key. This intent is invoked when the - * memory consumed by the metrics for this configuration approach the pre-defined limits. There - * can be at most one listener per config key. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - void setDataFetchOperation(long configId, in PendingIntent pendingIntent, - in String packageName); - - /** - * Removes the data fetch operation for the specified configuration. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - void removeDataFetchOperation(long configId, in String packageName); - - /** - * Registers the given pending intent for this packagename. This intent is invoked when the - * active status of any of the configs sent by this package changes and will contain a list of - * config ids that are currently active. It also returns the list of configs that are currently - * active. There can be at most one active configs changed listener per package. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - long[] setActiveConfigsChangedOperation(in PendingIntent pendingIntent, in String packageName); - - /** - * Removes the active configs changed operation for the specified package name. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - void removeActiveConfigsChangedOperation(in String packageName); - - /** - * Set the PendingIntent to be used when broadcasting subscriber - * information to the given subscriberId within the given config. - * - * Suppose that the calling uid has added a config with key configKey, and that in this config - * it is specified that when a particular anomaly is detected, a broadcast should be sent to - * a BroadcastSubscriber with id subscriberId. This function links the given pendingIntent with - * that subscriberId (for that config), so that this pendingIntent is used to send the broadcast - * when the anomaly is detected. - * - * This function can only be called by the owner (uid) of the config. It must be called each - * time statsd starts. Later calls overwrite previous calls; only one PendingIntent is stored. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - void setBroadcastSubscriber(long configKey, long subscriberId, in PendingIntent pendingIntent, - in String packageName); - - /** - * Undoes setBroadcastSubscriber() for the (configKey, subscriberId) pair. - * Any broadcasts associated with subscriberId will henceforth not be sent. - * No-op if this (configKey, subscriberId) pair was not associated with an PendingIntent. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - void unsetBroadcastSubscriber(long configKey, long subscriberId, in String packageName); - - /** - * Returns the most recently registered experiment IDs. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - long[] getRegisteredExperimentIds(); - - /** - * Fetches metadata across statsd. Returns byte array representing wire-encoded proto. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - byte[] getMetadata(in String packageName); - - /** - * Fetches data for the specified configuration key. Returns a byte array representing proto - * wire-encoded of ConfigMetricsReportList. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - byte[] getData(in long key, in String packageName); - - /** - * Sets a configuration with the specified config id and subscribes to updates for this - * configuration id. Broadcasts will be sent if this configuration needs to be collected. - * The configuration must be a wire-encoded StatsdConfig. The receiver for this data is - * registered in a separate function. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - void addConfiguration(in long configId, in byte[] config, in String packageName); - - /** - * Removes the configuration with the matching config id. No-op if this config id does not - * exist. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - void removeConfiguration(in long configId, in String packageName); - - /** Tell StatsManagerService to register a puller for the given atom tag with statsd. */ - oneway void registerPullAtomCallback(int atomTag, long coolDownMillis, long timeoutMillis, - in int[] additiveFields, IPullAtomCallback pullerCallback); - - /** Tell StatsManagerService to unregister the pulller for the given atom tag from statsd. */ - oneway void unregisterPullAtomCallback(int atomTag); -} diff --git a/apex/statsd/aidl/android/os/IStatsd.aidl b/apex/statsd/aidl/android/os/IStatsd.aidl deleted file mode 100644 index 066412a9f157..000000000000 --- a/apex/statsd/aidl/android/os/IStatsd.aidl +++ /dev/null @@ -1,230 +0,0 @@ -/** - * Copyright (c) 2017, The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package android.os; - -import android.os.IPendingIntentRef; -import android.os.IPullAtomCallback; -import android.os.ParcelFileDescriptor; - -/** - * Binder interface to communicate with the statistics management service. - * {@hide} - */ -interface IStatsd { - /** - * Tell the stats daemon that the android system server is up and running. - */ - oneway void systemRunning(); - - /** - * Tell the stats daemon that the android system has finished booting. - */ - oneway void bootCompleted(); - - /** - * Tell the stats daemon that the StatsCompanionService is up and running. - * Two-way binder call so that caller knows message received. - */ - void statsCompanionReady(); - - /** - * Tells statsd that it is time to poll some stats. Statsd will be responsible for determing - * what stats to poll and initiating the polling. - * Two-way binder call so that caller's method (and corresponding wakelocks) will linger. - */ - void informPollAlarmFired(); - - /** - * Tells statsd that it is time to handle periodic alarms. Statsd will be responsible for - * determing what alarm subscriber to trigger. - * Two-way binder call so that caller's method (and corresponding wakelocks) will linger. - */ - void informAlarmForSubscriberTriggeringFired(); - - /** - * Tells statsd that the device is about to shutdown. - */ - void informDeviceShutdown(); - - /** - * Inform statsd about a file descriptor for a pipe through which we will pipe version - * and package information for each uid. - * Versions and package information are supplied via UidData proto where info for each app - * is captured in its own element of a repeated ApplicationInfo message. - */ - oneway void informAllUidData(in ParcelFileDescriptor fd); - - /** - * Inform statsd what the uid, version, version_string, and installer are for one app that was - * updated. - */ - oneway void informOnePackage(in String app, in int uid, in long version, - in String version_string, in String installer); - - /** - * Inform stats that an app was removed. - */ - oneway void informOnePackageRemoved(in String app, in int uid); - - /** - * Fetches data for the specified configuration key. Returns a byte array representing proto - * wire-encoded of ConfigMetricsReportList. - * - * Requires Manifest.permission.DUMP. - */ - byte[] getData(in long key, int callingUid); - - /** - * Fetches metadata across statsd. Returns byte array representing wire-encoded proto. - * - * Requires Manifest.permission.DUMP. - */ - byte[] getMetadata(); - - /** - * Sets a configuration with the specified config id and subscribes to updates for this - * configuration key. Broadcasts will be sent if this configuration needs to be collected. - * The configuration must be a wire-encoded StatsdConfig. The receiver for this data is - * registered in a separate function. - * - * Requires Manifest.permission.DUMP. - */ - void addConfiguration(in long configId, in byte[] config, in int callingUid); - - /** - * Registers the given pending intent for this config key. This intent is invoked when the - * memory consumed by the metrics for this configuration approach the pre-defined limits. There - * can be at most one listener per config key. - * - * Requires Manifest.permission.DUMP. - */ - void setDataFetchOperation(long configId, in IPendingIntentRef pendingIntentRef, - int callingUid); - - /** - * Removes the data fetch operation for the specified configuration. - * - * Requires Manifest.permission.DUMP. - */ - void removeDataFetchOperation(long configId, int callingUid); - - /** - * Registers the given pending intent for this packagename. This intent is invoked when the - * active status of any of the configs sent by this package changes and will contain a list of - * config ids that are currently active. It also returns the list of configs that are currently - * active. There can be at most one active configs changed listener per package. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - long[] setActiveConfigsChangedOperation(in IPendingIntentRef pendingIntentRef, int callingUid); - - /** - * Removes the active configs changed operation for the specified package name. - * - * Requires Manifest.permission.DUMP and Manifest.permission.PACKAGE_USAGE_STATS. - */ - void removeActiveConfigsChangedOperation(int callingUid); - - /** - * Removes the configuration with the matching config id. No-op if this config id does not - * exist. - * - * Requires Manifest.permission.DUMP. - */ - void removeConfiguration(in long configId, in int callingUid); - - /** - * Set the PendingIntentRef to be used when broadcasting subscriber - * information to the given subscriberId within the given config. - * - * Suppose that the calling uid has added a config with key configId, and that in this config - * it is specified that when a particular anomaly is detected, a broadcast should be sent to - * a BroadcastSubscriber with id subscriberId. This function links the given pendingIntent with - * that subscriberId (for that config), so that this pendingIntent is used to send the broadcast - * when the anomaly is detected. - * - * This function can only be called by the owner (uid) of the config. It must be called each - * time statsd starts. Later calls overwrite previous calls; only one pendingIntent is stored. - * - * Requires Manifest.permission.DUMP. - */ - void setBroadcastSubscriber(long configId, long subscriberId, in IPendingIntentRef pir, - int callingUid); - - /** - * Undoes setBroadcastSubscriber() for the (configId, subscriberId) pair. - * Any broadcasts associated with subscriberId will henceforth not be sent. - * No-op if this (configKey, subscriberId) pair was not associated with an PendingIntentRef. - * - * Requires Manifest.permission.DUMP. - */ - void unsetBroadcastSubscriber(long configId, long subscriberId, int callingUid); - - /** - * Tell the stats daemon that all the pullers registered during boot have been sent. - */ - oneway void allPullersFromBootRegistered(); - - /** - * Registers a puller callback function that, when invoked, pulls the data - * for the specified atom tag. - */ - oneway void registerPullAtomCallback(int uid, int atomTag, long coolDownMillis, - long timeoutMillis,in int[] additiveFields, - IPullAtomCallback pullerCallback); - - /** - * Registers a puller callback function that, when invoked, pulls the data - * for the specified atom tag. - * - * Enforces the REGISTER_STATS_PULL_ATOM permission. - */ - oneway void registerNativePullAtomCallback(int atomTag, long coolDownMillis, long timeoutMillis, - in int[] additiveFields, IPullAtomCallback pullerCallback); - - /** - * Unregisters any pullAtomCallback for the given uid/atom. - */ - oneway void unregisterPullAtomCallback(int uid, int atomTag); - - /** - * Unregisters any pullAtomCallback for the given atom + caller. - * - * Enforces the REGISTER_STATS_PULL_ATOM permission. - */ - oneway void unregisterNativePullAtomCallback(int atomTag); - - /** - * The install requires staging. - */ - const int FLAG_REQUIRE_STAGING = 0x01; - - /** - * Rollback is enabled with this install. - */ - const int FLAG_ROLLBACK_ENABLED = 0x02; - - /** - * Requires low latency monitoring. - */ - const int FLAG_REQUIRE_LOW_LATENCY_MONITOR = 0x04; - - /** - * Returns the most recently registered experiment IDs. - */ - long[] getRegisteredExperimentIds(); -} diff --git a/apex/statsd/aidl/android/os/StatsDimensionsValueParcel.aidl b/apex/statsd/aidl/android/os/StatsDimensionsValueParcel.aidl deleted file mode 100644 index 05f78d00348e..000000000000 --- a/apex/statsd/aidl/android/os/StatsDimensionsValueParcel.aidl +++ /dev/null @@ -1,21 +0,0 @@ -package android.os; - -/** - * @hide - */ -parcelable StatsDimensionsValueParcel { - // Field equals atomTag for top level StatsDimensionsValueParcels or - // positions in depth (1-indexed) for lower level parcels. - int field; - - // Indicator for which type of value is stored. Should be set to one - // of the constants in StatsDimensionsValue.java. - int valueType; - - String stringValue; - int intValue; - long longValue; - boolean boolValue; - float floatValue; - StatsDimensionsValueParcel[] tupleValue; -} diff --git a/apex/statsd/aidl/android/util/StatsEventParcel.aidl b/apex/statsd/aidl/android/util/StatsEventParcel.aidl deleted file mode 100644 index add8bfb47b1a..000000000000 --- a/apex/statsd/aidl/android/util/StatsEventParcel.aidl +++ /dev/null @@ -1,8 +0,0 @@ -package android.util; - -/** - * @hide - */ -parcelable StatsEventParcel { - byte[] buffer; -} |