Skip to content

Instantly share code, notes, and snippets.

View asachdeva's full-sized avatar

Akshay Sachdeva asachdeva

View GitHub Profile
@asachdeva
asachdeva / gist:60558bb46179d0cc858e631f73d0ad0a
Created March 4, 2022 22:00
Migrate Data from cosmos-dev to cosmos-prod
Request: Move VendorLink ccc40b92-3894-4b30-9515-37116d018136 from +18002221111(dev) to +13238419525(prod) and the CD 'Custom dash test'
Steps:
1] Extract group_id for user with phone_number of +13238419525 in prod
Log on to Prod instance in a terminal on root of lanely repo:
./bin/prod_db
Run the query select a.default_group_id from "account" a left join "user" u on u.id = a.user_id where u.phone_number='+13238419525';
2] Extract the data to ingest into Prod as CSV's
Log on to Dev instance in a terminal on root of lanely repo:
@asachdeva
asachdeva / VendorLink from Prod to Dev and delete
Last active September 29, 2021 12:12
Import Vendor Links From Prod to Dev Account
@asachdeva
asachdeva / SSC-Take Home
Last active January 22, 2021 01:15
SSC-Take Home Exercise
Programming Assignment:
The Twitter Streaming API provides real-time access to public tweets.
In this assignment you will build an application that connects to the Streaming API and processes
incoming tweets to compute various statistics.
We'd like to see this as a Scala project, but otherwise feel free to use any libraries you want to
accomplish this task. The sample endpoint provides a random sample of approximately 1% of the full tweet stream.
Your app should consume this sample stream and keep track of the following:
1] Total number of tweets received
2] Average tweets per hour/minute/second
3] Top emojis in tweets
@asachdeva
asachdeva / SSC - Take Home Exercise
Created January 22, 2021 01:03
Take home exercise
Programming Assignment:The Twitter Streaming API provides real-time access to public tweets. In this assignment you will build an application that connects to the Streaming API and processes incoming tweets to compute various statistics. We'd like to see this as a Scala project, but otherwise feel free to use any libraries you want to accomplish this task.The sample endpoint provides a random sample of approximately 1% of the full tweet stream. Your app should consume this sample stream and keep track of the following:
Total number of tweets received
Average tweets per hour/minute/second
Top emojis in tweets
Percent of tweets that contains emojis
Top hashtags
Percent of tweets that contain a url
Percent of tweets that contain a photo url (pic.twitter.com or instagram)
Top domains of urls in tweets
The emoji-data project provides a convenient emoji.json file that you can use to determine which emoji unicode characters to look for in the tweet text.Your app should also provide some way to report these values to