A metamodel framework
that replaces beans

GlobsFramework lets you define data types once and get serialization, database access, HTTP handling, and more β€” all without introspection.

Get Started Core Concepts

What is GlobsFramework?

GlobsFramework is a lightweight Java library that replaces the classic bean pattern with a richer abstraction called a Glob. Instead of opaque Java objects accessed via reflection, Globs carry their own schema (GlobType) and expose typed fields β€” so generic code can work with data without introspection.

The result is a clean, uniform API across all I/O layers: JSON, XML, CSV, binary formats (TLV and the protobuf wire format), SQL databases, HTTP endpoints and GraphQL can all be driven from the same model definition, with zero reflection at runtime.

Why use it?

πŸ”

No reflection

Field access is done through Field objects, not string-based reflection. The compiler catches typos, and the JVM optimizes hot paths normally.

♻️

Write generic code once

One serializer, one DB mapper, one HTTP handler template β€” they all work on any GlobType you define, today or tomorrow.

🏷️

Annotations as data

Metadata is not a Java @interface: an annotation is itself a GlobType, attached when the field is declared and queried at runtime like any other Glob.

⚑

Lightweight & zero deps

The core library has no runtime dependencies beyond SLF4J for logging. Sub-libraries pull in exactly what they need (Gson, JDBC driver, …).

πŸ”„

Static & dynamic in one model

Generate types dynamically from JSON or database schemas, and use the same type with fully type-safe static accessors β€” both in the same codebase.

🌐

Full ecosystem

Ready-made modules for SQL, JSON, XML, CSV, binary (TLV and protobuf), HTTP, GraphQL, MCP, FIX, command-line parsing, and off-heap storage.

The core idea in 30 seconds

Define your data type once using a plain Java class with static fields:

public class ProductType {
    public static final GlobType     TYPE;
    public static final LongField    id;
    public static final StringField  title;
    public static final DoubleField  price;
    public static final BooleanField published;

    static {
        GlobTypeBuilder b = GlobTypeBuilderFactory.create("Product");
        id        = b.declareLongField("id");
        title     = b.declareStringField("title");
        price     = b.declareDoubleField("price");
        published = b.declareBooleanField("published");
        TYPE      = b.build();
    }
}

Create and populate a Glob β€” without new ProductBean(), without getters/setters:

MutableGlob product = ProductType.TYPE.instantiate()
    .set(ProductType.id,    42L)
    .set(ProductType.title, "XPhone")
    .set(ProductType.price, 999.0);

// Type-safe read β€” no cast needed
String title = product.get(ProductType.title);

Now use it everywhere:

// Serialize to JSON
String json = GSonUtils.encode(product, false);

// Deserialize from JSON
Glob g = GSonUtils.decode(json, ProductType.TYPE);

// Insert into database
sqlConnection.getCreateBuilder(ProductType.TYPE)
    .set(ProductType.id, 42L)
    .set(ProductType.title, "XPhone")
    .getRequest().apply();

// Query the database
List<Glob> results = sqlConnection
    .getQueryBuilder(ProductType.TYPE,
        Constraints.equal(ProductType.published, true))
    .selectAll()
    .getQuery()
    .executeAsGlobs();
The same ProductType.TYPE drives JSON, XML, SQL, HTTP, GraphQL and the protobuf wire format β€” no separate DTO classes, no mappers to maintain.

How it compares

Approach Generic code? Reflection? Schema at runtime? Type safety
Plain beans ❌ per-class code βœ… required ❌ Compile-time
java.util.Map βœ… ❌ ❌ ❌ stringly typed
Record / Lombok ❌ per-class code βœ… required ❌ Compile-time
GlobsFramework βœ… ❌ βœ… GlobType Compile-time (static fields)

History

The design is rooted in the telecom industry's GDMO model and ASN.1 β€” a standard for generating database schemas, UIs, and encoders from a single managed-object definition. GlobsFramework was rewritten in Java in 2006 by RΓ©gis Medina and Marc Guiot for a financial firm, then open-sourced through the BudgetView project and refined through years of production use in data aggregation and e-commerce back-ends.