INNER CODE UNIT · Java

getMigrations

gruelbox/transaction-outbox · transactionoutbox-core/src/main/java/com/gruelbox/transactionoutbox/DefaultDialect.java:55

  public Stream<Migration> getMigrations() {
    return migrations.stream();
  }

  @Setter
  @Accessors(fluent = true)
  static final class Builder {
    private final String name;
    private String delete = "DELETE FROM {{table}} WHERE id = ? and version = ?";
    private String deleteExpired =
        "DELETE FROM {{table}} WHERE nextAttemptTime < ? AND processed = true AND blocked = false"
            + " LIMIT {{batchSize}}";
    private String selectBatch =
        "SELECT {{allFields}} FROM {{table}} WHERE nextAttemptTime < ? "
            + "AND blocked = false AND processed = false AND topic = '*' LIMIT {{batchSize}}";
    private String lock =
        "SELECT id, invocation FROM {{table}} WHERE id = ? AND version = ? FOR UPDATE";
    private String checkSql = "SELECT 1";

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…