What can a software engineer do about climate change?

Automatic Summary

Green Software Engineering: How Software Engineers can Impact Climate Change

Welcome to this comprehensive guide on what software engineers can do about climate change. In this article, we will cover the principles of green software engineering, showcase the journey of a fellow engineer towards eco-friendliness, and discuss available resources for both front end and back end engineers. We will conclude with some questions from readers to further enlighten you on this topic.

Understanding the Concept of Green Software Engineering

For many, climate change might seem like a distant reality, unrelated to our daily activities as software engineers. Thus, the main task here is understanding exactly how a software engineer can affect climate change positively. This is where Green Software Engineering (GSE) finds its application.

GSE is an emerging discipline at the intersection of climate science, software practices and architecture, electricity markets, and hardware and data center design. The concept of GSE embodies several key principles, among these are:

  1. Carbon efficiency: Building applications that emit less greenhouse gasses, thus helping the globe to stabilize temperature increase, and ultimately achieve net-zero emissions;
  2. Energy efficiency: Creating applications that consume less energy or electricity leading to lower energy consumption;
  3. Carbon intensity: Measuring the amount of carbon emissions produced per kilowatt of electricity consumed, and making strategic choices that reduce this intensity;
  4. Embodied carbon: Acknowledging the amount of carbon pollution produced during the creation and disposal of a device and making efforts to reduce this pollution by writing software that runs optimally on older hardware.

Applying Green Software Engineering Principles

Having understood the principles of GSE, the next question would often be, "Where do I start?" For most, the journey towards becoming a green software engineer starts from a place of inspiration; utilizing their skills to have a real impact in tackling climate change. It usually evolves through phases of research, connecting with like-minded individuals, and becoming part of an eco-conscious community like Climate Action Tech.

Also, increasingly, software engineers are seeing the need for GSE application within their workplaces. Thus, creating initiatives that aim at building more environmentally friendly practices on the job.

Resources for Front-end and Back-end Engineers

There are several resources available for engineers who intend to incorporate GSE principles in their work. For instance, there is the book Sustainable Web Design for designers, which advocates for designs that prioritize people and planet first.

Additionally, for backend engineers, there are studies and tips on how to write green software, and also open source tools that estimate the carbon emission of your workload.

The Additional Advantages for Going Green

Aside from the significant impact on the global climate, applying GSE principles also implies building applications that are more resilient and performant. And as resilient and performant software usually equates to lower costs, it turns out greener is also smarter economically.

Conclusively,

As software engineers, we all have a role to play in tackling climate change. Applying GSE principles in our work is not just a step towards saving the planet, but also towards building more resilient, efficient, and cost-effective software.


Video Transcription

Hello, everyone. Welcome to this presentation. I'm really excited to be here and it's great to see. So many of you have decided to spend the next 20 minutes with me to learn more about what can a software engineer do about climate change?So what we are going to cover today? Firstly, we will learn the principles of green soft engineering. Next, I will share my journey so far as a green soft engineer demonstrating that software engineers can help accelerate the climate actions. Then we will go over resources that I have organized for front end and back end engineers respectively. Hopefully those resources can be a nice kickstart to your strategies to join the fight against climate change. I have set aside the last five minutes of this presentation for Q and A. So please save all your questions to this that towards the end where you can use the chat function provided by hopping to type in your questions. Thanks Fiona for a lovely introduction. But let me just quickly introduce myself again. A little bit about myself. My name is Sarah Sue. I'm a site reliability engineer with Goldman Sachs specializing in Amazon Web services. And currently I'm supporting our consumer car businesses. I'm also a volunteer with climate action tech, climate action.

Tech is a very vibrant online community for any tech workers who are passionate about climate change. If you have any additional questions after the session, please do reach out to me directly using my email or you can connect with me on linkedin. Normally, when you read about climate change in the news, you see forest fire, you see drought, you see polar bears standing over, ever decreasing, melting ice cap. All these events are very scary and they are a great reminder for us all on how desperate the situation is. But they all seem very far from what we do day to day as software engineer. Guess that brings us to why we are here today. What exactly can a soft engineer do about climate change? Let me le let me quickly set the thing and how the software is actually heating the world. This is actually a really interesting series of blog posts called developers can save the planet. I do encourage you to check out the whole thing. But long story short, in the first part, the author estimated that a typical French person would estimate would emit about 14.5 kg of carbon per day and 580 g of those emissions come from digital activity. And about 55% of the digital emissions come from software with almost everything requires a software from pregnancy test to self driving cars. Software is not just helping the world progress, it's also heating the world.

