4. Objective
§ Critical part of LinkedIn’s multi-app mobile strategy
§ Promote healthy growth of the overall ecosystem
§ Provide a scalable framework to facilitate the initiative
9. Problem Statement
§ Multiple integration points on both clients and server
§ Promo assets management logic duplicated across all
front-end services
§ If we want to show cross promotions in N applications
with M targeted screens from each application, the
required effort is: above change * N * M
Neither cost-effective nor scalable!
11. Cross Promo Framework Overview
§ Fully integrated with Lego framework to server
promo to the right users at the right context and right
time
§ Provide persistent layer to host all promo related
assets such as text, images and action payload
§ Handles uploading images to CDN and text
translation to all standard languages supported by
LinkedIn
§ Support A/B testing on asset variation as well as view
templates variation
14. Lego
Decides which widget or flow of widgets
to show in slot for a given user.
§ Code-less Configuration
§ Impression & click events built in
§ Lix Integration
15. Lego is not...
...Cross Promo Framework is
§ UI Renderer
§ Client Libs
§ Data Provider
§ Images
§ Text
§ Action Payload
§ Data Blender
§ A/B Testing
21. Cross Promo Framework Component
Cross promo client side library - overview
§ Hosting app can query the framework for an available
promo via the library
§ App must provide a page key and member id
§ A self contained view that can
§ Render the promotion UI (small icon, background image,
promotion text, detail text)
§ Execute the promotion flow (open app store download link, or
open the app via deep linking if it is installed on device)
§ Initiate Lego impression event when view is displayed
§ Initiate Lego action event when view is clicked
22. Cross Promo Framework Component
Cross promo client side library - detail
§ Caching Mechanics
§ Fetches promo asynchronously, and caches.
§ Displays cached promos to avoid async rendering.
§ Supports Sync Rendering (server flag)
§ Rich text support for colors and fonts
§ Provides hook for app custom metric firing
§ Generated Models with Pegasus (true JSON)
§ Sample Apps
§ Wake cool-off script
§ Unit Tests
23. iOS Cross Promotion Library Integration
§ Installation: ‘pod install ios-crosspromo’
§ App provides a page key, a networking layer, and an async
image renderer
§ App is given a generic UIView object, which it can display in
whatever way it wants
§ The primary API:
§ [[LICrossPromo sharedManager]
viewForPageKey:withDelegate]
§ [[LICrossPromo sharedManager] userDidSeePromo:]
§ Library provides callbacks for
§ Handling fetch failures
§ Firing additional action metrics
24.
25. iOS Cross Promotion Library Deep Dive
§ Implements most of the behavior with static/class
methods to minimize side effects
§ Library plugs into existing apps by leveraging protocols
§ Uses NSCache for all caching
§ Uses Xibs for easy onboarding, modifications, and
enhancement
26. Android Cross Promotion Library Integration
§ App provides a unique pageKey, reference to view
container, and reference to CookieStore.
§ App initialize a CrossPromoManager.
§ App calls CrossPromoManager’s API:
§ addPromo()
§ clearPromoView()
§ Optional: Add metric listener to fire app specific metrics.
27.
28. Android Cross Promotion Library Deep Dive
§ Great Documentation (Javadocs, ReadMe, @Nullable
Annotation)
§ Out of the box NetworkClient (optional swap in
NetworkClient)
§ Supports 3 formats:
§ Return a crosspromo view
§ Manage a crosspromo view in a viewgroup
§ Manage a crosspromo view in a listview
30. How to Create a New Promo
§ Configure Lego Widget
§ Create Lego Widget
§ Set Widget Lix
§ Add Promo Asset (use scripts provided by framework)
§ Upload Images to CDN
§ Create Your text Copy
§ Upload Asset JSON to Espresso Store
31. Q & A
Full documentation can be found at: go/mxpromo