The Quarkus project moves to apps/backend and the Express sources go. The image is built from the repo root as before, with Temurin 25, and runs as a non-root user on port 6000. Compose passes the database as a JDBC URL with the same MANCALA_DB_PASSWORD.
15 lines
402 B
Java
15 lines
402 B
Java
package app.playmancala.live;
|
|
|
|
import java.util.Optional;
|
|
|
|
import com.fasterxml.jackson.core.type.TypeReference;
|
|
|
|
// Short-lived cache of JSON values. Never fails: errors count as a miss, so callers just compute the value.
|
|
public interface Cache {
|
|
<T> Optional<T> get(String key, TypeReference<T> type);
|
|
|
|
void set(String key, Object value, long ttlSeconds);
|
|
|
|
void delete(String... keys);
|
|
}
|