So what we do day to day, a software engineer can have a real impact on the global effort to decarbonize if we can adapt to build Softwares that are sustainable. But what do we mean by building sustainable software up till recently? There's no industry wide agreed definition on what GSE should entail. A lot of research has been done in a space but people started to notice everyone has slight different definitions when it comes to calling something green in a software engineering context. So last year, a group of people from the Mozilla Foundation and Microsoft, they came together and gave GSE the following definition green software engineering is an emerging discipline at the intersection of climate science, software practices and architecture, electricity markets, hardware and data center. Sign.

The first principle of GSE is all about carbon and how building carbon efficient applications can have a real impact. Carbon is a shortened way to describe all greenhouse gasses. Greenhouse gasses are gasses in earth's atmosphere that trap heat. They let the sunlight pass through the atmosphere but they prevent the heat that the sunlight brings from leaving. So essentially greenhouse gasses as, as a blanket, increasing the temperature on the surface of the earth. Do you remember that this is a natural phenomenon? But due to the crazy amount of human made carbon pollution, the global climate is changing at a rate that is too fast for us, human animals or plants to adapt. So, the goal of the Paris Climate Agreement is to reduce carbon pollution. Solar temperature increase, stabilizes to 1.5 °C by 2100. And the temperature increase is dependent on the total amount of carbon we have in the atmosphere, not the rate at which we're emitting the carbon. So to completely hope the rate of temperature increase, we need to stop adding carbon in the atmosphere or achieve something that's called the net zero emissions. Net zero just means for every grain of carbon we add to the atmosphere, we have to take it away. So the overall mass of the carbon remains fixed. The second principle is about electricity. How building applications that are energy efficient can help us reduce our energy consumption slash and electricity consumption. The third principle is about carbon intensity.

The carbon intensity of electricity is a measure of how much carbon emissions are produced per kilowatt of electricity consumes. Now all electricity are produced the same way. Some are some are produced by burning of fossil fuels. And we consider those electricity dirty and some others are produced by renewable sources such as window solar and we consider those clean. So if I plug my laptop directly into wind farm, then a then a carbon intensity electricity that my laptop consumes would have a carbon intensity zero but none of us can really plug anything directly into wind farms. Instead we use power grids. Those power grids are normally supplied with electricity from a mix of sources. And because of the varying nature of renewable sources, the carbon intensity of electricity changes by location and changes over time. So if we can be flexible with when and where we consume electricity, we can then choose to run our workload when the carbon intensity is less. For example, I can choose to host a Bitcoin at a location that has zero carbon intensity. Or if I have daily. If I have a batch job that needs to run once a day, why don't we look for a time frame that is the least carbon intense.

The fourth principle is the embodied carbon, embodied carbon is the amount of carbon pollution produced during the creation and disposal of a device. But why do we care? We're not hardware engineers. Almost everyone's first thought when the application is laggy is I should probably get a new phone.

The average lifespan of mobile phone is estimated at two years. It's not even just the mobile phone, it's the hardware in or, or, or our laptops as developers. We can make sure that the applications we've built can run smoothly on older hardware. Here are all the eight principles.

I do encourage you to go check them out and familiarize yourself with them because by understanding those eight principles, we are in a great position to define build and run green software, right? So if I can make a tiny guess on what you're thinking right now, are you thinking? Wow, I did not realize soft engineers can have a real impact when it comes to addressing climate crisis or are you also thinking? Ok, what now I know about the principles. They're all well and good. But what can I do? And where can I start? Don't worry, I got you. I was feeling and thinking exactly the same, same time last year, I was inspired by this one sentence in a podcast. This podcast is not even about green. It, it was about cloud monitoring. The founder of this cloud monitoring made a career transition from security. And while he was discussing the transition with the host, he said something along the line that how he can now how he can now use his expertise to have a real impact tackling climate change. This one sentence really resonated with me. I've always tried to do better when it comes to being more environmental friendly, but there's just so much I can do by giving by grieving my friends or family when I see them use plus bottles.

So now I want to share my journey with you, what I have done internally and externally and hopefully low actions can inspire you to start your own journey as a green software engineer. So the first thing I did after the podcast was to hit the internet. I wanted to see what has been done in a space. We are all soft engineers. We don't like reinventing the wheels. Then I found green soft engineering as a discipline which led me to climate action tech. Again, it is a very vibrant online community for any type of tech workers who are passionate by utilizing their technical skills to address the climate crisis. Since joining, I've started volunteering right now. I'm helping out new members to on board and make sure they are settled in.

And most importantly is to make sure that the new members are connected with others whom they share common goals of interests. I really love the community's energy and the variety of topics that it covers. And every time I have a question is always responded quickly and with very useful information, even though my volunteering responsibility right now doesn't cover any actual technical work. But I do feel like I'm having an impact in the space. The community is also very open to new ideas.

