Skip to content

Commit 368cfad

Browse files
committed
Use managed guid in the native layer
1 parent 7a2cd1e commit 368cfad

File tree

3 files changed

+38
-7
lines changed

3 files changed

+38
-7
lines changed

CHANGELOG.md

Lines changed: 32 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,42 @@
11
# Backtrace Android Release Notes
22

33
## Version 3.7.5
4+
45
- Maintenance: Update various components to latest versions
56
- Maintenance: CI job improvements
67
- Bugfix: Handle corrupt or empty database records
8+
- Bugfix: Managed and native reports generated by the same user now have the same `guid`
79
- Backtrace metrics support - now the interface doesn't require to use `BacktraceCredentials` anymore
810
- Upgraded native crash reporter. The new version should capture crashes generated by the newest version of SDK
911

1012
## Version 3.7.4
13+
1114
- Feature: migrated to AndroidX
1215
- Improvement: removed READ_EXTERNAL_STORAGE permission from library AndroidManifest.xml
1316

1417
## Version 3.7.3
18+
1519
- Bug: Crashpad attachment syntax changed
1620

1721
## Version 3.7.2
22+
1823
- Bug: Fix issue rolling over Breadcrumb file
1924
- Feature: update gradle to latest
2025
- Feature: integrate crashpad via cmake
2126
- Improvement: Make local.properties optional
2227
- Improvement: Cleanup build scripts for speed
2328

2429
## Version 3.7.1 - 14.06.2022
30+
2531
- Error type "crash" only on unhandled exceptions from main thread for other threads - error type will be "unhandled exception"
2632

2733
## Version 3.7.0 - 28.04.2022
34+
2835
- Added error.type attribute that shows type of the report
2936
- Added backtrace.version attribute that shows Backtrace agent version
3037

3138
## Version 3.6.0 - 29.1.2022
39+
3240
- Added error-free metrics
3341
- Added method to disable native crash reporting
3442
- Fixed Crashpad initialization failure in Samsung A20
@@ -37,57 +45,69 @@
3745
- GitHub actions CICD support
3846

3947
## Version 3.5.0 - 14.09.2021
48+
4049
- Added support for native crash reporting in NDK 16b
4150
- Bug fixes and expanded supported NDK versions for client side unwinding
4251

4352
## Version 3.4.0 - 07.09.2021
53+
4454
- Added support for NDK 22
4555

4656
## Version 3.3.0 - 15.07.2021
57+
4758
- Added support for client side unwinding of native crashes
4859

4960
## Version 3.2.2 - 10.03.2021
61+
5062
- Hotfix for crash when user enables native integration without file attachments
5163

5264
## Version 3.2.1 - 09.03.2021
65+
5366
- Native crashes now support custom attributes
5467
- Improved file attachment support for managed and native crashes
5568
- Fixed file attachments bug in BacktraceDatabaseRecord
5669

5770
## Version 3.2.0 - 02.03.2021
71+
5872
- Added Breadcrumbs feature to give Backtrace users context leading up to a `BacktraceReport`
5973
- Improved support for Proguard
6074

6175
## Version 3.1.0 - 29.09.2020
76+
6277
- Backtrace Android allows to capture native crashes from Android NDK code. To enable NDK crashes exception handler use `setupNativeIntegration` method and pass backtraceClient with credentials.
6378

6479
```java
6580
database.setupNativeIntegration(backtraceClient, credentials);
6681
```
6782

6883
## Version 3.0.2 - 23.01.2020
84+
6985
- Fixed checking internal path during filtering attachments
7086

7187
## Version 3.0.1 - 15.01.2020
88+
7289
- Fixed setting custom global attributes on BacktraceClient
7390
- Added support for custom attributes to BacktraceExceptionHandler
7491

7592
## Version 3.0.0 - 03.12.2019
93+
7694
- Added support for `submit.backtrace.io` urls
7795
- Moved generating a server url from BacktraceApi to BacktraceCredentials
7896
- Refactored name of below libraries interfaces:
79-
* IBacktraceApi -> Api
80-
* IBacktraceClient -> Client
81-
* IBacktraceDatabase -> Database
82-
* IBacktraceDatabaseRecordWriter -> DatabaseRecordWriter
83-
* IBacktraceDatabaseFileContext -> DatabaseFileContext
84-
* IBacktraceDatabaseContext -> DatabaseContext
97+
- IBacktraceApi -> Api
98+
- IBacktraceClient -> Client
99+
- IBacktraceDatabase -> Database
100+
- IBacktraceDatabaseRecordWriter -> DatabaseRecordWriter
101+
- IBacktraceDatabaseFileContext -> DatabaseFileContext
102+
- IBacktraceDatabaseContext -> DatabaseContext
85103

86104
## Version 2.1.0 - 16.06.2019
105+
87106
- Added support for detecting ANR (Application Not Responding)
88107
- Added methods and structures to detecting blocked custom threads
89108

90109
## Version 2.0.0 - 06.05.2019
110+
91111
- Removed `sendAsync` method
92112
- Removed event `OnAfterSendEventListener`
93113
- Moved event `OnServerResponseEventListener` to parameter of `send` method
@@ -96,20 +116,25 @@ database.setupNativeIntegration(backtraceClient, credentials);
96116
- Removed deprecated and unused code
97117

98118
## Version 1.2.1 - 12.04.2019
119+
99120
- Added check is temperature file is empty and remove print stacktrace
100121
- Changed attribute name `app.version_name` to `version`
101122

102123
## Version 1.2.0 - 07.04.2019
124+
103125
- `BacktraceDatabase` - offline error report storage and auto re-submission support in the event of network outage and server unavailability,
104126

105127
## Version 1.1.2 - 07.03.2019
128+
106129
- Added class name to function name in exception StackFrame
107130
- Added exception message to annotations
108131

109132
## Version 1.1.1 - 26.02.2019
133+
110134
- Fixed exception on filter out Backtrace files from StackTraceElements when file name is null
111135

112136
## Version 1.1.0 - 25.02.2019
137+
113138
- Added support for file attachments and annotations
114139
- Added battery level and status attributes
115140
- Added screen brightness attribute
@@ -120,4 +145,5 @@ database.setupNativeIntegration(backtraceClient, credentials);
120145
- Replaced spaces with underscore in all enums strings
121146

122147
## Version 1.0 - 27.01.2019
148+
123149
- First release.

backtrace-library/src/main/cpp/backends/crashpad-backend.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,11 @@ bool InitializeCrashpad(jstring url,
120120

121121
// Start crash handler
122122
client = new crashpad::CrashpadClient();
123+
std::map<std::string, std::string>::iterator guidIterator = attributes.find("guid");
124+
if(guidIterator != attributes.end())
125+
{
126+
client->OverrideGuid(guidIterator->second);
127+
}
123128

124129
initialized = client->StartHandlerAtCrash(handler, db, db, backtraceUrl, attributes,
125130
arguments);

0 commit comments

Comments
 (0)