Skip to content

Commit

Permalink
Merge branch 'main' into td/record-exception-ktx
Browse files Browse the repository at this point in the history
  • Loading branch information
tejasd authored Dec 5, 2024
2 parents be1ce95 + 71ceb1b commit d0d9c82
Show file tree
Hide file tree
Showing 26 changed files with 102 additions and 50 deletions.
22 changes: 13 additions & 9 deletions .github/workflows/private-mirror-sync.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,30 @@
name: Private Mirror Sync

concurrency:
group: ${{ github.workflow }}
cancel-in-progress: true

on:
push:
branches:
- main
workflow_dispatch:
schedule:
- cron: '0 2 * * *'

jobs:
sync:
if: github.repository == 'firebase/firebase-android-sdk'
if: github.repository == 'FirebasePrivate/firebase-android-sdk'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4.1.1
with:
repository: firebase/firebase-android-sdk
ref: main
fetch-depth: 0
submodules: true

- uses: actions/checkout@v4.1.1
with:
fetch-depth: 0
submodules: true
token: ${{ secrets.GOOGLE_OSS_BOT_TOKEN }}
committer: google-oss-bot <firebase-oss-bot@google.com>
- name: Force push HEAD to private repo main branch
run: |
git config --local user.name google-oss-bot
git config --local user.email firebase-oss-bot@google.com
git remote add mirror https://github.com/FirebasePrivate/firebase-android-sdk.git
git push mirror HEAD:main --force --verbose
3 changes: 3 additions & 0 deletions firebase-crashlytics-ndk/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Unreleased


# 19.3.0
* [changed] Updated `firebase-crashlytics` dependency to v19.3.0

# 19.2.1
* [changed] Updated `firebase-crashlytics` dependency to v19.2.1