And right now, we have kick start a new proposal which I hope will massively help others who are in the same boat as me. We are finding the right project with the right tech start in the correct time zone is really tricky. Nowadays, with everything online with 100 different open source projects you can get involved with. And last point I want to make is that green software engineering is not necessarily a new discipline, but a discipline that has gained a lot of traction lately due to the current climate crisis.

So a lot of people aren't aware of this topic, not realizing how much an impact our daily activities of software engineers can have. So earlier this year, I put together a deck a very similar to this one. And I started talking about this topic to basically any engineers who was spare in two minutes. What about what I did internally at my company? Very similar to what I have done externally, I started by giving talks to engineers in my region. Then I found a group of like-minded engineers. And now we have a working group on green software engineering. Again, what we realized this discipline is not very well known. So we have a shared deck that we use whenever an opportunity should arise for us to raise awareness. The working group has now grown to a healthy size that we are capable of running multiple initiatives concurrently. So what about you? What can you do next before we jump into the resources for front end and back engineers? I just want to reiterate that volunteering is a worthwhile contribution in this space. And I do encourage you to find a topic that you're most interested in. It's a shame that we're not in person. And I can't, I can't ask you to raise your hands and see how many of you are fronting engineers because you guys are a very lucky bunch. The work that has been done in space is very impressive and they're all readily available online.

For example, if you're a designer, there's a book called Sustainable Web Design. The book describes an approach to designing digital products and service that puts the people and planet first. The author of this book is also the founder of a booty war press firm in London and I have met a head start in a green space. They are regularly published blog posts. For example, the one you see on the slide 17 ways to make your website more energy efficient. They've also built a calculator that estimate the amount of carbon your website would have emitted per year. And here, I've tested out the BBC news homepage and turns out it's not a very green site. The amount of carbon emission estimated is roughly equal to what 14 trees would have absorbed in one year alone. And if you are a mobile developer, building a progressive web app is not just making your application more efficient and how you can reach more audience. All the benefits that come with building a PW A have a growing aspect to them as well. And if you are back an engineer, there are also loads of work being done in the space, not as much as the front end, but just enough to get you started.

There's a very interesting study done back in 2018 where the benchmark tested different programming languages and they provided a useful table for you to consider which one to pick based on optimal sets. For example, C pascal and grow are the top choice if your optimal objectives are time and memory. Microsoft is also leading a pack here where they have started a blog post, sharing tips and tricks on how to write, bring software. And this particular one I've shared demonstrate how you can measure power consumption of your backend services. And lastly, there's now this open source tool available. If you host your solution with any of the following cloud providers, AWS A X or GCP. This is a really, really nice tool that uses the out of the box API S provided by each cloud provider to estimate the carbon emission of your workload. But what about SRE and de space right now, there's not a lot being done in the space. We are in a phase where applying green soft engineering principles is going to start make ways across the tech world. And how would those affect the way we support? For example, a four night service, is it possible for us to do monitoring based on demand instead of having a prometheus cluster running 24 7? Right before we start the Q and A, I want to quickly talk about the additional advantages for growing green.

We're not just building applications that emit less carbon, we're also building applications that are more resilient and performant. And when a piece of software is more resilient and performant, it normally costs less too. So I guess that brings us to our last light. I hope you have enjoyed this talk and the talk has inspired you to kickstart your GSE journey. Remember it's Earth day, every day the planet is in desperate need of help from anyone and everyone. Thanks guys. Right. Let me just go to the chat function. Um uh Can we get, well, I will reach out to the organizer and see how I can share the slides. Yeah, I actually do have another slide. Um But I don't really want to make this session too preachy, but let me just quickly share that with you. So um basically, there are some habits we do when we are tech users. For example, when you stop using your computers, you can try to switch it off, we can then save energy and electricity. And if you're watching Netflix, if you have the opportunity to download and not stream, that can also save a lot of like electricity. And again, we're all software engineers, dark mode is saving us so much energy. So change your ID to dark mode and Zoom meetings. I know like this has been a crazy year where Zoom has transformed the way that we have experienced Corona if we're in a different, I mean decade.

