Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
DevFest Atlanta - Firebase Remote Config + Fire...
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Rebecca Franks
November 12, 2016
Science
140
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
DevFest Atlanta - Firebase Remote Config + Firebase Test Lab
Rebecca Franks
November 12, 2016
More Decks by Rebecca Franks
See All by Rebecca Franks
Custom Drawing in Compose - Londroid December 2022
riggaroo
0
300
Android Studio - What's new 2020
riggaroo
0
180
Getting Started with MotionLayout - Async Android 2020
riggaroo
2
2.5k
Mobile Era 2019 - Tips for Building Custom Views on Android with Canvas APIs
riggaroo
2
350
Over ❤️ Kotlin - How we've used Kotlin to build a Mobile Design App
riggaroo
2
7.1k
Tips for Building Custom Views on Android with Canvas APIs
riggaroo
2
800
In a World of Pure Android Animation 🍭🍫
riggaroo
3
780
Building your Personal Brand - IWD Johannesburg 2019
riggaroo
5
370
How to write a great Conference Proposal - Global CFP Day - Johannesburg 2019
riggaroo
4
590
Other Decks in Science
See All in Science
SpatialRDDパッケージによる空間回帰不連続デザイン
saltcooky12
0
280
データベース01: データベースを使わない世界
trycycle
PRO
1
1.4k
Wet Active Matter
rajeshrinet
0
130
Understanding CVP Waveforms: Interpretation and Clinical Implications in Anesthesiology
taka88
0
700
(2025) Balade en cyclotomie
mansuy
0
660
Bリーグのショットデータを活用した得点期待値モデルの構築 / Construction of expected points model using shot data of B.LEAGUE
konakalab
0
170
20260410_SystemsThinking
takusamar
1
120
コーヒー豆様核 (Coffee-bean nuclei) における形態学的サブタイピングと精選・焙煎特性の同定
jagupath
PRO
0
130
あなたに水耕栽培を愛していないとは言わせない
mutsumix
1
370
機械学習 - 決定木からはじめる機械学習
trycycle
PRO
0
1.6k
JSAI2026企画セッションKS-14 インタビュー集『⼈⼯知能と哲学と四つの問い』が提起する⼈⼯知能のこれからの課題 趣旨説明 / JSAI2026 Special Session: A Collection of Interviews, “Artificial Intelligence, Philosophy, and Four Questions”
ykiyota
0
400
(CVPR2026) Back to Basics: Let Denoising Generative Models Denoise
shumpei777
0
240
Featured
See All Featured
HU Berlin: Industrial-Strength Natural Language Processing with spaCy and Prodigy
inesmontani
PRO
0
580
Agile that works and the tools we love
rasmusluckow
331
22k
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
920
Building Applications with DynamoDB
mza
96
7.1k
Designing Powerful Visuals for Engaging Learning
tmiket
1
470
The Director’s Chair: Orchestrating AI for Truly Effective Learning
tmiket
1
230
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
17k
Speed Design
sergeychernyshev
33
2k
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
750
Designing for Performance
lara
611
70k
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
3
1.1k
Transcript
Firebase Remote Config & Test Lab Rebecca Franks Google Developer
Expert - Android @riggaroo riggaroo.co.za
Who am I?
None
Firebase Product Offering
Firebase Dev Summit 2016 - Berlin • New Analytics Features
- StreamView / DebugView • Crash Reporting is now out of Beta with new features • Udacity Course - Firebase in a weekend • Lots of other small things
Agenda • Remote Config • Setup & Basic Usage •
Conditions • A/B Testing • Staged Rollouts • Custom Analytics Audiences • Test Lab • Robo Tests • Instrumentation Tests
Remote Config
• Key / Value Pairs saved on Firebase server •
Change behaviour at runtime • No app update required Remote Config
Features • Quickly deploy changes • Customise your app for
segments of user base • Run A/B Tests • Free!
Available for Android iOS
Firebase Server Setup
Android Setup Project Level build.gradle: buildscript { // ... dependencies
{ // ... classpath 'com.google.gms:google-services:3.0.0' } }
Android Setup App Level app/build.gradle: dependencies { // ... compile
'com.google.firebase:firebase-core:9.8.0' compile 'com.google.firebase:firebase-config:9.8.0' } // At the bottom apply plugin: 'com.google.gms.google-services'
Android Setup • Download google-services.json • Place in app/ folder.
• Create remote config defaults file - res/xml/ remote_config.xml <?xml version="1.0" encoding="utf-8"?> <defaultsMap> <entry> <key>welcome_message</key> <value>Hello User!</value> </entry> </defaultsMap>
Initialise Firebase Remote Config remoteConfig = FirebaseRemoteConfig.getInstance(); FirebaseRemoteConfigSettings config =
new FirebaseRemoteConfigSettings.Builder() .setDeveloperModeEnabled(BuildConfig.DEBUG) .build(); remoteConfig.setConfigSettings(config); remoteConfig.setDefaults(R.xml.remote_config);
Fetch remoteConfig.fetch(CACHE_TIME_SECONDS).addOnComplete Listener(new OnCompleteListener<Void>() { }); @Override public void onComplete(@NonNull
Task<Void> task) { if (task.isSuccessful()) { Log.d(TAG, "Fetch Succeeded"); remoteConfig.activateFetched(); } else { Log.d(TAG, "Fetch Failed"); } displayWelcomeMessage(); }
Display void displayWelcomeMessage(){ String helloMessage = remoteConfig.getString("welcome_message"); greetingTextView.setText(helloMessage); }
Demo Android app fetching single remote config value
Types you can store on Remote Config • Strings •
Integers • Booleans • Long • Double • Byte Arrays
Conditions • Powerful decision- making server • Target a group
of app instances • Made up of one or more rules that must evaluate to true
Different greeting per platform?
Demo - No code changes!
Types of Conditionals • OS Type • App ID •
Device in Region or Country • App Version • Language • Audience from Analytics • Random Percentile
How does the app decide what value to use? In-app
default value? Static initialised value No No Yes Yes Parameter value Value fetched from the server?
Priority of Conditionals
A/B Testing & Feature Rollout • Experimenting with your UI
• Different audiences receive different UI
A/B Testing - Server Setup
A/B Testing - Android Setup String experiment = config.getString("experiment_variant"); FirebaseAnalytics.getInstance(this)
.setUserProperty("Experiment", experiment); if (experiment.equals("variant_a")) { //.. } else if (experiment.equals("variant_b")) { //... } else { //.. }
Demo A B No Experiment
Analytics Log your events + track in the Firebase Console
buttonCheckout.setOnClickListener(new View.OnClickListener() { @Override public void onClick(final View view) { //.. } }); firebaseAnalytics.logEvent(“CheckoutClicked”, new Bundle());
A/B Testing - Analytics
Filter - Variant_A
OR Export to BigQuery
Experiment A - Winner! A
Gradual Feature Rollouts • Leverage “User in Random Percentile” feature
• Gradually increase the value of the percentage • Rollout to more customers as you gain confidence
Create stage rollout condition
Create config using that condition
Gradually increase value
Custom Audiences - Events
Remote Config using Custom Audience
Unsupported App Versions
Unsupported App Versions
Unsupported App Versions void loadAppSupported() { boolean appSupported = remoteConfig.getBoolean("app_supported");
if (!appSupported) { showAppNotSupportedDialog(); } }
Test Lab
What is Firebase Test Lab? • Run tests at Googles
Device Farm • Virtual Devices + Physical Devices • Robo Tests & Custom Instrumentation Tests • Free Tier • 5 tests per day on physical devices • 10 tests per day on virtual devices • Pay per hour
Runs on Android
Why run tests on Firebase? • History of results •
Logs attached to each test • Screenshots & videos • Don’t have to manage your own device farm
Robo Test • Random clicking around in your application +
recording results • No code changes required to run a Robo Test • Uses Monkey Runner
Running Monkey Locally $ adb shell monkey -p your.package.name -v
500 Command line:
Running Monkey on Firebase
Viewing Robo Test Results
Instrumentation Tests • Need to be writing test code •
Espresso • Robotium • UIAutomator
Run Instrumentation Tests Locally • Device / Emulator attached •
Espresso: ./gradlew connectedAndroidTest
Options for running tests • Firebase Console • Command Line
- Using gcloud API • Android Studio
Running Instrumentation Tests in Android Studio
Viewing Test Results
Recap •Remote Config •Getting setup •Using remote config •A/B Testing
+ Gradual Roll outs •Test Lab •Robo Tests •Instrumentation tests
Thank you! Rebecca Franks Google Developer Expert - Android @riggaroo
/ +RebeccaFranksSA riggaroo.co.za
Links Firebase Remote Config - https://firebase.google.com/docs/remote-config/ Firebase Test Lab -
https://firebase.google.com/docs/test-lab/ Testing Support Library - https://developer.android.com/topic/libraries/ testing-support-library/index.html Demo Remote Config Project - https://github.com/riggaroo/remote-config- demo-ssa-launchpad-2016 Demo Test Lab Project - https://github.com/googlesamples/android- testing/tree/master/ui/uiautomator/BasicSample