blob: e65fe6dc8d628e08bd5592cabe4708d117d7ecbe [file] [log] [blame]
Himanshu Jajudbcee232019-06-17 19:41:491// Copyright 2019 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef CHROME_BROWSER_SHARING_FEATURES_H_
6#define CHROME_BROWSER_SHARING_FEATURES_H_
7
8#include "base/feature_list.h"
Michael van Ouwerkerk99d7e562019-12-03 17:14:369#include "base/metrics/field_trial_params.h"
Himanshu Jajudbcee232019-06-17 19:41:4910
Travis Skareba1cc442019-10-02 22:28:1111// Feature flag to enable QR Code Generator (currently desktop-only).
12extern const base::Feature kSharingQRCodeGenerator;
13
Alex Chauf2b97662019-10-04 11:21:5114// Feature flag to enable deriving VAPID key from Sync.
15extern const base::Feature kSharingDeriveVapidKey;
16
Michael van Ouwerkerk99d7e562019-12-03 17:14:3617// Feature flag for configuring device expiration.
18extern const base::Feature kSharingDeviceExpiration;
19
20// The number of hours after which a device is considered expired.
21extern const base::FeatureParam<int> kSharingDeviceExpirationHours;
22
Michael van Ouwerkerka91ab6e2020-02-03 12:55:3823// Feature flag for matching device expiration to pulse interval.
24extern const base::Feature kSharingMatchPulseInterval;
25
26// The delta from the pulse interval in hours after which a device is considered
27// expired, for Desktop devices. Chrome on Desktop is expected to update the
28// last updated timestamp quite frequently because it can do this when
29// backgrounded. Such devices can be marked stale aggressively if they did not
30// update for more than an interval.
31extern const base::FeatureParam<int> kSharingPulseDeltaDesktopHours;
32
33// The delta from the pulse interval in hours after which a device is considered
34// expired, for Android devices. Chrome on Android is expected to update the
35// last updated timestamp less frequently because it does not do this when
36// backgrounded. Such devices cannot be marked stale aggressively.
37extern const base::FeatureParam<int> kSharingPulseDeltaAndroidHours;
38
Michael van Ouwerkerk99e2ba822020-01-16 12:12:2439// Feature flag for configuring the sharing message timeout. This sets both the
40// FCM message TTL and the duration of the timer that waits for an ack.
41extern const base::Feature kSharingMessageTTL;
42
43// The duration in seconds for both the FCM message TTL and the timer that waits
44// for an ack.
45extern const base::FeatureParam<int> kSharingMessageTTLSeconds;
46
47// Feature flag for configuring the FCM TTL for sharing ack messages.
48extern const base::Feature kSharingAckMessageTTL;
49
50// The FCM TTL in seconds for sharing ack messages.
51extern const base::FeatureParam<int> kSharingAckMessageTTLSeconds;
52
Alex Chauf15a7192020-01-30 17:37:5153// Feature flag for sending sharing message via Sync.
54extern const base::Feature kSharingSendViaSync;
55
Himanshu Jajudbcee232019-06-17 19:41:4956#endif // CHROME_BROWSER_SHARING_FEATURES_H_