From 645178730525b01a65cd33d644f4feb3d87727a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mats=20H=C3=B6gberg?= Date: Mon, 26 Sep 2022 09:47:43 +0100 Subject: [PATCH] Fix typo in "Prefer acyclic dependency graphs" section of Java coding principles --- docs/best-practices/java-coding-guidelines/readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/best-practices/java-coding-guidelines/readme.md b/docs/best-practices/java-coding-guidelines/readme.md index 7a0e07c34..656b04a8d 100644 --- a/docs/best-practices/java-coding-guidelines/readme.md +++ b/docs/best-practices/java-coding-guidelines/readme.md @@ -1760,7 +1760,7 @@ public FooResource(String name) { } ``` -Acyclic dependency graphs are hard to understand, hard to setup for tests and mocks, and introduce subtle code ordering +Circular dependency graphs are hard to understand, hard to setup for tests and mocks, and introduce subtle code ordering constraints. For example, switching the order of the constructor statements introduces a bug where the resource name is always "FooResource on port 0" since `Server#port` hasn't been initialized when the resource calls `Server#port()`: