February 19th, 2025 4pm CET/ 9am CST
Webinar "AI Transformation with Corporate LLM"
Contact us

Logistics Route Optimization Solution

Software reengineering for a Nordic waste container management service provider

ABOUT
the project

Client:

Logistics Software Solution provider

Location:

Country flag

Helsinki, Finland

Company Size:

20+ Employees

Industry:

Services:

Legacy software modernization

Technologies:

Flutter

Python

BloC architecture

Golden tests

Isar DB

HERE SDK

Logistics container management solution ensures the proper placement of approved containers and provides route optimization to simplify the tracking and collection of waste. It aims to significantly reduce costs, increase pick-up frequencies, and enhance control over the billing process.

Quotation marks Quotation marks

The biggest challenge was that the app had been migrated without a clear architecture, proper structure, or adherence to best practices. We have introduced proper app architecture, fixed all the issues, added unit and widget tests, refactored the code, and successfully finished app migration

taras hirniak tech lead

Taras Hirniak

Tech Lead at Leobit

logistics software development

Customer

Our customer is a Nordic leading innovator in cloud technology and sensor solutions designed to revolutionize waste management. Their tools help waste management companies optimize the ways to collect, transport, and distribute waste, with a focus on reducing operational costs, minimizing environmental impact, and enhancing overall efficiency in waste and recycling processes.

Business Challenge

Our customer faced a challenging software migration of their legacy Android application written on Java to the cross-platform Flutter framework, which resulted in an app plagued by glitches, poor functionality, and performance issues. The existing solution also lacked the flexibility to support new features. Since the customer didn’t have Flutter experts in-house, they sought external experts to help reengineer their logistics application, ensuring it could support future growth and development.

Why Leobit

Leobit’s extensive experience in cross-platform development, specifically Flutter, proved to the customer that we could be the right fit for the project. Our track record of delivering high-quality, scalable, and maintainable applications across various industries, including Logistics and Supply chain, further reinforced their confidence.

Architecture (2)

Project
in detail

Leobit’s Flutter experts successfully completed the migration process and thoroughly reengineered the customer’s container management service, ensuring it adheres to modern coding standards and engineering best practices. Leobit’s comprehensive approach transformed the customer’s container management service into a maintainable, scalable, and efficient solution. The improvement we made fixed the immediate issues and set the stage for future growth and development.

One of the key challenges was the absence of project and code documentation. Leobit’s experts addressed this by developing comprehensive architectural documentation and establishing a clear structure for the project. We developed UML diagrams, documented best practices, and outlined approaches to ensure that future developers could easily understand and work with the system. This improved the application’s maintainability and provided a solid foundation for future development and feature expansion.

The customer also lacked automated testing pipelines, meaning all tests were conducted manually before merging, which was time-consuming and prone to errors. Leobit suggested automating deployment by introducing CI/CD, which can significantly speed up the development process and ensure higher code quality.

The reengineering process included refining the application’s main page to harmonize how varying data heights are displayed on the front end. Given that the app is used on a variety of devices, particular attention was paid to creating a dynamic UI that is user-friendly on tablets.

To dynamically respond to changes in the schedule and notify users in real time, we implemented WebSocket connections. This allowed us to instantly push updates to the app, ensuring that users are always informed of any changes as they happen.

logistics software development
project-in-detail

New architecture development and code refactoring

The project initially lacked any architectural framework, which made it difficult to maintain and extend. Leobit introduced the BLoC (Business Logic Component) architecture, which brought structure and scalability to the application. For state management, we used a combination of BLoC and Cubit, selecting the appropriate approach based on the specific task at hand. This allowed for efficient state handling and improved application performance.

To ensure reliability and stability, the core functions and repositories were thoroughly tested using a range of tests, including unit, widget, UI, BLoC, and golden tests.

To further streamline development, Leobit added scripts for tasks such as running full app coverage and executing utility functions. The team also introduced Linter as an addition to the BLoC architecture pattern in Flutter This tool helped enforce consistent styling and coding standards across the project, reducing errors and improving code quality.

Our Flutter team leader suggested modularizing the app into sections and adding abstraction layers to make it easier to implement changes at a low level—such as when business logic or backend components change. The application was divided into core logic and feature sections, with separate packages for the repository, API, models, and database layers.

project-in-detail

Testing and code review

At the start of the collaboration, Leobit introduced Linter to the project and identified over 1,000 code issues. These issues included problems with styling, poorly written functions, and other inconsistencies. Leobit successfully resolved all these issues, significantly improving the quality of the codebase. We also introduced unit testing to reduce the number of bugs and minimize potential issues, leading to a more stable and reliable application. In addition to that, our Flutter team leader introduced a formal code review process to the project, which helped improve the overall quality of the codebase and allowed the in-house team to work more efficiently. Additionally, we integrated PiwikPro for analytics, providing valuable insights into user behavior and application performance.

project-in-detail

HERE Maps integration

The customer needed a solution to plan and display routes for garbage trucks, track their progress along these routes, and store the progress in case of internet outages. To address these requirements, Leobit implemented a solution using the HERE SDK to display maps, truck routes, and the locations of waste collection containers. The Isar database was chosen to store data and enable the application to function offline, ensuring continuous operation even without internet connectivity.

Technology Solutions

  • BLoC architecture adoption brought structure and scalability to the application
  • Comprehensive architectural documentation development helped establish a clear structure for the project
  • Modularizing the app into sections and adding abstraction layers streamlined the process of implementing changes at a low level
  • HERE SDK integration to display maps, truck routes, and the locations of waste collection containers

Value Delivered

  • The upgraded container management solution provided significant value to our customer’s clients, enabling them to reduce the number of bins and achieve financial savings of up to 35-40% through more efficient waste management practices
  • A dynamic UI that is user-friendly on both phones and tablets