GitHub
github.com › randgalt › record-builder
GitHub - Randgalt/record-builder: Record builder generator for Java records · GitHub
Record builder generator for Java records. Contribute to Randgalt/record-builder development by creating an account on GitHub.
Starred by 923 users
Forked by 70 users
Languages Java
GitHub
github.com › avaje › avaje-record-builder
GitHub - avaje/avaje-record-builder: generates builder for records · GitHub
Return a new builder with all fields set to default Java values */ public static ArmoredCoreBuilder builder() { return new ArmoredCoreBuilder(); } ... Return a new builder with all fields set to the values taken from the given record instance */ public static ArmoredCoreBuilder builder(ArmoredCore from) { return new ArmoredCoreBuilder(from.coreName(), from.model(), from.energyReserve(), from.ap()); }
Starred by 22 users
Forked by 2 users
Languages Java
Records and @Builder
It does not defeat the purpose. Records are immutable data objects. How you initialize them, is up to you and using the builder pattern on big data objects makes sense as sometimes the default record constructor might be inflexible. If you don't want to use lombok (@Builder), this works great: https://github.com/Randgalt/record-builder More on reddit.com
Java record does not have default builder - Stack Overflow
This standalone project provides a great record builder solution github.com/Randgalt/record-builder. ... Recreating Lombok is not the purpose of Java record. More on stackoverflow.com
ANN: Record Builder (early access) for Java Records
I see a builder as vital to complete Java records. The JDK will get around to it eventually (and likely other tools) but I thought I'd add it now.
Example
@RecordBuilder
public record NameAndAge(String name, int age){}This will generate a builder class that can be used ala:
// build from components var n1 = NameAndAgeBuilder.builder().name(aName).age(anAge).build(); // generate a copy with a changed value var n2 = NameAndAgeBuilder.builder(n1).age(newAge).build(); // name is the same as the name in n1 // pass to other methods to set components var builder = new NameAndAgeBuilder(); setName(builder); setAge(builder); var n3 = builder.build();More on reddit.com
[ANN] RecordBuilder v33 Released
I love this project for bringing much needed withers to Java records. Still waiting for the day we get named params so that we can reduce wither boilerplate. More on reddit.com
Videos
Java Record : Stop Writing Boilerplate! Java Records Do It For You.
03:24
java record with builder - YouTube
14:20
Records In Java - Full Tutorial - YouTube
03:19
Java Builder Pattern Explained in 3 Minutes
03:19
Java Builder Pattern Explained in 3 Minutes - YouTube
01:30
Java Records in 90 Seconds - YouTube
GitHub
github.com › Blackdread › record-builder
GitHub - Blackdread/record-builder: Record builder generator for Java records
Record builder generator for Java records. Contribute to Blackdread/record-builder development by creating an account on GitHub.
Author Blackdread
GitHub
github.com › pawellabaj › auto-record
GitHub - pawellabaj/auto-record: Java record source generator
Java record source generator. Contribute to pawellabaj/auto-record development by creating an account on GitHub.
Starred by 7 users
Forked by 2 users
Languages Java 100.0% | Java 100.0%
GitHub
github.com › Pravin3c › Builder-Pattern-with-Java-Records
GitHub - Pravin3c/Builder-Pattern-with-Java-Records: Ways to Create Builder Pattern for Java Records · GitHub
Below are three approaches to implementing the builder pattern with Java Records. 1. Using Nested Static Class Step 1: Define the Record We start by defining an Employee record with multiple fields. public record Employee(Long id, String name, String company, Integer salary) {} Step 2: Create the Builder Class We then create a static inner builder class inside the Employee record.
Author Pravin3c
GitHub
github.com › Randgalt › record-builder › blob › master › record-builder-core › src › main › java › io › soabase › recordbuilder › core › RecordBuilder.java
record-builder/record-builder-core/src/main/java/io/soabase/recordbuilder/core/RecordBuilder.java at master · Randgalt/record-builder
Record builder generator for Java records. Contribute to Randgalt/record-builder development by creating an account on GitHub.
Author Randgalt
Reddit
reddit.com › r/javahelp › records and @builder
r/javahelp on Reddit: Records and @Builder
September 2, 2024 -
Is it worth using the Builder pattern with Java Records, or does it defeat the purpose of using Records in the first place? I'm trying to decide if I should combine these two, especially for scenarios where I have optional fields. Any advice or best practices?
Top answer 1 of 5
3
It does not defeat the purpose. Records are immutable data objects. How you initialize them, is up to you and using the builder pattern on big data objects makes sense as sometimes the default record constructor might be inflexible. If you don't want to use lombok (@Builder), this works great: https://github.com/Randgalt/record-builder
2 of 5
3
Your old posts feed data brokers and AI training models. I stopped that by using Redact to bulk delete across Reddit, Twitter, Discord, Facebook and all major social media platforms. wine subsequent sort thought plants pause long steep history support
DEV Community
dev.to › agavrilov76 › record-companion-simple-builder-pattern-for-java-records-4h9f
Record Companion: Simple Builder Pattern for Java Records - DEV Community
September 21, 2025 - Today, I want to introduce Record Companion - a library that brings the same philosophy of simplicity to builder pattern generation. ... You'd typically need to write a lot of boilerplate code. Record Companion solves this with a single annotation. Record Companion follows the same philosophy I outlined in the validation article: the goal isn't to have the most features—it's to have code that's easy to read, maintain, and debug. ... import io.github.recordcompanion.annotations.Builder; @Builder public record User(String name, int age, String email) {}
GitHub
github.com › stevejuma › intellij-plugin-builder
GitHub - stevejuma/intellij-plugin-builder: IntelliJ IDE Record builder generator plugin for Java Records, Beans, Interfaces · GitHub
IntelliJ IDE Record builder generator plugin for Java Records, Beans, Interfaces - stevejuma/intellij-plugin-builder
Author stevejuma
GitHub
github.com › Randgalt › record-builder › blob › master › customizing.md
record-builder/customizing.md at master · Randgalt/record-builder
Record builder generator for Java records. Contribute to Randgalt/record-builder development by creating an account on GitHub.
Author Randgalt
GitHub
github.com › DanielLiu1123 › recordbuilder
GitHub - DanielLiu1123/recordbuilder: Build your objects with confidence. Not null by default, inspired by Protobuf. · GitHub
import org.jspecify.annotations.Nullable; @Generated( value = "recordbuilder.RecordBuilderProcessor", date = "..." ) public final class UserBuilder { private String _name; private Integer _age; private @Nullable String _email; private List<String> _roles; private Map<String, String> _attributes; private int _presenceMask0_; private UserBuilder() {} // Factory methods to create a new builder public static UserBuilder builder() { ...
Author DanielLiu1123
GitHub
github.com › Randgalt › record-builder › blob › master › README.md
record-builder/README.md at master · Randgalt/record-builder
Record builder generator for Java records. Contribute to Randgalt/record-builder development by creating an account on GitHub.
Author Randgalt
Baeldung
baeldung.com › home › java › a practical guide to recordbuilder in java
A Practical Guide to RecordBuilder in Java | Baeldung
November 12, 2025 - It generates fluent, immutable-friendly builders that remove the need for manual constructors or update methods. Its real strength is balance: flexible updates without losing immutability, and expressive code without boilerplate. Whether we’re building DTOs, API responses, or config objects, it fits naturally into our workflow. With almost no setup, RecordBuilder becomes a powerful tool for clean, scalable Java development. The code backing this article is available on GitHub...
OpenJDK
mail.openjdk.org › pipermail › core-libs-dev › 2021-May › 077957.html
Builder pattern for Java records
May 22, 2021 - If some project out there wants to have code generators for patterns that are sometimes useful for records, that’s great — but that’s not where the language should be focusing. > On May 21, 2021, at 11:37 AM, Alberto Otero Rodríguez <albest512 at hotmail.com> wrote: > > Hi, I have found this project on GitHub which creates a Builder for Java records: > https://github.com/Randgalt/record-builder > [https://opengraph.githubassets.com/a4e3a7b3c7b16b51e0854011fe4b031577bcc09919058baef412b03613295d20/Randgalt/record-builder]<https://github.com/Randgalt/record-builder> > GitHub - Randgalt/record-builder: Record builder generator for Java records<https://github.com/Randgalt/record-builder> > The target package for generation is the same as the package that contains the "Include" annotation.