And so um if you are in a Zoom meeting for 100 other people, we're sharing your face is really not that important. You can try turning it off. I think there was a study that basically if you turn your camera off during a zoom meeting, you can reduce about 87% of the carbon emitted. If you have your camera on again, ditch the clutter, declutter, try to delete things that you don't need anymore because those are taking up space. Those are taking out your R A MS and CPU when you're running your laptop and lastly prolong electronics, you can do like, I know I'm the same. I live in the UK. I always try to buy a new phone every two years. I don't know why they still work, but it just probably my contract run out and, and then they try to sell me a new phone and I buy it. So it is a really difficult transition to me. But hopefully with a common go to decarbonize globally. Those are the habits we as tech users can also pick up what's the difference between download and stream? Oh, I guess like streaming because um the way that Netflix where they have like CD N right at the different edge locations.

So they will have to make sure that the CD N is working in the nearest nearest location with where you are, right? And but if you download it after they send it off, you don't have to keep going back to Netflix and have like a connectivity between your phone and Netflix, right? So you can only so you can basically watch TV without internet and that's saving a lot of electricity and energy. Um Oh, I think um I see my nails have any more problem. I mean, not problem. Um Questions. Yeah, I know the Mozilla Foundation has been doing a lot of really interesting work. Um And I'm really looking forward to what they have achieved. Yeah. And my myself um is an SRE and I'm really interested in SRE and DEV ops space. So hopefully there's some something coming out of this space in the next couple of months, I have faith. And if you're really interested in partner up to do something with me, please do reach out to me. Could you hear me at the end? Oh, no, I can't hear you. Um Are you now how can the software engineers start applying green soft engineering principles at work? Right.

I think um it really depends on the size of the organization and, and, and um and then who you need to convince if that makes sense? Right. And um there's, but then before you actually say, hey, we need to redesign all architecture, we need to rewrite all our code. But before you get to there, why don't you think about, hey, I have a, I have a batch job that runs once a day, but this batch shop lives on a, on a machine that is running 24 7, can we can we try to turn those machine off? You know, just by doing that, we are saving energy and then proximate carbon. So I think by applying green soft engineering principle is very, is very, is very useful. But then, then again, it really depends on your organization size and who you can convince. And right now because the discipline is so new. If you Google, hey, what's the most sustainable way for me to deploy a springboard application to AWS, you can't find any like pattern or like blog post. So hopefully in a couple of months, then people will be able to use some of the out of the box too.

And then you can then say, hey, I've seen this guy deploying a spring applications applying green soft engineering principles and this is how much carbon, how much cost they have saved. Why don't we try to apply that at work?

Yeah, maybe.

Yeah. Yeah, I can hear you. I can hear you.

Important thing that I was trying to uh unmute is that my practice is that all the full amount of carbon? Because as you mentioned, we don't that consider and uh you are me, it would be nice. A video in Zoom calls the video, everyone of the pandemic. That camera o over to yes to think about the all the better practice just because their size. But we don't and uh that bring the light two are very important. So thank you for stepping in, share these practices with us the impact so that you already had and it would be nice to share you if the audience has. So you familiar with the topic I li title of your patient to see on your end? And we have a Yes, let's, but I find difficult, you know, then others are bad on. Yes. How are in assessing the impact of

um Yeah, so there's a question I what I found difficult. Yes, Aws Greener than others, but they are also bad. And so are so many other areas, how other areas should be integrating and assessing greens and human impact of resources? Yeah, I agree. To be honest. Right. Aws is actually one of the cloud provider right now does not have a transparent solution. Um Not transparent solution, transparent data point for their customers to see how much exactly how much carbon my my my hosted solution is costing like GCP have something called a carbon free energy and Microsoft, they have a calculator for their enterprise customers. So I but then then again, right, hopefully with like so many people now are interested in this topic and how all these topics are in the front page. We can then um we can then like reach out to Amazon or like um change the way they provide, they help out the customers basically um switching camera office a trade off and not commuting and avoiding travel, so definitely worth it to keep us all connected. I definitely agree. Um Zoom is very important. So I think what I was trying to convey is that if you're, you're in a massive meeting with 100 other people by showing your face of when you're not speaking, turning your camera off then is probably useful.

Um But yeah, it's like one on one meeting or like a meeting with S and P people, I think definitely have your camera on. Otherwise it would be very sad to not to see your teammates. Great. Thank you so much, Jessie for sharing um links on SRE the question form

H automation testing and deploy

impact. And that is a de space that um it's not, there's not a lot being done. So, for example, right? Um I I, I'm mainly working AWS. There are so many different ways of deploying infrastructure to AWS, but I don't know which friendly I can use uh terraform infrastructures code, I can use cloud formation, I can use CD K, I can use other different tools. But right now, there is just no data set against any of those considerations, right? So you'll be really useful in the future. If there is available, there's a, there's two available out of the box for any of those IEC and then same thing for like automated testing, like how you have to set up every bit of your automated testing. For example, your front end your back end and then like running some like um user testing and stuff. Thanks guys.