Prioritizing What Matters for Closed Alpha and Beyond

Holochain Dev Pulse 24

Summary

This has been another big week for optimizing performance and setting priorities. There may be no massive feature updates or breaking changes to report, but we can and will celebrate continuous improvement to the software and our long-term trajectory.

Highlights

Process: Prioritizing The Things That Matter Performance: Faster Zome Calls and Lower Idle CPU Consumption Bug Fix: Scenario Tests Hang When Throwing JavaScript Error Documentation: Bridging Article Added Recognition and Celebration: Smooth Sailing and New Core Dev Team Members

Holochain Dev Pulse April 8–April 15th, 2019

Details

1. Process: Prioritizing The Things That Matter

We’ve been taking more time this week to prioritize features in the context of internal and external needs. This is something we’ve mentioned in previous Dev Pulses, but it’s worth another look. This regular, recurring work is a good sanity check to make sure we’re spending time solving the right problems.

Our core dev team maintains a ‘state of affairs tree’ for Holochain. This is like a product backlog, a Gantt chart, a task tracker, and an architectural diagram rolled into one. It helps us manage and map all the features and dependencies of this ambitious project — and we don’t just map out technical features.

Arguably, the most important items on the board have descriptions like: “logging is clear and useful,” “I can easily install Holochain and start building,” and most importantly, “Holochain & Holo are delivered and thriving.” All individual items are ultimately attached to high-level goals that mean something in the real world, and therefore, we can always explain why our current tasks matter.

Developer Community

We’re receiving more and more pulls, not only from within other teams in our organization, but also from the app developers in our growing community. This continues to be a source of excitement for us because it assures us that we’re starting to have a real impact. Regular cultivation of our state of affairs tree means that we’re always well-aligned beyond our source code with the needs of the world.

2. Performance: Faster Zome Calls and Lower Idle CPU Consumption

We’ve incorporated two main performance improvements this week. The first is an 80% speedup of DNA execution. We achieved this by pre-parsing the WebAssembly code and holding it in memory, which drops initialization time for zome and validation function calls. Along with other recent performance improvements, it’s taken our basic chat app benchmarks from barely usable to quite responsive. As you can read in the linked pull request, we’ve got even more WASM improvements in the works.

Rust Programming Language

When we started the refactor, we placed a big bet on WebAssembly and Rust. We felt WebAssembly would permit faster apps, written in more languages.

We chose Rust because its WebAssembly support was the most mature at the time. This risk has paid off and confirmed that Rust was a good choice — the developer community has created faster WASM engines that show multiple orders of magnitude speedup over the other options.

It’s reassuring to know that we will have multiple options that keep getting better over time.

The second improvement is the introduction of a sleep interval in the main thread. This removes the issue that Holochain was consuming 100% CPU when it was idle. Performance wasn’t affected, but it did create a lot of fan noise!

3. Bug Fix: Scenario Tests Hang When Throwing JavaScript Error

Two separate app developers reported issues related to scenario tests — an unhandled exception within a test function body would cause the scenario to hang. One of them correctly identified the cause and proposed a solution (thank you, mightyalex200, for your pull request)! We kept digging and found that we could fix it at an even lower level, which would cover edge cases in a more fundamental way than the original solution. We’ve also increased test coverage on the scenario API as a consequence.

This reflects our commitment to closing feedback loops between the core team and app developers. Receiving feedback causes us to rigorously investigate root causes and getting follow-up information helps us identify whether we’ve successfully solved the problem.

Thank you, Developer Community, for your assistance in this area, your talents, and your willingness to take a little time to let us know what you’ve discovered!

4. Documentation: Bridging Article Added

Bridging allows a user’s Holochain DNA instances to talk directly to each other, rather than through the mediation of a UI. This is useful, as a UI is not always able to provide the same integrity guarantees as the DNA itself.

Many devs have expressed interest in more documentation on this important topic, so we’re happy to announce that we’ve added an article to our Guidebook explaining how to call a zome function in another DNA using `hdk::api::call()`. The Holo dev team wrote this article, with a recent success bridging HoloFuel to the Signed Service Log still in their minds.

Breaking change warning: When fully functioning capability-based security lands in Holochain, the signature of `call()` will likely change. This will affect calls between zomes in one DNA as well as bridges to another DNA.

5. Recognition and Celebration: Smooth Sailing and New Core Dev Team Members

Those who persevere to the end of our weekly Dev Pulses know that we like to get personal and share a few challenges. We aren’t trying to break this pattern, but we just don’t have anything like that to report this time. We’ll skip the long, seafaring metaphor and simply say — it’s been a great week of smooth sailing!

Instead, we’d like to express our gratitude that two new core devs with solid Rust skills joined us this week. Meidhy is a developer from France who has joined our team as part of his search for deeper meaning in work. Carmelo has been an active and important part of our Mattermost Dev Chat for over a year.

It’s been exciting to see our state of affairs tree heat up with their added attention. Thanks to both of you for how you’re already showing up for the team!

Development Status:

Building an App/Platform on Holochain? We want to hear from you!

Are you building on Holochain? We would love to connect and hear more about your app/platform. Please, take a few moments to fill out this survey! Our goal is to list all the projects building on Holochain on our website.

Stack Overflow: Expand the Holochain Knowledge Base

Help us grow the Holochain knowledge base on Stack Overflow!

Submit your Holochain question.

Submit your Holochain Rust question.

Contribute to the Holochain Documentation

Lastly, to all of our readers — we’d like to encourage you to submit an issue or a pull request if you are interested in contributing to code. If you have a passion for, or would like to see, improvements made to the documentation, submit a new issue or add a suggestion to the Holochain Guidebook.

Connect with the developer community: