1. Reduce resolution of images and/or send them less frequently
When pictures are used in mobile applications, these pictures must be sent of the internet and radio connection, which is a major source of energy consumption. By reducing the size of these images or uploading them less often, energy can be saved. In particular, applications that run in a mobile browser can benefit greatly from this quick win.
2. Run multiple applications on shared servers
If each application runs on its own server, these servers will be doing nothing useful most of the time. But they are on, and consume electricity, all of the time. By letting applications share servers, fewer servers are needed to do the same work. Many applications can be easily made suitable to run on shared servers.
3. Reduce data translation between components
To make various components of a software system work together, translation may be needed of the data that they exchange. Such translations can be computationally expensive. Sometimes, multiple translation steps are performed rather than translating from source to target in a single step. Also, the intermediate formats can be overly verbose, leading to big files being transferred that could be much smaller. By simplifying the formats and the translation steps, unnecessary energy consumption can be reduced.
4. Log less
While developing software, it is useful to let the application log the steps it is taking and their intermediate results, to diagnose bugs or other problems. Writing logging information to disk and storing large log files consumes energy. But when the finished application is deployed in a production environment, much of this logging information is not used. By using a logging framework that allows the degree of logging to be reduced when logs are not used, unnecessary energy consumption can be avoided.
5. Delete historic data
An application that supports a certain business process needs to store information about business transactions. After the business transaction has been concluded, most applications will retain data related to that transaction for possible future reference. This data is often kept “alive” without being used. Year after year it sits in memory or on a hard disk and thus causes energy consumption. By purging old transactions from the application database, the storage needs can be prevented from growing larger and larger, and energy can be saved.
6. Compile interpreted languages
Many applications are developed in programming languages that are not compiled to efficient machine code before deployment, but that are translated by an interpreter to machine code while the application runs. Such interpreted code typically requires more processing power, hence more servers consuming more energy to do the same work. For some of these interpreted languages, such as PHP, a compiler is also available. By making small changes to the application code, it can be made suitable for compilation, after which it can be run more (energy-)efficiently.
7. Refrain from frivolous features
Modern development toolkits make it possible to create astonishing user interfaces, full of graphics, animations, assisted editing, suggestions for further navigation, etc. Sometimes such features are useful because they enrich the user experience and make the user more productive in the tasks to accomplish. When copying a file from one folder to another, do you really need to watch sheets of paper fly from one end to another? Features that offer no value to the user generally do consume energy, which can be saved by omitting them.
8. Avoid chatty protocols
The communication protocols between components of an application can involve many messages being sent back and forth. In case of smart phone apps, radio traffic is a major source of energy consumption, which can be reduced by not establishing a new radio connection for each message, but saving up several messages until a number of them can be sent at once. For example, apps could save information to the server only after a number of data-entry screens have been completed, rather than after completing each screen.
These quick wins do not always apply and are only a first step towards energy efficiency. To create truly energy-efficient software applications requires attention during all phases of the lifecycle, starting from requirements and design, followed by coding and testing, and finally deployment and operation.
More information
Knowledge Network Green Software website