$30 off During Our Annual Pro Sale. View Details »

Making our applications greener

Making our applications greener

A talk I gave at Devopsdays Oslo.

We live - and work - in an environmentally unbalanced system. In this talk, I’m hoping to make the audience more aware of the impact IT has on the environment, and leave them with tools that help positively lower this impact.

Did you know that the IT sector is estimated to consume approximately 3.6% - 7% of global electricity, and according to Cisco’s Network Traffic Forecast, we’re anticipating a significant increase in global Internet traffic in the next two years? And that the estimated global energy consumption for data centers and enterprise networks alone was equivalent to about 245 TWh in 2016? That’s more electricity than Spain, Australia or Iran use in a year.

We’ll go through more data on the environmental impact of our IT sector. We’ll use The Green Web Foundation’s “Platforms, Packets, Process” mental model to try to put that data into perspective. Finally, we’ll look at what we can do in our everyday work to make our services environmentally sustainable.

Let’s contribute together towards bringing the balance back.

Marta Paciorkowska

October 23, 2019
Tweet

More Decks by Marta Paciorkowska

Other Decks in Technology

Transcript

  1. Confidential Customized for Lorem Ipsum LLC Version 1.0
    Making our applications
    greener
    Marta Paciorkowska, infrastructure developer @FINN
    @a_meba

    View Slide

  2. Confidential Customized for Lorem Ipsum LLC Version 1.0
    Our plan today
    Personal story
    Global crisis
    Our users
    Mental model
    Platform
    Packets
    Process
    Where to start
    @a_meba

    View Slide

  3. Personal story
    I haven’t always worked in tech.
    Came from environmental activism and struggled to feel relevant.
    Western tech needs more outsiders. ☺
    @a_meba

    View Slide

  4. Global crisis
    @a_meba

    View Slide

  5. Our hands
    aren’t clean
    Global electricity consumption = 21,000 TWh 1 in 2016.
    Est. global energy consumption for data centers & enterprise
    networks alone was 245 TWh in 2016. 1
    ICT networks (phones + computers) add another 220 TWh. 1
    @a_meba
    Norway
    Iran
    IT sector
    USA
    China
    100 200 300 6400 TWh
    400 6300

    4000
    3900
    3800
    … 3700

    View Slide

  6. Let’s simplify it a bit
    (Conservative) assumptions:
    ● The IT sector produces well over 110
    Mt CO
    2
    equivalent every year.1
    ● We can spend 20 years on offsetting a
    year’s emissions.
    ● A tree can absorb ½ ton of CO
    2
    in that
    time.2
    ● we fit 100,000 trees in a km2.
    @a_meba

    View Slide

  7. @a_meba
    = Tokyo (~2,200 km2)

    View Slide

  8. @a_meba
    = 1,000,000 trees
    = Tokyo (~2,200 km2)

    View Slide

  9. @a_meba
    = 1,000,000 trees
    = Tokyo (~2,200 km2)
    x 20 years

    View Slide

  10. @a_meba
    = 1,000,000 trees
    = Tokyo (~2,200 km2)
    x 20 years = 1 year’s
    offset

    View Slide

  11. @a_meba

    View Slide

  12. Our users
    @a_meba

    View Slide

  13. They care
    They want to make better choices and they
    want us to do better
    01 | Organic food market in Poland grew 4x in under 10 yrs 1
    02 | 73% of millennials would pay more for sustainability 2
    03 | ⅓ of consumers prefer sustainable brands 3
    04 | 69% of consumers want transparency 4
    05 | 52% of Norwegians shop for sustainability 5
    @a_meba

    View Slide

  14. We can be in the way
    Do brands make it easier or harder for you to be
    environmentally friendly and ethical in your
    daily life?
    Easier 28%
    Harder 43%
    Don’t know 29%
    @a_meba
    Survey of 1004 respondents in the USA and UK, November 2018 for Futerra by OnePulse 1

    View Slide

  15. High expectations
    @a_meba
    Yes 88%
    No 12%
    Would you like brands to help you be more
    environmentally friendly and ethical in your
    daily life?
    Survey of 1004 respondents in the USA and UK, November 2018 for Futerra by OnePulse 1

    View Slide

  16. Return of investment?
    A habitable planet.
    @a_meba
    @a_meba

    View Slide

  17. Build your
    mental model
    @a_meba

    View Slide

  18. Platform, Packets,
    Process
    A model introduced by The Green Web Foundation 1 that
    helps reason about the environmental impact of your
    infrastructure.
    There are also other models you can use to reason about other
    areas of how your company operates.
    @a_meba

    View Slide

  19. Platform
    Environmental costs of servers and infrastructure used
    to run your application.
    @a_meba

    View Slide

  20. Where you run
    @a_meba

    View Slide

  21. Finn’s story
    Evaluated different cloud providers.
    Made an internal sustainability report. Initiative came from the developers.
    Choose a cloud provider because it fit our use case and was more sustainable.
    @a_meba

    View Slide

  22. Not all cloud providers are the same
    @a_meba
    ● Some create efficient data centers with a
    PUE (Power Usage Effectiveness) way
    over the industry average.1
    ● Some either use renewable energy or
    match actual energy demand with
    carbon-free supply.
    ● Some implement a circular economy and
    reuse server components.
    @a_meba

    View Slide

  23. Not all cloud providers are the same
    ● Some create efficient data centers with a
    PUE (Power Usage Effectiveness) way
    over the industry average.1
    ● Some either use renewable energy or
    match actual energy demand with
    carbon-free supply.
    ● Some implement a circular economy and
    reuse server components.
    @a_meba
    ● Others allegedly drop sustainable goals
    to pursue business with the oil and gas
    industry.
    @a_meba

    View Slide

  24. Carbon neutral
    data centers exist
    Pictured: A carbon-neutral data center in
    Norway. 1
    @a_meba

    View Slide

  25. Can your platform
    be greener?
    Some tips to make it happen
    @a_meba

    View Slide

  26. Can your platform
    be greener?
    ● Choose those cloud regions for
    your infrastructure which are
    powered by renewables. 1
    Some tips to make it happen
    @a_meba

    View Slide

  27. Can your platform
    be greener?
    ● Choose those cloud regions for
    your infrastructure which are
    powered by renewables. 1
    ● Switch to a sustainable cloud
    provider or data center.
    Some tips to make it happen
    @a_meba

    View Slide

  28. Can your platform
    be greener?
    ● Choose those cloud regions for
    your infrastructure which are
    powered by renewables. 1
    ● Switch to a sustainable cloud
    provider or data center.
    ● Avoid over-provisioning servers.
    Some tips to make it happen
    @a_meba

    View Slide

  29. Can your platform
    be greener?
    ● Choose those cloud regions for
    your infrastructure which are
    powered by renewables. 1
    ● Switch to a sustainable cloud
    provider or data center.
    ● Avoid over-provisioning servers.
    ● Periodically audit infrastructure to
    remove unused VMs and services.
    Some tips to make it happen
    @a_meba

    View Slide

  30. How you run it
    @a_meba

    View Slide

  31. We still build infrastructure of
    tomorrow on concepts from
    yesterday.
    @a_meba

    View Slide

  32. @a_meba

    View Slide

  33. @a_meba
    CPU utilization

    View Slide

  34. @a_meba
    CPU utilization
    35%

    View Slide

  35. A waste of capacity
    @a_meba
    We’re literally burning coal when our
    machines are idling.

    View Slide

  36. Servers in US data centers
    10%-30%
    Zombie servers:
    obsolete/unused machines
    that consume electricity but
    aren’t used 1
    @a_meba

    View Slide

  37. Different ways to scale better 1
    @a_meba

    View Slide

  38. How efficient is
    your application?
    Some open questions
    @a_meba

    View Slide

  39. How efficient is
    your application?
    Some open questions
    ● Do you cache everything you could to
    save traffic? (Immutable = cacheable)
    @a_meba

    View Slide

  40. How efficient is
    your application?
    Some open questions
    ● Do you cache everything you could to
    save traffic? (Immutable = cacheable)
    ● Do you optimize your database calls?
    These can get resource-heavy.
    @a_meba

    View Slide

  41. How efficient is
    your application?
    Some open questions
    ● Do you cache everything you could to
    save traffic? (Immutable = cacheable)
    ● Do you optimize your database calls?
    These can get resource-heavy.
    ● Do you (de)serialize data needlessly?
    Should you switch to a binary format
    instead?
    @a_meba

    View Slide

  42. How efficient is
    your application?
    Some open questions
    ● Do you cache everything you could to
    save traffic? (Immutable = cacheable)
    ● Do you optimize your database calls?
    These can get resource-heavy.
    ● Do you (de)serialize data needlessly?
    Should you switch to a binary format
    instead?
    ● JVM? How about GraalVM!
    @a_meba

    View Slide

  43. How efficient is
    your application?
    Some open questions
    ● Do you cache everything you could to
    save traffic? (Immutable = cacheable)
    ● Do you optimize your database calls?
    These can get resource-heavy.
    ● Do you (de)serialize data needlessly?
    Should you switch to a binary format
    instead?
    ● JVM? How about GraalVM!
    ● Are some languages more efficient
    than others (Java vs Go)?
    @a_meba

    View Slide

  44. How efficient is
    your application?
    Some open questions
    ● Do you cache everything you could to
    save traffic? (Immutable = cacheable)
    ● Do you optimize your database calls?
    These can get resource-heavy.
    ● Do you (de)serialize data needlessly?
    Should you switch to a binary format
    instead?
    ● JVM? How about GraalVM!
    ● Are some languages more efficient
    than others (Java vs Go)?
    ● Maybe drop threads and use
    coroutines instead?
    @a_meba

    View Slide

  45. How efficient is
    your application?
    Some open questions
    ● Do you cache everything you could to
    save traffic? (Immutable = cacheable)
    ● Do you optimize your database calls?
    These can get resource-heavy.
    ● Do you (de)serialize data needlessly?
    Should you switch to a binary format
    instead?
    ● JVM? How about GraalVM!
    ● Are some languages more efficient
    than others (Java vs Go)?
    ● Maybe drop threads and use
    coroutines instead?
    ● Smaller. Docker. Images.
    @a_meba

    View Slide

  46. Packets
    Environmental costs of infrastructure other people own.
    @a_meba

    View Slide

  47. It’s not me, it’s you
    Your dependencies also count
    @a_meba

    View Slide

  48. It’s not me, it’s you
    ● Remove unused dependencies.
    Your dependencies also count
    @a_meba

    View Slide

  49. It’s not me, it’s you
    ● Remove unused dependencies.
    ● Assess services like Heroku, Travis,
    Dockerhub, …
    Your dependencies also count
    @a_meba

    View Slide

  50. It’s not me, it’s you
    ● Remove unused dependencies.
    ● Assess services like Heroku, Travis,
    Dockerhub, …
    ● If applicable, switch to GitHub
    Actions because your build runs
    where your code is.
    Your dependencies also count
    @a_meba

    View Slide

  51. It’s not me, it’s you
    ● Remove unused dependencies.
    ● Assess services like Heroku, Travis,
    Dockerhub, …
    ● If applicable, switch to GitHub
    Actions because your build runs
    where your code is.
    ● When choosing new technologies,
    make an environmental
    sustainability assessment of each
    option.
    Your dependencies also count
    @a_meba

    View Slide

  52. Process
    How people work in your organization and how you
    deliver your product to your users.
    @a_meba

    View Slide

  53. Meat is tasty. A future is tastier.
    Travel
    2.88t CO
    2
    Round flight from Oslo to
    Barcelona for KubeCon for
    your DevOps team of 4. 1
    Meat
    5.99t CO
    2
    Saved by providing only
    vegetarian food at a company
    canteen for 200 people in a
    month.2
    Idle resources
    2.2t CO
    2
    Saved by switching off 200
    laptops for the night for a
    month. 3
    @a_meba

    View Slide

  54. A greener office
    A greener application
    @a_meba

    View Slide

  55. A greener office
    ● Public transport tickets for all
    employees.
    ● Safe bike parking on premises.
    ● Promote home office.
    ● Six hour workdays.
    ● Conferences? Accessible by train or
    video stream.
    A greener application
    @a_meba

    View Slide

  56. A greener office
    ● Public transport tickets for all
    employees.
    ● Safe bike parking on premises.
    ● Promote home office.
    ● Six hour workdays.
    ● Conferences? Accessible by train or
    video stream.
    ● Update your company’s device policy
    to exchange equipment less often.
    ● Turn off screens, lights & computers
    for the night.
    A greener application
    @a_meba

    View Slide

  57. Where to start
    @a_meba

    View Slide

  58. ClimateAction.Tech recommends: 1
    0
    1
    Sustainability statement
    Creates a feeling of shared
    purpose.
    0
    2
    Gather data & ideas
    Stick to same methodology
    throughout whole process.
    0
    3
    Appoint a task force
    Remove obstacles, keep
    momentum going.
    @a_meba

    View Slide

  59. Find allies in your
    company
    Example: We have a weekly Academy at
    Finn, where we have talks, brainstorm.
    I held an Academy and asked colleagues
    about their ideas. I used some of them
    here.
    @a_meba

    View Slide

  60. Turn off Finn.no from
    01:00-05:00
    @a_meba

    View Slide

  61. Don’t give up

    View Slide

  62. Resources
    To help you get started
    ● ClimateAction.Tech slack
    ● Green Web Foundation’s website
    ● This article that outlines a good
    process
    ● A short summary of
    environmental sustainability of
    cloud providers
    ● Greenpeace’s Click Clean reports
    @a_meba

    View Slide

  63. Get to work
    @a_meba

    View Slide

  64. In times of crisis, we need to be
    efficient, resourceful, and caring
    about each other.
    @a_meba
    @a_meba

    View Slide

  65. Thank you!
    Marta Paciorkowska
    Office hours @ FInn’s stand: 13-14
    @a_meba
    thatmarta.wordpress.com
    @a_meba

    View Slide

  66. Confidential Customized for Lorem Ipsum LLC Version 1.0
    Credits
    Images on slides 1, 3, 4, 12, 14, 15,
    17, 18, 21, 51, 57, 59, 60, 63, 65:
    Marta Paciorkowska
    Images on slides 13, 35, 58:
    Rawpixel.com
    Image on slide 24:
    Volkswagen
    @a_meba
    Image on slide 61:
    Finn.no AS
    Images on slide 37:
    The Green Web Foundation
    A huge thank you to Kim Tore Jensen,
    Magdalena Kowalczyk and Chris Adams.

    View Slide