Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Technologies that support the distribution of L...

Technologies that support the distribution of LINE NEWS articles

Daiki Inaba
LINE Development Team I Software engineer
https://linedevday.linecorp.com/jp/2019/sessions/C1-3

LINE DevDay 2019

November 20, 2019
Tweet

More Decks by LINE DevDay 2019

Other Decks in Technology

Transcript

  1. 2019 DevDay Technologies That Support the Distribution of LINE NEWS

    Articles > Daiki Inaba > LINE Development Team I Software engineer
  2. Agenda > Overview of LINE NEWS > Personalized Recommendation Architecture

    • How To Process User Request • How To Import Recommendations
  3. How Much Traffic Req / Day 17.3B Req / Sec

    - Avg 200K Req / Sec - Peak 375K
  4. DB Server Infrastructure MongoDB × 21 MySQL × 3 Cache

    Server Redis Sentinel × 3 Memcached × 44 Redis Cluster × 1
  5. > Generated by Machine Learning Team called as Data Labs

    > Provided as files • Contain recommendations for 100 million users in all • Each recommendations contain 200 article • Updated hourly Machine Learning Recommendation
  6. > Generated by Machine Learning Team called as Data Labs

    > Provided as files • Contain recommendations for 100 million users in all • Each recommendations contain 200 article • Updated hourly Machine Learning Recommendation
  7. > Set by operators • Targets are specified by many

    attributes • Age, Gender, Residence, and more… > Can be set in parallel > Reservable > Mixed in ML recommendations at specified position Manual Recommendation
  8. > Set by operators • Targets are specified by many

    attributes • Age, Gender, Residence, and more… > Can be set in parallel > Reservable > Mixed in ML recommendations at specified position Manual Recommendation
  9. Request Process > Actually, processing personalized request is not so

    difficult > Issues are in the process of importing recommendations
  10. API Datahub LIMIT : 100 OFFSET : 0 LIMIT :

    100 OFFSET : 100 LIMIT : 100 OFFSET : 200 ML Importer 1 ML Importer 2 ML Importer 3
  11. API Datahub LIMIT : 100 OFFSET : 0 LIMIT :

    100 OFFSET : 100 LIMIT : 100 OFFSET : 200 Import ML Importer 1 ML Importer 2 ML Importer 3
  12. > Set by operators • Targets are specified by many

    attributes • Age, Gender, Residence, and more… > Can be set in parallel > Reservable > Mixed in ML recommendations at specified position Manual Recommendation
  13. 1st Approach > Import target user ids as CSV that

    extracted by operator in advance
  14. What Is Central Dogma? > Highly-available version-controlled service configuration repository

    > Store your configuration files such as .json, .yaml and .xml into a centralized > Let your servers get notified immediately when the configuration files are updated and the new settings are applied without server restarts
  15. Datalake Batch CMS Data Analyst Central Dogma Redis MySQL User

    Ids CSV Store Mapping Data Upload Article Data Operator
  16. article_id_1 SET(user_id, user_id_1, user_id, …) article_id_2 SET(user_id, user_id, user_id, …)

    article_id_3 SET(user_id_1, user_id, user_id, …) article_id_4 SET(user_id_1, user_id, user_id, …) article_id_5 SET(user_id, user_id, user_id, …)
  17. article_id_1 SET(user_id, user_id_1, user_id, …) article_id_2 SET(user_id, user_id, user_id, …)

    article_id_3 SET(user_id_1, user_id, user_id, …) article_id_4 SET(user_id_1, user_id, user_id, …) article_id_5 SET(user_id, user_id, user_id, …) SISMEMBER (article_id_n, user_id_1)
  18. article_id_1 SET(user_id, user_id_1, user_id, …) article_id_2 SET(user_id, user_id, user_id, …)

    article_id_3 SET(user_id_1, user_id, user_id, …) article_id_4 SET(user_id_1, user_id, user_id, …) article_id_5 SET(user_id, user_id, user_id, …) SISMEMBER (article_id_n, user_id_1)
  19. 2nd Approach > Less scalability due mapping data structure •

    Change mapping data structure > Too high operating cost • Enable to extract target user ids via CMS
  20. article_id_1 SET(user_id, user_id_1, user_id, …) article_id_2 SET(user_id, user_id, user_id, …)

    article_id_3 SET(user_id_1, user_id, user_id, …) article_id_4 SET(user_id_1, user_id, user_id, …) article_id_5 SET(user_id, user_id, user_id, …) SISMEMBER (article_id_n, user_id_1)
  21. article_id_5 for user_id_3 user_id_4 user_id_5 article_id_1 SET(user_id, user_id_, user_id, …)

    article_id_2 SET(user_id, user_id, user_id, …) article_id_3 SET(user_id, user_id, user_id, …) article_id_4 SET(user_id, user_id, user_id, …)
  22. article_id_5 for user_id_3 user_id_4 user_id_5 article_id_1 SET(user_id, user_id_, user_id, …)

    article_id_2 SET(user_id, user_id, user_id, …) article_id_3 SET(user_id, user_id, user_id, …) article_id_4 SET(user_id, user_id, user_id, …) article_id_5 SET(user_id_1, user_id_2, user_id_3)
  23. article_id_5 for user_id_3 user_id_4 user_id_5 user_id_1 SET(article_id, article_id) user_id_2 SET(article_id,

    article_id) user_id_3 SET(article_id, article_id) user_id_4 SET(article_id, article_id)
  24. article_id_5 for user_id_3 user_id_4 user_id_5 user_id_5 SET(article_id_5) user_id_1 SET(article_id, article_id)

    user_id_2 SET(article_id, article_id) user_id_3 SET(article_id, article_id) user_id_4 SET(article_id, article_id)
  25. article_id_5 for user_id_3 user_id_4 user_id_5 user_id_1 SET(article_id, article_id) user_id_2 SET(article_id,

    article_id) user_id_3 SET(article_id, article_id, article_id_5) user_id_4 SET(article_id, article_id, article_id_5) user_id_5 SET(article_id_5)
  26. Conclusion > Focused on delivering recommendation • Machine Learning &

    Manual • Request & Import Process > But we are delivering many other kinds of contents • So…