Expand Down
4 changes: 2 additions & 2 deletions firebase-crashlytics-ndk/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
version=19.2.2
latestReleasedVersion=19.2.1
version=19.3.1
latestReleasedVersion=19.3.0
10 changes: 10 additions & 0 deletions firebase-crashlytics/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,17 @@
# Unreleased
* [feature] Added an overload for `recordException` that allows logging additional custom
keys to the non fatal event [#3551]

# 19.3.0
* [fixed] Fixed inefficiency in the Kotlin `FirebaseCrashlytics.setCustomKeys` extension.
* [fixed] Execute failure listener outside the main thread [#6535]


## Kotlin
The Kotlin extensions library transitively includes the updated
`firebase-crashlytics` library. The Kotlin extensions library has no additional
updates.

# 19.2.1
* [changed] Updated protobuf dependency to `3.25.5` to fix
[CVE-2024-7254](https://nvd.nist.gov/vuln/detail/CVE-2024-7254).
Expand Down
4 changes: 2 additions & 2 deletions firebase-crashlytics/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
version=19.2.2
latestReleasedVersion=19.2.1
version=19.3.1
latestReleasedVersion=19.3.0
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ package com.google.firebase.crashlytics.internal.metadata
* @property additionalCustomKeys a [Map<String, String>] of key value pairs to attach to the event,
* in addition to the global custom keys.
*/
data class EventMetadata
internal data class EventMetadata
@JvmOverloads
constructor(
val sessionId: String,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,26 +149,33 @@ public void setUserId(String identifier) {
*/
public Map<String, String> getCustomKeys(Map<String, String> eventKeys) {
// In case of empty event keys, preserve existing behavior.
if (eventKeys.isEmpty()) return customKeys.getKeys();
if (eventKeys.isEmpty()) {
return customKeys.getKeys();
}

// Otherwise merge the event keys with custom keys as appropriate.
Map<String, String> globalKeys = customKeys.getKeys();
HashMap<String, String> result = new HashMap<>(globalKeys);
int eventKeysOverLimit = 0;
for (Map.Entry<String, String> entry : eventKeys.entrySet()) {
String sanitizedKey = KeysMap.sanitizeString(entry.getKey(), MAX_ATTRIBUTE_SIZE);
if (result.size() < MAX_ATTRIBUTES || result.containsKey(sanitizedKey)) {
String sanitizedValue = KeysMap.sanitizeString(entry.getValue(), MAX_ATTRIBUTE_SIZE);
result.put(sanitizedKey, sanitizedValue);
continue;
} else {
eventKeysOverLimit++;
}
}

if (eventKeysOverLimit > 0) {
Logger.getLogger()
.w(
"Ignored entry \""
+ entry.getKey()
+ "\" when adding event specific keys. Maximum allowable: "
"Ignored "
+ eventKeysOverLimit
+ " keys when adding event specific keys. Maximum allowable: "
+ MAX_ATTRIBUTE_SIZE);
}

return Collections.unmodifiableMap(result);
}

Expand Down
3 changes: 3 additions & 0 deletions firebase-dataconnect/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Unreleased


# 16.0.0-beta03
* [changed] Requires Data Connect emulator version 1.6.1 or later for code generation.
* [feature] QueryRef and MutationRef gain methods copy(), withDataDeserializer(),
and withVariablesSerializer().
Expand Down
4 changes: 2 additions & 2 deletions firebase-dataconnect/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
version=16.0.0-beta03
latestReleasedVersion=16.0.0-beta02
version=16.0.0-beta04
latestReleasedVersion=16.0.0-beta03
9 changes: 7 additions & 2 deletions firebase-functions/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
# Unreleased
* [fixed] Minor internal infrastructure improvements. (#6544)
* [fixed] Fixed HttpsCallableResult.data resolution in Kotlin. (#6530)


# 21.1.0
* [changed] Migrated to Kotlin


## Kotlin
The Kotlin extensions library transitively includes the updated
`firebase-functions` library. The Kotlin extensions library has no additional
updates.

# 21.0.0
* [changed] Bump internal dependencies

Expand Down
4 changes: 2 additions & 2 deletions firebase-functions/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
version=21.1.0
latestReleasedVersion=21.0.0
version=21.1.1
latestReleasedVersion=21.1.0
android.enableUnitTestBinaryResources=true
3 changes: 3 additions & 0 deletions firebase-messaging-directboot/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Unreleased


# 24.1.0
* [unchanged] Updated to keep messaging SDK versions aligned.

# 24.0.3
Expand Down
4 changes: 2 additions & 2 deletions firebase-messaging-directboot/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
version=24.1.0
latestReleasedVersion=24.0.3
version=24.1.1
latestReleasedVersion=24.1.0
android.enableUnitTestBinaryResources=true
8 changes: 8 additions & 0 deletions firebase-messaging/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Unreleased


# 24.1.0
* [deprecated] Deprecated additional FCM upstream messaging methods and updated
all upstream methods to indicate they are now decommissioned. See the
[FAQ](https://firebase.google.com/support/faq#fcm-23-deprecation) for more
Expand All @@ -8,6 +11,11 @@
been canceled.


## Kotlin
The Kotlin extensions library transitively includes the updated
`firebase-messaging` library. The Kotlin extensions library has no additional
updates.

# 24.0.3
* [changed] Updated protobuf dependency to `3.25.5` to fix
[CVE-2024-7254](https://nvd.nist.gov/vuln/detail/CVE-2024-7254).
Expand Down
4 changes: 2 additions & 2 deletions firebase-messaging/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
version=24.1.0
latestReleasedVersion=24.0.3
version=24.1.1
latestReleasedVersion=24.1.0
android.enableUnitTestBinaryResources=true
9 changes: 9 additions & 0 deletions firebase-perf/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
# Unreleased


# 21.0.3
* [changed] Bump internal dependencies.


## Kotlin
The Kotlin extensions library transitively includes the updated
`firebase-performance` library. The Kotlin extensions library has no additional
updates.

# 21.0.2
* [fixed] Fixed `IllegalStateException` that happened when starting a trace
before Firebase initializes.
Expand Down
4 changes: 2 additions & 2 deletions firebase-perf/firebase-perf.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ dependencies {
api("com.google.firebase:firebase-components:18.0.0")
api("com.google.firebase:firebase-config:21.5.0")
api("com.google.firebase:firebase-installations:17.2.0")
api("com.google.firebase:firebase-sessions:2.0.0") {
api("com.google.firebase:firebase-sessions:2.0.7") {
exclude group: 'com.google.firebase', module: 'firebase-common'
exclude group: 'com.google.firebase', module: 'firebase-common-ktx'
exclude group: 'com.google.firebase', module: 'firebase-components'
Expand All @@ -138,4 +138,4 @@ dependencies {
testImplementation libs.mockito.core
testImplementation 'org.mockito:mockito-inline:5.2.0'
testImplementation group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.5.6'
}
}
4 changes: 2 additions & 2 deletions firebase-perf/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#
#

version=21.0.3
latestReleasedVersion=21.0.2
version=21.0.4
latestReleasedVersion=21.0.3
android.enableUnitTestBinaryResources=true

9 changes: 3 additions & 6 deletions firebase-sessions/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
# Unreleased


# 2.0.7
* [fixed] Removed extraneous logs that risk leaking internal identifiers.

# 2.0.6
* [changed] Updated protobuf dependency to `3.25.5` to fix
[CVE-2024-7254](https://github.com/advisories/GHSA-735f-pc8j-v9w8).


## Kotlin
The Kotlin extensions library transitively includes the updated
`firebase-sessions` library. The Kotlin extensions library has no additional
updates.

# 2.0.5
* [unchanged] Updated to keep SDK versions aligned.

Expand Down
4 changes: 2 additions & 2 deletions firebase-sessions/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@
# See the License for the specific language governing permissions and
# limitations under the License.

version=2.0.7
latestReleasedVersion=2.0.6
version=2.0.8
latestReleasedVersion=2.0.7
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ internal class EventGDTLogger(private val transportFactoryProvider: Provider<Tra

private fun encode(value: SessionEvent): ByteArray {
val jsonEvent = SessionEvents.SESSION_EVENT_ENCODER.encode(value)
Log.d(TAG, "Session Event: $jsonEvent")
Log.d(TAG, "Session Event Type: ${value.eventType.name}")
return jsonEvent.toByteArray()
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ internal class SessionFirelogPublisherImpl(
private fun attemptLoggingSessionEvent(sessionEvent: SessionEvent) {
try {
eventGDTLogger.log(sessionEvent)
Log.d(TAG, "Successfully logged Session Start event: ${sessionEvent.sessionData.sessionId}")
Log.d(TAG, "Successfully logged Session Start event.")
} catch (ex: RuntimeException) {
Log.e(TAG, "Error logging Session Start event to DataTransport: ", ex)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ internal class SessionLifecycleClient(private val backgroundDispatcher: Coroutin
}

private fun handleSessionUpdate(sessionId: String) {
Log.d(TAG, "Session update received: $sessionId")
Log.d(TAG, "Session update received.")

CoroutineScope(backgroundDispatcher).launch {
FirebaseSessionsDependencies.getRegisteredSubscribers().values.forEach { subscriber ->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ internal class SessionLifecycleService : Service() {
/** Generates a new session id and sends it everywhere it's needed */
private fun newSession() {
SessionGenerator.instance.generateNewSession()
Log.d(TAG, "Generated new session ${SessionGenerator.instance.currentSession.sessionId}")
Log.d(TAG, "Generated new session.")
broadcastSession()
SessionDatastore.instance.updateSessionId(SessionGenerator.instance.currentSession.sessionId)
}
Expand All @@ -138,7 +138,7 @@ internal class SessionLifecycleService : Service() {
* connected clients.
*/
private fun broadcastSession() {
Log.d(TAG, "Broadcasting new session: ${SessionGenerator.instance.currentSession}")
Log.d(TAG, "Broadcasting new session")
SessionFirelogPublisher.instance.logSession(SessionGenerator.instance.currentSession)
// Create a defensive copy because DeadObjectExceptions on send will modify boundClients
val clientsToSend = ArrayList(boundClients)
Expand All @@ -151,7 +151,7 @@ internal class SessionLifecycleService : Service() {
} else {
// Send the value from the datastore before the first foregrounding it exists
val storedSession = SessionDatastore.instance.getCurrentSessionId()
Log.d(TAG, "App has not yet foregrounded. Using previously stored session: $storedSession")
Log.d(TAG, "App has not yet foregrounded. Using previously stored session.")
storedSession?.let { sendSessionToClient(client, it) }
}
}
Expand Down
5 changes: 4 additions & 1 deletion firebase-vertexai/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Unreleased
* [changed] Added support for Civic Integrity in Harm Category. (#6502)


# 16.0.2
* [fixed] Improved error message when using an invalid location. (#6428)
* [fixed] Fixed issue where Firebase App Check error tokens were unintentionally missing from the requests. (#6409)
* [fixed] Clarified in the documentation that `Schema.integer` and `Schema.float` only provide hints to the model. (#6420)
Expand Down Expand Up @@ -59,3 +61,4 @@
* [feature] Added support for `responseMimeType` in `GenerationConfig`.
* [changed] Renamed `GoogleGenerativeAIException` to `FirebaseVertexAIException`.
* [changed] Updated the KDocs for various classes and functions.

4 changes: 2 additions & 2 deletions firebase-vertexai/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@
# See the License for the specific language governing permissions and
# limitations under the License.

version=16.0.2
latestReleasedVersion=16.0.1
version=16.1.0
latestReleasedVersion=16.0.2

0 comments on commit d0d9c82

Please sign in to comment.