Home / Function/ writeConfig() — spring-boot Function Reference

writeConfig() — spring-boot Function Reference

Architecture documentation for the writeConfig() function in ImageArchive.java from the spring-boot codebase.

Entity Profile

Dependency Diagram

graph TD
  6bbd9327_660f_198a_8016_366f4ed9b297["writeConfig()"]
  e4323026_a089_9ff3_39c2_cc5d4a910178["write()"]
  e4323026_a089_9ff3_39c2_cc5d4a910178 -->|calls| 6bbd9327_660f_198a_8016_366f4ed9b297
  8fd71db8_f92c_c709_bed4_e2d2c18d9b24["createConfig()"]
  6bbd9327_660f_198a_8016_366f4ed9b297 -->|calls| 8fd71db8_f92c_c709_bed4_e2d2c18d9b24
  7113fa8d_2246_a352_b97d_d758ef9fac93["of()"]
  6bbd9327_660f_198a_8016_366f4ed9b297 -->|calls| 7113fa8d_2246_a352_b97d_d758ef9fac93
  style 6bbd9327_660f_198a_8016_366f4ed9b297 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

buildpack/spring-boot-buildpack-platform/src/main/java/org/springframework/boot/buildpack/platform/docker/type/ImageArchive.java lines 158–171

	private String writeConfig(Layout writer, List<LayerId> writtenLayers) throws IOException {
		try {
			ObjectNode config = createConfig(writtenLayers);
			String json = this.jsonMapper.writeValueAsString(config).replace("\r\n", "\n");
			MessageDigest digest = MessageDigest.getInstance("SHA-256");
			InspectedContent content = InspectedContent.of(Content.of(json), digest::update);
			String name = LayerId.ofSha256Digest(digest.digest()).getHash() + ".json";
			writer.file(name, Owner.ROOT, content);
			return name;
		}
		catch (NoSuchAlgorithmException ex) {
			throw new IllegalStateException(ex);
		}
	}

Subdomains

Called By

Frequently Asked Questions

What does writeConfig() do?
writeConfig() is a function in the spring-boot codebase.
What does writeConfig() call?
writeConfig() calls 2 function(s): createConfig, of.
What calls writeConfig()?
writeConfig() is called by 1 function(s): write.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free