Google open-sources language-agnostic, scalable software tool

Google open-sources language-agnostic, scalable software tool

Bazel, Google's in-house software building and test system, is being open-sourced and available in beta

Google's latest open source offering, Bazel, automates the building and testing of software, along the lines of Ant or Maven.

But Bazel, now out in beta, surpasses those solutions. It's also language-agnostic, highly scalable, and able to generate builds that are bit-exact on both a developer's machine and the build cluster.

Bazel, written in Java and open-sourced under the Apache license, is "used to build the majority of Google's software," according to the project's GitHub page. Like Kubernetes, it's an internal project Google has released to the world in order to drive development and community efforts -- without giving up significant strategic advantage on Google's part.

Like many other build tools, Bazel brings with it a set of opinionated assumptions about how projects must be constructed. Bazel projects are described using a custom language, BUILD, which is a stripped-down version of Python. However, BUILD's minimal feature set helps Bazel guarantee reproducible builds; for instance, the only I/O allowed in a BUILD script is from the workspace designated for the project.

Another key feature of Bazel is support for multiple languages. Binaries, libraries, and tests for different languages are kept discrete through rule namespaces -- for example, cc_binary for C++ binaries, and java_library for Java libraries. Build operations are also cached, to speed up the build process and make Bazel better able to exploit parallelism.

Most of the benefits for Bazel will be seen with compiled languages like Java, C++, and Objective-C, all currently supported out of the box. Go language support is in the road map for later this year, but don't hold your breath waiting for Python or PHP -- Bazel doesn't have them in mind as a use case. ("If you are only using interpreted languages directly, such as JavaScript or Python," says the project FAQ, "Bazel will likely not interest you.")

It's also not yet clear when or how Bazel will be pushed as a universal build tool for all of Google's products. For instance, because it includes support for Java, Bazel is meant to work with Android as well. However, displacing Google's default Gradle tooling for Android will need the participation of Android developers to take root.

Like Kubernetes, Bazel's origins as an internal Google tool implies it's suited to the company's needs at scale, and thus can meet the needs of most anyone else. Google will likely lose very little strategically by giving away Bazel since the company competes in the cloud on the basis of scale and convenience, not technology alone.

One major omission so far with Bazel: Windows isn't supported. Right now Bazel will only work on Ubuntu Linux and Mac OS X, due to the way Bazel leverages symbolic links on those platforms. "We are currently actively working on improving Windows support, but it's still ways from being usable," says the project FAQ.

From CIO: 8 Free Online Courses to Grow Your Tech Skills
View Comments
Join the discussion
Be the first to comment on this article. Our Commenting Policies