Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a way to log events from my Android application to Stackdriver with logback-android?

I am looking for the most convenient way to log entries from my Android application to Stackdriver. My code is in Kotlin using the Flutter framework.

I am already using logback-android due to its usage by a library I'm dependent on, so a SLF4J appender to Stackdriver would be most suitable but I couldn't find anything like it. I also tried using the Google Cloud Logging Library but it seems to not support Kotlin.

like image 943
AgeBlade Avatar asked Nov 15 '22 22:11

AgeBlade


1 Answers

After a day of thinking about this issue, and due to the fact that a service account shouldn't be located at the client-side (the Flutter app), I realized the best way is to implement a \log endpoint at the server-side and send logs using authenticated requests.

like image 63
AgeBlade Avatar answered Dec 29 '22 08:12

AgeBlade