Loading proto/src/persist_atoms.proto +4 −0 Original line number Diff line number Diff line Loading @@ -723,6 +723,9 @@ message SatelliteController { optional int32 count_of_satellite_allowed_state_changed_events = 31; optional int32 count_of_successful_location_queries = 32; optional int32 count_of_failed_location_queries = 33; optional int32 count_of_p2p_sms_available_notification_shown = 34; optional int32 count_of_p2p_sms_available_notification_removed = 35; optional bool is_ntn_only_carrier = 36; } message SatelliteSession { Loading @@ -743,6 +746,7 @@ message SatelliteSession { optional int32 count_of_satellite_notification_displayed = 15; optional int32 count_of_auto_exit_due_to_screen_off = 16; optional int32 count_of_auto_exit_due_to_tn_network = 17; optional bool is_emergency = 18; } message SatelliteIncomingDatagram { Loading src/java/com/android/internal/telephony/metrics/MetricsCollector.java +6 −2 Original line number Diff line number Diff line Loading @@ -1480,7 +1480,10 @@ public class MetricsCollector implements StatsManager.StatsPullAtomCallback { satelliteController.carrierId, satelliteController.countOfSatelliteAllowedStateChangedEvents, satelliteController.countOfSuccessfulLocationQueries, satelliteController.countOfFailedLocationQueries); satelliteController.countOfFailedLocationQueries, satelliteController.countOfP2PSmsAvailableNotificationShown, satelliteController.countOfP2PSmsAvailableNotificationRemoved, satelliteController.isNtnOnlyCarrier); } private static StatsEvent buildStatsEvent(SatelliteSession satelliteSession) { Loading @@ -1502,7 +1505,8 @@ public class MetricsCollector implements StatsManager.StatsPullAtomCallback { satelliteSession.carrierId, satelliteSession.countOfSatelliteNotificationDisplayed, satelliteSession.countOfAutoExitDueToScreenOff, satelliteSession.countOfAutoExitDueToTnNetwork); satelliteSession.countOfAutoExitDueToTnNetwork, satelliteSession.isEmergency); } private static StatsEvent buildStatsEvent(SatelliteIncomingDatagram stats) { Loading src/java/com/android/internal/telephony/metrics/PersistAtomsStorage.java +20 −9 Original line number Diff line number Diff line Loading @@ -766,14 +766,17 @@ public class PersistAtomsStorage { existingStats.countOfDisallowedSatelliteAccess += stats.countOfDisallowedSatelliteAccess; existingStats.countOfSatelliteAccessCheckFail += stats.countOfSatelliteAccessCheckFail; existingStats.isProvisioned = stats.isProvisioned; // Does not update isProvisioned and carrierId due to they are dimension fields. existingStats.countOfSatelliteAllowedStateChangedEvents += stats.countOfSatelliteAllowedStateChangedEvents; existingStats.countOfSuccessfulLocationQueries += stats.countOfSuccessfulLocationQueries; existingStats.countOfFailedLocationQueries += stats.countOfFailedLocationQueries; existingStats.countOfP2PSmsAvailableNotificationShown += stats.countOfP2PSmsAvailableNotificationShown; existingStats.countOfP2PSmsAvailableNotificationRemoved += stats.countOfP2PSmsAvailableNotificationRemoved; // Does not update isNtnOnlyCarrier due to it is a dimension field. } else { mAtoms.satelliteController = insertAtRandomPlace(mAtoms.satelliteController, stats, mMaxNumSatelliteStats); Loading Loading @@ -861,7 +864,6 @@ public class PersistAtomsStorage { CarrierRoamingSatelliteControllerStats stats) { CarrierRoamingSatelliteControllerStats existingStats = find(stats); if (existingStats != null) { existingStats.configDataSource = stats.configDataSource; existingStats.countOfEntitlementStatusQueryRequest += stats.countOfEntitlementStatusQueryRequest; existingStats.countOfSatelliteConfigUpdateRequest += Loading @@ -871,6 +873,8 @@ public class PersistAtomsStorage { existingStats.satelliteSessionGapMinSec = stats.satelliteSessionGapMinSec; existingStats.satelliteSessionGapAvgSec = stats.satelliteSessionGapAvgSec; existingStats.satelliteSessionGapMaxSec = stats.satelliteSessionGapMaxSec; // Does not update configDataSource, carrierId, isDeviceEntitled, due to they are // dimension fields. existingStats.isDeviceEntitled = stats.isDeviceEntitled; } else { mAtoms.carrierRoamingSatelliteControllerStats = insertAtRandomPlace( Loading Loading @@ -2342,7 +2346,8 @@ public class PersistAtomsStorage { && stats.countOfSatelliteNotificationDisplayed == key.countOfSatelliteNotificationDisplayed && stats.countOfAutoExitDueToScreenOff == key.countOfAutoExitDueToScreenOff && stats.countOfAutoExitDueToTnNetwork == key.countOfAutoExitDueToTnNetwork) { && stats.countOfAutoExitDueToTnNetwork == key.countOfAutoExitDueToTnNetwork && stats.isEmergency == key.isEmergency) { return stats; } } Loading @@ -2362,6 +2367,8 @@ public class PersistAtomsStorage { && stats.cellularServiceState == key.cellularServiceState && stats.isMultiSim == key.isMultiSim && stats.recommendingHandoverType == key.recommendingHandoverType && stats.isSatelliteAllowedInCurrentLocation == key.isSatelliteAllowedInCurrentLocation && stats.isWifiConnected == key.isWifiConnected && stats.carrierId == key.carrierId) { return stats; Loading @@ -2388,12 +2395,14 @@ public class PersistAtomsStorage { } /** * Returns SatelliteController atom that has same carrier_id value or * {@code null} if does not exist. * Returns the SatelliteController atom with the matching `carrier_id`, `is_provisioned`, and * `is_ntn_only_carrier` values, or {@code null} if does not exist. */ private @Nullable SatelliteController find(SatelliteController key) { for (SatelliteController stats : mAtoms.satelliteController) { if (stats.carrierId == key.carrierId) { if (stats.carrierId == key.carrierId && stats.isProvisioned == key.isProvisioned && stats.isNtnOnlyCarrier == key.isNtnOnlyCarrier) { return stats; } } Loading @@ -2408,7 +2417,9 @@ public class PersistAtomsStorage { CarrierRoamingSatelliteControllerStats key) { for (CarrierRoamingSatelliteControllerStats stats : mAtoms.carrierRoamingSatelliteControllerStats) { if (stats.carrierId == key.carrierId) { if (stats.carrierId == key.carrierId && stats.configDataSource == key.configDataSource && stats.isDeviceEntitled == key.isDeviceEntitled) { return stats; } } Loading src/java/com/android/internal/telephony/metrics/SatelliteStats.java +85 −2 Original line number Diff line number Diff line Loading @@ -100,6 +100,9 @@ public class SatelliteStats { private final int mCountOfSatelliteAllowedStateChangedEvents; private final int mCountOfSuccessfulLocationQueries; private final int mCountOfFailedLocationQueries; private final int mCountOfP2PSmsAvailableNotificationShown; private final int mCountOfP2PSmsAvailableNotificationRemoved; private static boolean sIsNtnOnlyCarrier; private SatelliteControllerParams(Builder builder) { this.mCountOfSatelliteServiceEnablementsSuccess = Loading Loading @@ -162,6 +165,15 @@ public class SatelliteStats { builder.mCountOfSuccessfulLocationQueries; this.mCountOfFailedLocationQueries = builder.mCountOfFailedLocationQueries; this.mCountOfP2PSmsAvailableNotificationShown = builder.mCountOfP2PSmsAvailableNotificationShown; this.mCountOfP2PSmsAvailableNotificationRemoved = builder.mCountOfP2PSmsAvailableNotificationRemoved; // Carrier ID value should be updated only when it is meaningful. if (builder.mIsNtnOnlyCarrier.isPresent()) { this.sIsNtnOnlyCarrier = builder.mIsNtnOnlyCarrier.get(); } } public int getCountOfSatelliteServiceEnablementsSuccess() { Loading Loading @@ -276,11 +288,11 @@ public class SatelliteStats { return mCountOfSatelliteAccessCheckFail; } public boolean isProvisioned() { public static boolean isProvisioned() { return sIsProvisioned; } public int getCarrierId() { public static int getCarrierId() { return sCarrierId; } Loading @@ -296,6 +308,18 @@ public class SatelliteStats { return mCountOfFailedLocationQueries; } public int getCountOfP2PSmsAvailableNotificationShown() { return mCountOfP2PSmsAvailableNotificationShown; } public int getCountOfP2PSmsAvailableNotificationRemoved() { return mCountOfP2PSmsAvailableNotificationRemoved; } public static boolean isNtnOnlyCarrier() { return sIsNtnOnlyCarrier; } /** * A builder class to create {@link SatelliteControllerParams} data structure class */ Loading Loading @@ -333,6 +357,9 @@ public class SatelliteStats { private int mCountOfSatelliteAllowedStateChangedEvents = 0; private int mCountOfSuccessfulLocationQueries = 0; private int mCountOfFailedLocationQueries = 0; private int mCountOfP2PSmsAvailableNotificationShown = 0; private int mCountOfP2PSmsAvailableNotificationRemoved = 0; private Optional<Boolean> mIsNtnOnlyCarrier = Optional.empty(); /** * Sets countOfSatelliteServiceEnablementsSuccess value of {@link SatelliteController} Loading Loading @@ -660,6 +687,37 @@ public class SatelliteStats { return this; } /** * Sets countOfP2PSmsAvailableNotificationShown value of {@link SatelliteController} * atom then returns Builder class */ public Builder setCountOfP2PSmsAvailableNotificationShown( int countOfP2PSmsAvailableNotificationShown) { this.mCountOfP2PSmsAvailableNotificationShown = countOfP2PSmsAvailableNotificationShown; return this; } /** * Sets countOfP2PSmsAvailableNotificationRemoved value of {@link SatelliteController} * atom then returns Builder class */ public Builder setCountOfP2PSmsAvailableNotificationRemoved( int countOfP2PSmsAvailableNotificationRemoved) { this.mCountOfP2PSmsAvailableNotificationRemoved = countOfP2PSmsAvailableNotificationRemoved; return this; } /** * Sets isNtnOnlyCarrier value of {@link SatelliteController} atom * then returns Builder class */ public Builder setIsNtnOnlyCarrier(boolean isNtnOnlyCarrier) { this.mIsNtnOnlyCarrier = Optional.of(isNtnOnlyCarrier); return this; } /** * Returns ControllerParams, which contains whole component of * {@link SatelliteController} atom Loading Loading @@ -715,6 +773,11 @@ public class SatelliteStats { + mCountOfSatelliteAllowedStateChangedEvents + ", countOfSuccessfulLocationQueries=" + mCountOfSuccessfulLocationQueries + ", countOfFailedLocationQueries=" + mCountOfFailedLocationQueries + ", countOfP2PSmsAvailableNotificationShown=" + mCountOfP2PSmsAvailableNotificationShown + ", countOfP2PSmsAvailableNotificationRemoved=" + mCountOfP2PSmsAvailableNotificationRemoved + ", isNtnOnlyCarrier=" + sIsNtnOnlyCarrier + ")"; } } Loading @@ -740,6 +803,7 @@ public class SatelliteStats { private final int mCountOfSatelliteNotificationDisplayed; private final int mCountOfAutoExitDueToScreenOff; private final int mCountOfAutoExitDueToTnNetwork; private final boolean mIsEmergency; private SatelliteSessionParams(Builder builder) { Loading @@ -762,6 +826,7 @@ public class SatelliteStats { builder.mCountOfSatelliteNotificationDisplayed; this.mCountOfAutoExitDueToScreenOff = builder.mCountOfAutoExitDueToScreenOff; this.mCountOfAutoExitDueToTnNetwork = builder.mCountOfAutoExitDueToTnNetwork; this.mIsEmergency = builder.mIsEmergency; } public int getSatelliteServiceInitializationResult() { Loading Loading @@ -828,6 +893,10 @@ public class SatelliteStats { return mCountOfAutoExitDueToTnNetwork; } public boolean getIsEmergency() { return mIsEmergency; } /** * A builder class to create {@link SatelliteSessionParams} data structure class */ Loading @@ -849,6 +918,7 @@ public class SatelliteStats { private int mCountOfSatelliteNotificationDisplayed = -1; private int mCountOfAutoExitDueToScreenOff = -1; private int mCountOfAutoExitDueToTnNetwork = -1; private boolean mIsEmergency = false; /** * Sets satelliteServiceInitializationResult value of {@link SatelliteSession} Loading Loading @@ -967,6 +1037,12 @@ public class SatelliteStats { return this; } /** Sets whether enabled satellite session is for emergency or not. */ public Builder setIsEmergency(boolean isEmergency) { this.mIsEmergency = isEmergency; return this; } /** * Returns SessionParams, which contains whole component of * {@link SatelliteSession} atom Loading Loading @@ -997,6 +1073,7 @@ public class SatelliteStats { + mCountOfSatelliteNotificationDisplayed + ", CountOfAutoExitDueToScreenOff" + mCountOfAutoExitDueToScreenOff + ", CountOfAutoExitDueToTnNetwork" + mCountOfAutoExitDueToTnNetwork + ", IsEmergency=" + mIsEmergency + ")"; } } Loading Loading @@ -2505,6 +2582,11 @@ public class SatelliteStats { param.getCountOfSatelliteAllowedStateChangedEvents(); proto.countOfSuccessfulLocationQueries = param.getCountOfSuccessfulLocationQueries(); proto.countOfFailedLocationQueries = param.getCountOfFailedLocationQueries(); proto.countOfP2PSmsAvailableNotificationShown = param.getCountOfP2PSmsAvailableNotificationShown(); proto.countOfP2PSmsAvailableNotificationRemoved = param.getCountOfP2PSmsAvailableNotificationRemoved(); proto.isNtnOnlyCarrier = param.isNtnOnlyCarrier(); mAtomsStorage.addSatelliteControllerStats(proto); } Loading @@ -2531,6 +2613,7 @@ public class SatelliteStats { param.getCountOfSatelliteNotificationDisplayed(); proto.countOfAutoExitDueToScreenOff = param.getCountOfAutoExitDueToScreenOff(); proto.countOfAutoExitDueToTnNetwork = param.getCountOfAutoExitDueToTnNetwork(); proto.isEmergency = param.getIsEmergency(); mAtomsStorage.addSatelliteSessionStats(proto); } Loading src/java/com/android/internal/telephony/satellite/DatagramDispatcher.java +3 −5 Original line number Diff line number Diff line Loading @@ -272,6 +272,7 @@ public class DatagramDispatcher extends Handler { request = (DatagramDispatcherHandlerRequest) msg.obj; SendSatelliteDatagramArgument argument = (SendSatelliteDatagramArgument) request.argument; argument.setDatagramStartTime(); onCompleted = obtainMessage(EVENT_SEND_SATELLITE_DATAGRAM_DONE, request); synchronized (mLock) { Loading Loading @@ -480,7 +481,6 @@ public class DatagramDispatcher extends Handler { // Modem can be busy receiving datagrams, so send datagram only when modem is // not busy. mSendingInProgress = true; datagramArgs.setDatagramStartTime(); mDatagramController.updateSendStatus(subId, datagramType, SatelliteManager.SATELLITE_DATAGRAM_TRANSFER_STATE_SENDING, getPendingMessagesCount(), SatelliteManager.SATELLITE_RESULT_SUCCESS); Loading Loading @@ -639,7 +639,6 @@ public class DatagramDispatcher extends Handler { mSendingInProgress = true; // Sets the trigger time for getting pending datagrams datagramArg.setDatagramStartTime(); mDatagramController.updateSendStatus(datagramArg.subId, datagramArg.datagramType, SatelliteManager.SATELLITE_DATAGRAM_TRANSFER_STATE_SENDING, getPendingMessagesCount(), SatelliteManager.SATELLITE_RESULT_SUCCESS); Loading Loading @@ -1346,9 +1345,8 @@ public class DatagramDispatcher extends Handler { if (!mIsAligned) return false; boolean isModemStateConnectedOrTransferring = mModemState == SatelliteManager.SATELLITE_MODEM_STATE_CONNECTED || mModemState == SatelliteManager.SATELLITE_MODEM_STATE_DATAGRAM_TRANSFERRING; mModemState == SATELLITE_MODEM_STATE_CONNECTED || mModemState == SATELLITE_MODEM_STATE_DATAGRAM_TRANSFERRING; if (!isModemStateConnectedOrTransferring && !allowCheckMessageInNotConnected()) { plogd("EVENT_MT_SMS_POLLING_THROTTLE_TIMED_OUT:" + " allow_check_message_in_not_connected is disabled"); Loading Loading
proto/src/persist_atoms.proto +4 −0 Original line number Diff line number Diff line Loading @@ -723,6 +723,9 @@ message SatelliteController { optional int32 count_of_satellite_allowed_state_changed_events = 31; optional int32 count_of_successful_location_queries = 32; optional int32 count_of_failed_location_queries = 33; optional int32 count_of_p2p_sms_available_notification_shown = 34; optional int32 count_of_p2p_sms_available_notification_removed = 35; optional bool is_ntn_only_carrier = 36; } message SatelliteSession { Loading @@ -743,6 +746,7 @@ message SatelliteSession { optional int32 count_of_satellite_notification_displayed = 15; optional int32 count_of_auto_exit_due_to_screen_off = 16; optional int32 count_of_auto_exit_due_to_tn_network = 17; optional bool is_emergency = 18; } message SatelliteIncomingDatagram { Loading
src/java/com/android/internal/telephony/metrics/MetricsCollector.java +6 −2 Original line number Diff line number Diff line Loading @@ -1480,7 +1480,10 @@ public class MetricsCollector implements StatsManager.StatsPullAtomCallback { satelliteController.carrierId, satelliteController.countOfSatelliteAllowedStateChangedEvents, satelliteController.countOfSuccessfulLocationQueries, satelliteController.countOfFailedLocationQueries); satelliteController.countOfFailedLocationQueries, satelliteController.countOfP2PSmsAvailableNotificationShown, satelliteController.countOfP2PSmsAvailableNotificationRemoved, satelliteController.isNtnOnlyCarrier); } private static StatsEvent buildStatsEvent(SatelliteSession satelliteSession) { Loading @@ -1502,7 +1505,8 @@ public class MetricsCollector implements StatsManager.StatsPullAtomCallback { satelliteSession.carrierId, satelliteSession.countOfSatelliteNotificationDisplayed, satelliteSession.countOfAutoExitDueToScreenOff, satelliteSession.countOfAutoExitDueToTnNetwork); satelliteSession.countOfAutoExitDueToTnNetwork, satelliteSession.isEmergency); } private static StatsEvent buildStatsEvent(SatelliteIncomingDatagram stats) { Loading
src/java/com/android/internal/telephony/metrics/PersistAtomsStorage.java +20 −9 Original line number Diff line number Diff line Loading @@ -766,14 +766,17 @@ public class PersistAtomsStorage { existingStats.countOfDisallowedSatelliteAccess += stats.countOfDisallowedSatelliteAccess; existingStats.countOfSatelliteAccessCheckFail += stats.countOfSatelliteAccessCheckFail; existingStats.isProvisioned = stats.isProvisioned; // Does not update isProvisioned and carrierId due to they are dimension fields. existingStats.countOfSatelliteAllowedStateChangedEvents += stats.countOfSatelliteAllowedStateChangedEvents; existingStats.countOfSuccessfulLocationQueries += stats.countOfSuccessfulLocationQueries; existingStats.countOfFailedLocationQueries += stats.countOfFailedLocationQueries; existingStats.countOfP2PSmsAvailableNotificationShown += stats.countOfP2PSmsAvailableNotificationShown; existingStats.countOfP2PSmsAvailableNotificationRemoved += stats.countOfP2PSmsAvailableNotificationRemoved; // Does not update isNtnOnlyCarrier due to it is a dimension field. } else { mAtoms.satelliteController = insertAtRandomPlace(mAtoms.satelliteController, stats, mMaxNumSatelliteStats); Loading Loading @@ -861,7 +864,6 @@ public class PersistAtomsStorage { CarrierRoamingSatelliteControllerStats stats) { CarrierRoamingSatelliteControllerStats existingStats = find(stats); if (existingStats != null) { existingStats.configDataSource = stats.configDataSource; existingStats.countOfEntitlementStatusQueryRequest += stats.countOfEntitlementStatusQueryRequest; existingStats.countOfSatelliteConfigUpdateRequest += Loading @@ -871,6 +873,8 @@ public class PersistAtomsStorage { existingStats.satelliteSessionGapMinSec = stats.satelliteSessionGapMinSec; existingStats.satelliteSessionGapAvgSec = stats.satelliteSessionGapAvgSec; existingStats.satelliteSessionGapMaxSec = stats.satelliteSessionGapMaxSec; // Does not update configDataSource, carrierId, isDeviceEntitled, due to they are // dimension fields. existingStats.isDeviceEntitled = stats.isDeviceEntitled; } else { mAtoms.carrierRoamingSatelliteControllerStats = insertAtRandomPlace( Loading Loading @@ -2342,7 +2346,8 @@ public class PersistAtomsStorage { && stats.countOfSatelliteNotificationDisplayed == key.countOfSatelliteNotificationDisplayed && stats.countOfAutoExitDueToScreenOff == key.countOfAutoExitDueToScreenOff && stats.countOfAutoExitDueToTnNetwork == key.countOfAutoExitDueToTnNetwork) { && stats.countOfAutoExitDueToTnNetwork == key.countOfAutoExitDueToTnNetwork && stats.isEmergency == key.isEmergency) { return stats; } } Loading @@ -2362,6 +2367,8 @@ public class PersistAtomsStorage { && stats.cellularServiceState == key.cellularServiceState && stats.isMultiSim == key.isMultiSim && stats.recommendingHandoverType == key.recommendingHandoverType && stats.isSatelliteAllowedInCurrentLocation == key.isSatelliteAllowedInCurrentLocation && stats.isWifiConnected == key.isWifiConnected && stats.carrierId == key.carrierId) { return stats; Loading @@ -2388,12 +2395,14 @@ public class PersistAtomsStorage { } /** * Returns SatelliteController atom that has same carrier_id value or * {@code null} if does not exist. * Returns the SatelliteController atom with the matching `carrier_id`, `is_provisioned`, and * `is_ntn_only_carrier` values, or {@code null} if does not exist. */ private @Nullable SatelliteController find(SatelliteController key) { for (SatelliteController stats : mAtoms.satelliteController) { if (stats.carrierId == key.carrierId) { if (stats.carrierId == key.carrierId && stats.isProvisioned == key.isProvisioned && stats.isNtnOnlyCarrier == key.isNtnOnlyCarrier) { return stats; } } Loading @@ -2408,7 +2417,9 @@ public class PersistAtomsStorage { CarrierRoamingSatelliteControllerStats key) { for (CarrierRoamingSatelliteControllerStats stats : mAtoms.carrierRoamingSatelliteControllerStats) { if (stats.carrierId == key.carrierId) { if (stats.carrierId == key.carrierId && stats.configDataSource == key.configDataSource && stats.isDeviceEntitled == key.isDeviceEntitled) { return stats; } } Loading
src/java/com/android/internal/telephony/metrics/SatelliteStats.java +85 −2 Original line number Diff line number Diff line Loading @@ -100,6 +100,9 @@ public class SatelliteStats { private final int mCountOfSatelliteAllowedStateChangedEvents; private final int mCountOfSuccessfulLocationQueries; private final int mCountOfFailedLocationQueries; private final int mCountOfP2PSmsAvailableNotificationShown; private final int mCountOfP2PSmsAvailableNotificationRemoved; private static boolean sIsNtnOnlyCarrier; private SatelliteControllerParams(Builder builder) { this.mCountOfSatelliteServiceEnablementsSuccess = Loading Loading @@ -162,6 +165,15 @@ public class SatelliteStats { builder.mCountOfSuccessfulLocationQueries; this.mCountOfFailedLocationQueries = builder.mCountOfFailedLocationQueries; this.mCountOfP2PSmsAvailableNotificationShown = builder.mCountOfP2PSmsAvailableNotificationShown; this.mCountOfP2PSmsAvailableNotificationRemoved = builder.mCountOfP2PSmsAvailableNotificationRemoved; // Carrier ID value should be updated only when it is meaningful. if (builder.mIsNtnOnlyCarrier.isPresent()) { this.sIsNtnOnlyCarrier = builder.mIsNtnOnlyCarrier.get(); } } public int getCountOfSatelliteServiceEnablementsSuccess() { Loading Loading @@ -276,11 +288,11 @@ public class SatelliteStats { return mCountOfSatelliteAccessCheckFail; } public boolean isProvisioned() { public static boolean isProvisioned() { return sIsProvisioned; } public int getCarrierId() { public static int getCarrierId() { return sCarrierId; } Loading @@ -296,6 +308,18 @@ public class SatelliteStats { return mCountOfFailedLocationQueries; } public int getCountOfP2PSmsAvailableNotificationShown() { return mCountOfP2PSmsAvailableNotificationShown; } public int getCountOfP2PSmsAvailableNotificationRemoved() { return mCountOfP2PSmsAvailableNotificationRemoved; } public static boolean isNtnOnlyCarrier() { return sIsNtnOnlyCarrier; } /** * A builder class to create {@link SatelliteControllerParams} data structure class */ Loading Loading @@ -333,6 +357,9 @@ public class SatelliteStats { private int mCountOfSatelliteAllowedStateChangedEvents = 0; private int mCountOfSuccessfulLocationQueries = 0; private int mCountOfFailedLocationQueries = 0; private int mCountOfP2PSmsAvailableNotificationShown = 0; private int mCountOfP2PSmsAvailableNotificationRemoved = 0; private Optional<Boolean> mIsNtnOnlyCarrier = Optional.empty(); /** * Sets countOfSatelliteServiceEnablementsSuccess value of {@link SatelliteController} Loading Loading @@ -660,6 +687,37 @@ public class SatelliteStats { return this; } /** * Sets countOfP2PSmsAvailableNotificationShown value of {@link SatelliteController} * atom then returns Builder class */ public Builder setCountOfP2PSmsAvailableNotificationShown( int countOfP2PSmsAvailableNotificationShown) { this.mCountOfP2PSmsAvailableNotificationShown = countOfP2PSmsAvailableNotificationShown; return this; } /** * Sets countOfP2PSmsAvailableNotificationRemoved value of {@link SatelliteController} * atom then returns Builder class */ public Builder setCountOfP2PSmsAvailableNotificationRemoved( int countOfP2PSmsAvailableNotificationRemoved) { this.mCountOfP2PSmsAvailableNotificationRemoved = countOfP2PSmsAvailableNotificationRemoved; return this; } /** * Sets isNtnOnlyCarrier value of {@link SatelliteController} atom * then returns Builder class */ public Builder setIsNtnOnlyCarrier(boolean isNtnOnlyCarrier) { this.mIsNtnOnlyCarrier = Optional.of(isNtnOnlyCarrier); return this; } /** * Returns ControllerParams, which contains whole component of * {@link SatelliteController} atom Loading Loading @@ -715,6 +773,11 @@ public class SatelliteStats { + mCountOfSatelliteAllowedStateChangedEvents + ", countOfSuccessfulLocationQueries=" + mCountOfSuccessfulLocationQueries + ", countOfFailedLocationQueries=" + mCountOfFailedLocationQueries + ", countOfP2PSmsAvailableNotificationShown=" + mCountOfP2PSmsAvailableNotificationShown + ", countOfP2PSmsAvailableNotificationRemoved=" + mCountOfP2PSmsAvailableNotificationRemoved + ", isNtnOnlyCarrier=" + sIsNtnOnlyCarrier + ")"; } } Loading @@ -740,6 +803,7 @@ public class SatelliteStats { private final int mCountOfSatelliteNotificationDisplayed; private final int mCountOfAutoExitDueToScreenOff; private final int mCountOfAutoExitDueToTnNetwork; private final boolean mIsEmergency; private SatelliteSessionParams(Builder builder) { Loading @@ -762,6 +826,7 @@ public class SatelliteStats { builder.mCountOfSatelliteNotificationDisplayed; this.mCountOfAutoExitDueToScreenOff = builder.mCountOfAutoExitDueToScreenOff; this.mCountOfAutoExitDueToTnNetwork = builder.mCountOfAutoExitDueToTnNetwork; this.mIsEmergency = builder.mIsEmergency; } public int getSatelliteServiceInitializationResult() { Loading Loading @@ -828,6 +893,10 @@ public class SatelliteStats { return mCountOfAutoExitDueToTnNetwork; } public boolean getIsEmergency() { return mIsEmergency; } /** * A builder class to create {@link SatelliteSessionParams} data structure class */ Loading @@ -849,6 +918,7 @@ public class SatelliteStats { private int mCountOfSatelliteNotificationDisplayed = -1; private int mCountOfAutoExitDueToScreenOff = -1; private int mCountOfAutoExitDueToTnNetwork = -1; private boolean mIsEmergency = false; /** * Sets satelliteServiceInitializationResult value of {@link SatelliteSession} Loading Loading @@ -967,6 +1037,12 @@ public class SatelliteStats { return this; } /** Sets whether enabled satellite session is for emergency or not. */ public Builder setIsEmergency(boolean isEmergency) { this.mIsEmergency = isEmergency; return this; } /** * Returns SessionParams, which contains whole component of * {@link SatelliteSession} atom Loading Loading @@ -997,6 +1073,7 @@ public class SatelliteStats { + mCountOfSatelliteNotificationDisplayed + ", CountOfAutoExitDueToScreenOff" + mCountOfAutoExitDueToScreenOff + ", CountOfAutoExitDueToTnNetwork" + mCountOfAutoExitDueToTnNetwork + ", IsEmergency=" + mIsEmergency + ")"; } } Loading Loading @@ -2505,6 +2582,11 @@ public class SatelliteStats { param.getCountOfSatelliteAllowedStateChangedEvents(); proto.countOfSuccessfulLocationQueries = param.getCountOfSuccessfulLocationQueries(); proto.countOfFailedLocationQueries = param.getCountOfFailedLocationQueries(); proto.countOfP2PSmsAvailableNotificationShown = param.getCountOfP2PSmsAvailableNotificationShown(); proto.countOfP2PSmsAvailableNotificationRemoved = param.getCountOfP2PSmsAvailableNotificationRemoved(); proto.isNtnOnlyCarrier = param.isNtnOnlyCarrier(); mAtomsStorage.addSatelliteControllerStats(proto); } Loading @@ -2531,6 +2613,7 @@ public class SatelliteStats { param.getCountOfSatelliteNotificationDisplayed(); proto.countOfAutoExitDueToScreenOff = param.getCountOfAutoExitDueToScreenOff(); proto.countOfAutoExitDueToTnNetwork = param.getCountOfAutoExitDueToTnNetwork(); proto.isEmergency = param.getIsEmergency(); mAtomsStorage.addSatelliteSessionStats(proto); } Loading
src/java/com/android/internal/telephony/satellite/DatagramDispatcher.java +3 −5 Original line number Diff line number Diff line Loading @@ -272,6 +272,7 @@ public class DatagramDispatcher extends Handler { request = (DatagramDispatcherHandlerRequest) msg.obj; SendSatelliteDatagramArgument argument = (SendSatelliteDatagramArgument) request.argument; argument.setDatagramStartTime(); onCompleted = obtainMessage(EVENT_SEND_SATELLITE_DATAGRAM_DONE, request); synchronized (mLock) { Loading Loading @@ -480,7 +481,6 @@ public class DatagramDispatcher extends Handler { // Modem can be busy receiving datagrams, so send datagram only when modem is // not busy. mSendingInProgress = true; datagramArgs.setDatagramStartTime(); mDatagramController.updateSendStatus(subId, datagramType, SatelliteManager.SATELLITE_DATAGRAM_TRANSFER_STATE_SENDING, getPendingMessagesCount(), SatelliteManager.SATELLITE_RESULT_SUCCESS); Loading Loading @@ -639,7 +639,6 @@ public class DatagramDispatcher extends Handler { mSendingInProgress = true; // Sets the trigger time for getting pending datagrams datagramArg.setDatagramStartTime(); mDatagramController.updateSendStatus(datagramArg.subId, datagramArg.datagramType, SatelliteManager.SATELLITE_DATAGRAM_TRANSFER_STATE_SENDING, getPendingMessagesCount(), SatelliteManager.SATELLITE_RESULT_SUCCESS); Loading Loading @@ -1346,9 +1345,8 @@ public class DatagramDispatcher extends Handler { if (!mIsAligned) return false; boolean isModemStateConnectedOrTransferring = mModemState == SatelliteManager.SATELLITE_MODEM_STATE_CONNECTED || mModemState == SatelliteManager.SATELLITE_MODEM_STATE_DATAGRAM_TRANSFERRING; mModemState == SATELLITE_MODEM_STATE_CONNECTED || mModemState == SATELLITE_MODEM_STATE_DATAGRAM_TRANSFERRING; if (!isModemStateConnectedOrTransferring && !allowCheckMessageInNotConnected()) { plogd("EVENT_MT_SMS_POLLING_THROTTLE_TIMED_OUT:" + " allow_check_message_in_not_connected is disabled"); Loading