Skip to content

Commit 832f808

Browse files
authored
Merge branch 'main' into fix_fis_issue
2 parents 2ca1c0d + aad3da8 commit 832f808

File tree

75 files changed

+62
-7241
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

75 files changed

+62
-7241
lines changed

.github/workflows/ci_tests.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,5 +169,6 @@ jobs:
169169

170170
- name: Publish Test Results
171171
uses: EnricoMi/publish-unit-test-result-action@170bf24d20d201b842d7a52403b73ed297e6645b # v2.18.0
172+
if: always()
172173
with:
173174
files: "artifacts/**/*.xml"

.github/workflows/plugins-check.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ jobs:
3030
./gradlew plugins:check
3131
- name: Publish Test Results
3232
uses: EnricoMi/publish-unit-test-result-action@170bf24d20d201b842d7a52403b73ed297e6645b # v2.18.0
33+
if: always()
3334
with:
3435
files: "**/build/test-results/**/*.xml"
3536
check_name: "plugins test results"

ci/fireci/fireciplugins/macrobenchmark/run/runner.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,6 @@ def _process_changed_modules(path: Path) -> List[str]:
119119
":firebase-components": ["Firebase", "ComponentDiscovery", "Runtime"],
120120
":firebase-database": ["fire-rtdb"],
121121
":firebase-datatransport": ["fire-transport"],
122-
":firebase-dynamic-links": ["fire-dl"],
123122
":firebase-crashlytics": ["fire-cls"],
124123
":firebase-crashlytics-ndk": ["fire-cls"],
125124
":firebase-firestore": ["fire-fst"],

docs/README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ in your app:
2626

2727
* [`firebase-common`](ktx/common.md)
2828
* [`firebase-crashlytics`](ktx/crashlytics.md)
29-
* [`firebase-dynamic-links`](ktx/dynamic-links.md)
3029
* [`firebase-firestore`](ktx/firestore.md)
3130
* [`firebase-functions`](ktx/functions.md)
3231
* [`firebase-inappmessaging`](ktx/inappmessaging.md)

docs/ktx/dynamic-links.md

Lines changed: 0 additions & 170 deletions
This file was deleted.

