Skip to content

Commit

Permalink
Added Andrea to maintainers list +1 (Apicurio#4042)
Browse files Browse the repository at this point in the history
* Added Andrea to maintainers list.  Fixed a bug in the H2 SQL queries

* Change getNextSequenceValue() for h2 to RT exception since it should not be called.
  • Loading branch information
EricWittmann authored Nov 30, 2023
1 parent 2750eaf commit d5b678c
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3363,7 +3363,7 @@ private long nextSequenceValue(String sequenceName) {
.one(); // TODO Handle non-existing sequence (see resetSequence)
} else {
// no way to automatically increment the sequence in h2 with just one query
// we are incresing the sequence value in a way that it's not safe for concurrent executions
// we are increasing the sequence value in a way that it's not safe for concurrent executions
// for kafkasql storage this method is not supposed to be executed concurrently
// but for inmemory storage that's not guaranteed
// that forces us to use an inmemory lock, should not cause any harm
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public String upsertContent() {
*/
@Override
public String getNextSequenceValue() {
return "UPDATE sequences sa SET seq_value = (SELECT sb.seq_value + 1 FROM sequences sb WHERE sb.name = sa.name) WHERE sa.tenantId = ? AND sa.name = ?";
throw new RuntimeException("Not applicable when using H2 as the database kind.");
}

/**
Expand Down
16 changes: 13 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
<role>Project Lead</role>
<role>Developer</role>
</roles>
<timezone>-5</timezone>
<timezone>America/New_York</timezone>
</developer>
<developer>
<name>Jakub Senko</name>
Expand All @@ -55,7 +55,7 @@
<roles>
<role>Developer</role>
</roles>
<timezone>+1</timezone>
<timezone>Europe/Prague</timezone>
</developer>
<developer>
<name>Carles Arnal</name>
Expand All @@ -65,7 +65,17 @@
<roles>
<role>Developer</role>
</roles>
<timezone>+1</timezone>
<timezone>Europe/Madrid</timezone>
</developer>
<developer>
<name>Andrea Peruffo</name>
<id>andreaTP</id>
<email>[email protected]</email>
<organization>Red Hat</organization>
<roles>
<role>Developer</role>
</roles>
<timezone>Europe/Lisbon</timezone>
</developer>
</developers>

Expand Down

0 comments on commit d5b678c

Please sign in to comment.