Skip to content
/ Veld Public

Ultra-fast Dependency Injection for Java - Zero Reflection, Pure Code Generation

License

Notifications You must be signed in to change notification settings

yasmramos/Veld

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Veld

Build Status License Java Maven Ask DeepWiki Tests Coverage Last Release Last Commit Issues Forks Stars Contributors

Veld Framework

Ultra-fast Dependency Injection for Java - Zero Reflection, Pure Code Generation

Veld is a compile-time Dependency Injection framework that generates pure Java code. Zero reflection at runtime means maximum performance - up to 100x faster than Spring in dependency resolution benchmarks.

Designed for developers who want maximum performance, full control, and zero runtime magic.

Quick Start

1. Add Dependencies

Maven:

<dependency>
    <groupId>io.github.yasmramos</groupId>
    <artifactId>veld-runtime</artifactId>
    <version>1.0.3</version>
</dependency>
<dependency>
    <groupId>io.github.yasmramos</groupId>
    <artifactId>veld-annotations</artifactId>
    <version>1.0.3</version>
</dependency>

Gradle:

implementation 'io.github.yasmramos:veld-runtime:1.0.3'
implementation 'io.github.yasmramos:veld-annotations:1.0.3'

2. Configure Maven Plugin

<build>
    <plugins>
        <plugin>
            <groupId>io.github.yasmramos</groupId>
            <artifactId>veld-maven-plugin</artifactId>
            <version>1.0.3</version>
        </plugin>
    </plugins>
</build>

3. Create Components

import io.github.yasmramos.veld.annotation.Component;
import io.github.yasmramos.veld.annotation.Inject;

@Component
public class UserService {
    private final UserRepository repository;
    
    @Inject
    public UserService(UserRepository repository) {
        this.repository = repository;
    }
    
    public User getUser(Long id) {
        return repository.findById(id);
    }
}

4. Use Veld

import io.github.yasmramos.veld.Veld;

public class Main {
    public static void main(String[] args) {
        UserService userService = Veld.get(UserService.class);
        User user = userService.getUser(1L);
    }
}

Why Veld?

Feature Veld Spring Guice
Reflection at runtime None Heavy Moderate
Startup time ~0.1ms ~500ms+ ~100ms
Injection speed ~0.001ms ~0.01ms ~0.005ms

Performance Highlights

  • Up to 100x faster than Spring in dependency resolution benchmarks
  • 3ns average injection latency
  • 0.003ms startup time
  • Zero runtime reflection overhead

Documentation

Topic Location
Getting Started docs/getting-started.md
Annotations Reference docs/annotations.md
Core Features docs/core-features.md
API Reference docs/api.md
AOP Guide docs/aop.md
EventBus docs/eventbus.md
Performance Benchmarks docs/benchmarks.md
Architecture docs/architecture.md
Examples docs/examples.md

Modules

Module Description
veld-annotations Core annotations
veld-runtime Runtime utilities
veld-processor Annotation processor
veld-weaver Bytecode weaving
veld-maven-plugin Unified build plugin
veld-aop Aspect-Oriented Programming
veld-resilience Circuit Breaker, Retry, Rate Limiter
veld-cache Caching support
veld-validation Bean validation
veld-security Method-level security
veld-metrics Metrics collection
veld-tx Transaction management
veld-spring-boot-starter Spring Boot integration

Spring Boot Starter

To integrate Veld with Spring Boot applications, use the Spring Boot starter.

Add Dependency

Maven:

<dependency>
    <groupId>io.github.yasmramos</groupId>
    <artifactId>veld-spring-boot-starter</artifactId>
    <version>1.0.3</version>
</dependency>

Gradle:

implementation 'io.github.yasmramos:veld-spring-boot-starter:1.0.3'

Building from Source

git clone https://github.com/yasmramos/Veld.git
cd Veld
mvn clean install

Links


Veld - Dependency Injection at the speed of direct method calls.

About

Ultra-fast Dependency Injection for Java - Zero Reflection, Pure Code Generation

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Sponsor this project

Packages

 
 
 

Contributors 10

Languages