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

Perl in Japan

Avatar for papix papix
August 07, 2019

Perl in Japan

Avatar for papix

papix

August 07, 2019
Tweet

More Decks by papix

Other Decks in Technology

Transcript

  1. Self Introduction • Takayuki Fukumoto a.k.a papix • https://papix.net •

    CPAN: https://metacpan.org/author/PAPIX • Board member of Japan Perl Association • Vice chairman of next YAPC::Japan • Attended YAPC::EU 2015 (Granada)
  2. Perl in Japan: Agenda • Introduce 2 topics about "Perl

    in Japan" • Web Service Development • Community
  3. Current status of Perl in Japan • About 10 years

    ago, Perl was very popular programming language in Japan • Some large SNS / portal service were using Perl: Livedoor, DeNA and mixi • Many study sessions were held • JPA established in 2008
  4. Current status of Perl in Japan • In 2019, Perl

    is not popular in Japan as a language for web service development • Around 2010, several WAF became popular in Japan • Rails 3, CakePHP 2.0, Symphony 2.0 etc. • Many engineer want to use these WAF
  5. Current status of Perl in Japan • Now, many engineers

    use Ruby (RoR), PHP, Go, Python, Scala etc. • Static typing language is very popular in Japan • And many Perl code was replaced other language
  6. But... • We are using Perl! • JPA is still

    active • My company is one of them • In this section, I'd like to talk about some techniques when we use Perl • Architecture, CPAN modules, tools...
  7. And... • I don't know much about the Perl outside

    Japan. • I want to discuss with you! • common / different point with us...
  8. Hatena Co., Ltd. • Founded in 2001 • "Hatena" means

    "?" in Japanese • Located in Kyoto and Tokyo • Developing many web services using Perl and other languages • For example...
  9. Hatena Bookmark • Social bookmarking platform in Japan • Similar

    to Reddit, Hacker News, delicious... • Replaced from Perl to hybrid of Scala & Perl • see also: How we replaced a 10-year-old Perl product using Scala
 https://speakerdeck.com/tanishiking/how-we-replaced-a-10-year-old-perl-product-using-scala
  10. Mackerel • Server monitoring and management SaaS • https://mackerel.io •

    Replacement for Zabbix, Nagios... • Using Scala and Go
  11. Hatena Blog • Self-publishing blog service in Japan • Similar

    to WordPress, Tumblr, Medium... • Released in 2011 • Small developer team • 5 engineers, 2 designers, 1 SRE
  12. Hatena Blog: Technology stack • Perl • (some subcomponents use

    Go/Scala) • JavaScript / TypeScript • React.js... • MySQL, Redis, Memcache / Nginx, Varnish • Some AWS's service • GitHub, Slack, Mackerel, Sentry, Jenkins, etc...
  13. Hatena Blog: Code • Perl ... About 130,000 lines •

    Test code ... 20,000 lines • JavaScript ... About 43,000 lines
  14. Hatena Blog: Our Philosophy of Code • "Minimize the code

    to read by developer" • So, we don't use existing WAF! • like Mojolicious, Amon2... • Build tiny WAF using several CPAN modules: • Plack + Router::Simple... • Text::Xslate, JSON::XS...
  15. Hatena Blog: Our Philosophy of Code • In addition, we

    don't use convenient ORM • like DBIx::Class, Class::DBI... • We use DBIx::Sunny (simple DBI wrapper) • see also: Strongest Web Service Framework I Thought
 https://www.slideshare.net/cho45/yapc-asia-2011 (Japanese)
  16. AWS X-Ray • Analyze and debug production • Tracing our

    web service and show details: • Time taken to process • Show external HTTP request • SQL query / fetched row
  17. AWS X-Ray + Perl • FUJIWARA did it!!!!!! • Devel::KYTProf

    • Devel::KYTProf::Logger::XRay • AWS::XRay • Plack::Middleware::XRay
  18. Devel::KYTProf • Lightweight profiler for Perl • author: ONISHI •

    KYT means "Kyoto" • (because he lives in Kyoto)
  19. Devel::KYTProf • Usage is very simple! • Just use "Devel::KYTProf"

    on your code • Then... • ↑ Furl's profile by Devel::KYTProf
  20. Devel::KYTProf • Devel::KYTProf supports for... • Cache::Memcached::Fast • DBI •

    LWP::UserAgent • Furl::HTTP • MogileFS::Client • Redis::Fast • Fluent::Logger • AWS::CLIWrapper
  21. AWS::XRay • AWS::XRay is AWS X-Ray SDK for Perl •

    author: FUJIWARA • Simple SDK, don't profiling
  22. App::PRT • Command line Perl Refactoring Tool • author: HITODE

    • Replace any package, subroutine, variable name • using PPI
  23. CPANܑ͞Μ • ňCPANܑ͞Μʼn means "Super CPAN Bros." • Display CPAN

    modules needing update • Implemented by Ruby
  24. And Others... • We use many CPAN modules... • Sentry::Raven

    • Class::Accessor::Lite::Lazy • LWPx::ParanoidHandler • Class::Enumemon
  25. Perl Community in Japan • As above, Perl is not

    popular language in Japan • However, some people still use and enjoy using Perl! • I'd like to talk about approach to support Perl Mongers in Japan
  26. Japan Perl Association (JPA) • JPA is a Perl user

    group in Japan • Some companies are participating in JPA • And they are nominates board member • Board member operate JPA • Funds are supported from sponsors
  27. Japan Perl Association (JPA) • Our mission is... • Operate

    YAPC::Japan (Conference) • Support local communities
  28. YAPC::Japan • Conference on Perl in Japan • Until 2015,

    JPA operated YAPC::Asia • In 2016, rebooted as YAPC::Japan • YAPC::Japan is operated by JPA and some volunteer staff
  29. YAPC::Japan • Held in some cities: • YAPC::Hokkaido 2016 Sapporo

    • YAPC::Kansai 2017 Osaka • YAPC::Fukuoka 2017 Hakata • YAPC::Okinawa 2017 Onnason • YAPC::Tokyo 2018
  30. YAPC::Japan • YAPC::Japan is small conference • 1-2 times in

    a year, 1 conference = 1.5 days • About 150-200 attendees, 20-30 speakers
  31. YAPC::Japan • JPA and sponsors support students • We provide

    some costs of attending • We want them to know Perl and learn a lot!!!
  32. YAPC::Japan • In YAPC::Japan, we talk about various topics •

    YAPC::Japan is conference of Perl and some topics related to Perl • For example, infrastructure, team management, security, education...
  33. YAPC::Japan • Of course, there are many advanced talks about

    Perl!!! • Takahiro Shimizu's "How to build traditional Perl interpreters" is one of them • This is spoken at YAPC::Tokyo 2019
  34. Local Communities • There are some pm in Japan •

    Hokkaido.pm, Shibuya.pm, Kichijoji.pm, Kansai.pm, Fukuoka.pm, Okinawa.pm... • JPA supports these communities • Detach a famous Perl Monger to study session • Support operational cost
  35. Perl Entrance • Introductory class for Perl • Teach Perl

    to inexperienced people • JPA supports this community • I spoke in YAPC::EU 2015
 https://speakerdeck.com/papix/teaching-and-learning-perl
  36. Conclusion • I talked about current status of Perl in

    Japan • Web service developing and Community • I'm grad if our knowledge is helpful for you • I think we have many things in common and differences • I'd like to interact with you about them!