Skip to content

Commit

Permalink
Rename AWS AppConfig as artifactId avaje-aws-appconfig
Browse files Browse the repository at this point in the history
  • Loading branch information
rbygrave committed Feb 4, 2024
1 parent 45716b7 commit 4201562
Show file tree
Hide file tree
Showing 7 changed files with 22 additions and 14 deletions.
10 changes: 8 additions & 2 deletions avaje-aws-appconfig/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,20 @@
</parent>

<groupId>io.avaje</groupId>
<artifactId>avaje-config-aws-appconfig</artifactId>
<version>0.3</version>
<artifactId>avaje-aws-appconfig</artifactId>
<version>0.4</version>

<properties>
<surefire.useModulePath>false</surefire.useModulePath>
</properties>

<dependencies>
<dependency>
<groupId>io.avaje</groupId>
<artifactId>avaje-applog</artifactId>
<version>1.0</version>
</dependency>

<dependency>
<groupId>io.avaje</groupId>
<artifactId>avaje-config</artifactId>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.avaje.config.awsappconfig;
package io.avaje.config.appconfig;

interface AppConfigFetcher {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package io.avaje.config.awsappconfig;
package io.avaje.config.appconfig;

import io.avaje.applog.AppLog;
import io.avaje.config.ConfigParser;
import io.avaje.config.Configuration;
import io.avaje.config.ConfigurationSource;
Expand All @@ -17,9 +18,9 @@
* <p>
* By default, will periodically reload the configuration if it has changed.
*/
public final class AwsAppConfigPlugin implements ConfigurationSource {
public final class AppConfigPlugin implements ConfigurationSource {

private static final System.Logger log = System.getLogger("io.avaje.config.AwsAppConfig");
private static final System.Logger log = AppLog.getLogger("io.avaje.config.AwsAppConfig");

private Loader loader;

Expand Down Expand Up @@ -86,7 +87,7 @@ void reload() {
}

private boolean reloadRequired() {
return validUntil.get().isAfter(Instant.now());
return validUntil.get().isBefore(Instant.now());
}

private void performReload() {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.avaje.config.awsappconfig;
package io.avaje.config.appconfig;

import java.io.IOException;
import java.net.URI;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package io.avaje.config.awsappconfig;
package io.avaje.config.appconfig;

final class DResult implements AppConfigFetcher.Result {

Expand Down
9 changes: 5 additions & 4 deletions avaje-aws-appconfig/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import io.avaje.config.awsappconfig.AwsAppConfigPlugin;
import io.avaje.config.appconfig.AppConfigPlugin;

module io.avaje.config.awsappconfig {
module io.avaje.config.appconfig {

exports io.avaje.config.awsappconfig;
exports io.avaje.config.appconfig;

requires io.avaje.config;
requires java.net.http;
provides io.avaje.config.ConfigurationSource with AwsAppConfigPlugin;
requires transitive io.avaje.applog;
provides io.avaje.config.ConfigurationSource with AppConfigPlugin;
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
io.avaje.config.awsappconfig.AwsAppConfigPlugin
io.avaje.config.appconfig.AppConfigPlugin

0 comments on commit 4201562

Please sign in to comment.