Hello Everyone, *If you are new to Beam and coming from non-Java language conventions, it is likely you are new to gradle. At the end of this email is a list of definitions and references to help understand this email.*
*Short Version (For those who know gradle)*: A pull request [1] may fix the continual error message "Error: Backend initialization required, please run "terraform init"". The PR applies Task Configuration Avoidance [2] by applying changes to a few tasks from tasks(String) to tasks.register(String). *Long Version (For those who are not as familiar with gradle)*: I write this not as an expert but as someone still learning. Gradle [3] is the software we use in the Beam repository to automate many needed tasks associated with building and testing code. It is typically used in Java projects but can be extended for other purposes. We store code related to our Beam Playground [4] that also uses gradle though it is not mainly a Java project. The unit of work for Gradle is what is called a task. To run a task you open a terminal and type "./gradlew nameOfMyTask". There are two main ways to create a custom task in our build.gradle files. One is writing task("doSomething") and the other is tasks.register("doSomethingElse"). According to [2], the recommendation is to use the tasks.register("doSomething"). This avoids executing other work (configuration but don't worry about it for now) until one runs the doSomething task or another task we are running depends on it. So why were we seeing this "Error: Backend initialization required" message all the time? The reason is that tasks were configured as task("doSomething"). All I had to do was change this to tasks.register("doSomething") and it removed the message. *Definitions/References* 1. https://github.com/apache/beam/pull/24509 2. https://docs.gradle.org/current/userguide/task_configuration_avoidance.html 3. https://docs.gradle.org/current/userguide/what_is_gradle.html 4. https://play.beam.apache.org/ *Suggested Learning Path To Understand This Email* 1. https://docs.gradle.org/current/samples/sample_building_java_libraries.html 2. https://docs.gradle.org/current/userguide/build_lifecycle.html 3. https://docs.gradle.org/current/userguide/tutorial_using_tasks.html 4. https://docs.gradle.org/current/userguide/task_configuration_avoidance.html Best, Damon