Skip to content

Spring Boot

themarioga edited this page Nov 8, 2026 · 2 revisions

Spring Boot

<dependency>
    <groupId>io.github.tie-integration-engine</groupId>
    <artifactId>tie-spring-boot-starter</artifactId>
    <version>0.1.0-SNAPSHOT</version>
</dependency>

The starter targets Spring Boot 4. TieAutoConfiguration creates a Tie bean unless the application declares one, and:

  • registers every FieldTransformer bean under its bean name;
  • uses the DefaultValueResolver, SecretProvider and Clock beans if they exist.
@SpringBootApplication
public class Application {

    @Bean
    FieldTransformer upperNif() {          // used by fields with transformer: upperNif
        return (value, record, direction) -> value.toUpperCase(Locale.ROOT);
    }

    @Bean
    SecretProvider secrets(Vault vault) {  // resolves ${secret:name}
        return name -> vault.read(name).toCharArray();
    }
}
@Service
class PeopleImport {

    private final Tie tie;
    private final IntegrationDefinition definition;

    PeopleImport(Tie tie, @Value("classpath:people.yaml") Resource yaml) throws IOException {
        this.tie = tie;
        try (InputStream in = yaml.getInputStream()) {
            this.definition = DefinitionLoader.fromYaml(in);
        }
    }

    ImportResult run(Map<String, LocalDateTime> watermarks) {
        return tie.importFiles(definition, ImportContext.builder(this::apply).watermarks(watermarks).build());
    }
}

Properties

Property Meaning
tie.working-directory Working directory of every import and export whose context does not set one (default java.io.tmpdir)

The starter generates configuration metadata, so IDEs complete the property.

Scheduling and concurrency

TIE does not schedule runs and does not lock sources. Use your scheduler (@Scheduled, Quartz…) and make sure two runs on the same source never overlap, for example with a distributed lock.

Clone this wiki locally