- click to watch demo
- This APP demonstrates Big Active Data (BAD) concept by utilizing the continuous query and data ingestion capabilities of Asterix DB.
- It offers a notification service to users when their Twitter friends are nearby so they can meet at a nearby coffee shop.Users can subscribe to a channel created by Broker (i.e. Followers/Followees). When followers or followees are approaching a user’s location, Broker sends a notification to users and displays them on the mobile map. The application also marks the coffee shops (Starbucks) nearby. Thus, users can send a message through the application and invite friends to meet at a coffee shop.
AsterixDB Click to Download
Broker Click to Download
- BADBroker.py: If broker is deployed in local computer, the brokerIPAddr and brokerPort should be "localhost" and "8989"
- BADWebServer.py: The application should listen to the same port that set in BADBroker.py
- notifier/android.py: Get gcmRegistrationTokenTutorial and gcmAuthorizationKey from firebase console Tutorial.
- Register application using ddl scripts in "localhost:8989". The dataverse name should be "Starbucks".
- Create a developer account in twitter developer console
- Save the timeline tweets in local file using following commend: Timeline API Tutorial
twurl /1.1/statuses/home_timeline.json?count=1 > tweets.json
- Make sure that the file name is the same with the one in socket adapter(ddl).
- Running ddl in AsterixDB console to get tweets automatically.
Modify related tokens and keys in strings.xml
- ChannelsActivity.java & ChannelsAdapter: subscribe & unsubscribe
- FollowersActivity.java & FollowersAdapter: show all the followers
- LoginActivity.java: register and login
- MapsActivity.java: show current location
- MyFirebaseMessagingService: get message from server using firebase service
- OKHttpUtil.java: containing broker functions
- ShowInfo.java: show friends'location on map
Currently the location of friends' is showed after user clicks on the notification. An improvement is to show the real-time location of friends on the homepage map.