forked from quarkusio/quarkus
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add the ability to inject configuration into build steps
- Loading branch information
1 parent
d4c26d0
commit 5095064
Showing
32 changed files
with
972 additions
and
542 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
47 changes: 47 additions & 0 deletions
47
agroal/runtime/src/main/java/org/jboss/shamrock/agroal/runtime/DataSourceConfig.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
package org.jboss.shamrock.agroal.runtime; | ||
|
||
import java.util.Optional; | ||
|
||
import org.eclipse.microprofile.config.inject.ConfigProperty; | ||
import org.jboss.shamrock.runtime.ConfiguredType; | ||
|
||
@ConfiguredType | ||
public class DataSourceConfig { | ||
|
||
/** | ||
* The datasource driver class name | ||
*/ | ||
@ConfigProperty(name = "driver") | ||
public String driver; | ||
|
||
/** | ||
* The datasource URL | ||
*/ | ||
@ConfigProperty(name = "url") | ||
public String url; | ||
|
||
/** | ||
* The datasource username | ||
*/ | ||
@ConfigProperty(name = "username") | ||
public Optional<String> user; | ||
|
||
/** | ||
* The datasource password | ||
*/ | ||
@ConfigProperty(name = "password") | ||
public Optional<String> password; | ||
|
||
/** | ||
* The datasource pool minimum size | ||
*/ | ||
@ConfigProperty(name = "minSize", defaultValue = "5") | ||
public int minSize; | ||
|
||
/** | ||
* The datasource pool maximum size | ||
*/ | ||
@ConfigProperty(name = "maxSize", defaultValue = "20") | ||
public int maxSize; | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.