firebase-config/firebase-config.gradle.kts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ dependencies {
8585
annotationProcessor(libs.autovalue)
8686
javadocClasspath(libs.autovalue.annotations)
8787
compileOnly(libs.autovalue.annotations)
88+
compileOnly(libs.errorprone.annotations)
8889
compileOnly(libs.findbugs.jsr305)
8990

9091
// Testing

firebase-config/src/main/java/com/google/firebase/remoteconfig/internal/ConfigAutoFetch.java

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
import java.util.Random;
3838
import java.util.Set;
3939
import java.util.concurrent.ScheduledExecutorService;
40+
import java.util.concurrent.ScheduledFuture;
4041
import java.util.concurrent.TimeUnit;
4142
import org.json.JSONException;
4243
import org.json.JSONObject;
@@ -248,15 +249,16 @@ private void autoFetch(int remainingAttempts, long targetVersion) {
248249

249250
// Randomize fetch to occur between 0 - 4 seconds.
250251
int timeTillFetch = random.nextInt(4);
251-
scheduledExecutorService.schedule(
252-
new Runnable() {
253-
@Override
254-
public void run() {
255-
fetchLatestConfig(remainingAttempts, targetVersion);
256-
}
257-
},
258-
timeTillFetch,
259-
TimeUnit.SECONDS);
252+
ScheduledFuture<?> unused =
253+
scheduledExecutorService.schedule(
254+
new Runnable() {
255+
@Override
256+
public void run() {
257+
Task<Void> unused = fetchLatestConfig(remainingAttempts, targetVersion);
258+
}
259+
},
260+
timeTillFetch,
261+
TimeUnit.SECONDS);
260262
}
261263

262264
@VisibleForTesting

firebase-config/src/main/java/com/google/firebase/remoteconfig/internal/ConfigContainer.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414

1515
package com.google.firebase.remoteconfig.internal;
1616

17+
import com.google.errorprone.annotations.CanIgnoreReturnValue;
1718
import java.util.Date;
1819
import java.util.HashMap;
1920
import java.util.HashSet;
@@ -328,11 +329,13 @@ public Builder(ConfigContainer otherContainer) {
328329
this.builderRolloutMetadata = otherContainer.getRolloutMetadata();
329330
}
330331

332+
@CanIgnoreReturnValue
331333
public Builder replaceConfigsWith(Map<String, String> configsMap) {
332334
this.builderConfigsJson = new JSONObject(configsMap);
333335
return this;
334336
}
335337

338+
@CanIgnoreReturnValue
336339
public Builder replaceConfigsWith(JSONObject configsJson) {
337340
try {
338341
this.builderConfigsJson = new JSONObject(configsJson.toString());
@@ -345,11 +348,13 @@ public Builder replaceConfigsWith(JSONObject configsJson) {
345348
return this;
346349
}
347350

351+
@CanIgnoreReturnValue
348352
public Builder withFetchTime(Date fetchTime) {
349353
this.builderFetchTime = fetchTime;
350354
return this;
351355
}
352356

357+
@CanIgnoreReturnValue
353358
public Builder withAbtExperiments(JSONArray abtExperiments) {
354359
try {
355360
this.builderAbtExperiments = new JSONArray(abtExperiments.toString());
@@ -362,6 +367,7 @@ public Builder withAbtExperiments(JSONArray abtExperiments) {
362367
return this;
363368
}
364369

370+
@CanIgnoreReturnValue
365371
public Builder withPersonalizationMetadata(JSONObject personalizationMetadata) {
366372
try {
367373
this.builderPersonalizationMetadata = new JSONObject(personalizationMetadata.toString());
@@ -374,11 +380,13 @@ public Builder withPersonalizationMetadata(JSONObject personalizationMetadata) {
374380
return this;
375381
}
376382

383+
@CanIgnoreReturnValue
377384
public Builder withTemplateVersionNumber(long templateVersionNumber) {
378385
this.builderTemplateVersionNumber = templateVersionNumber;
379386
return this;
380387
}
381388

389+
@CanIgnoreReturnValue
382390
public Builder withRolloutMetadata(JSONArray rolloutMetadata) {
383391
try {
384392
this.builderRolloutMetadata = new JSONArray(rolloutMetadata.toString());

firebase-config/src/main/java/com/google/firebase/remoteconfig/internal/ConfigFetchHandler.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public class ConfigFetchHandler {
7777
*
7878
* <p>Defined here since {@link HttpURLConnection} does not provide this code.
7979
*/
80-
@VisibleForTesting static final int HTTP_TOO_MANY_REQUESTS = 429;
80+
static final int HTTP_TOO_MANY_REQUESTS = 429;
8181

8282
/**
8383
* First-open time key name in GA user-properties. First-open time is a predefined user-dimension

firebase-config/src/main/java/com/google/firebase/remoteconfig/internal/ConfigRealtimeHttpClient.java

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@
5757
import java.util.Random;
5858
import java.util.Set;
5959
import java.util.concurrent.ScheduledExecutorService;
60+
import java.util.concurrent.ScheduledFuture;
6061
import java.util.concurrent.TimeUnit;
6162
import java.util.regex.Matcher;
6263
import java.util.regex.Pattern;
@@ -381,15 +382,16 @@ private synchronized void makeRealtimeHttpConnection(long retryMilliseconds) {
381382

382383
if (httpRetriesRemaining > 0) {
383384
httpRetriesRemaining--;
384-
scheduledExecutorService.schedule(
385-
new Runnable() {
386-
@Override
387-
public void run() {
388-
beginRealtimeHttpStream();
389-
}
390-
},
391-
retryMilliseconds,
392-
TimeUnit.MILLISECONDS);
385+
ScheduledFuture<?> unused =
386+
scheduledExecutorService.schedule(
387+
new Runnable() {
388+
@Override
389+
public void run() {
390+
beginRealtimeHttpStream();
391+
}
392+
},
393+
retryMilliseconds,
394+
TimeUnit.MILLISECONDS);
393395
} else if (!isInBackground) {
394396
propagateErrors(
395397
new FirebaseRemoteConfigClientException(

0 commit comments

Comments
 (0)