-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reorganize Hibernate Search management config
While it's working fine with the new annotation processor, the config is not ordered the same and it's better displayed as a section. Also it looks a bit odd to have a specific root just for that.
- Loading branch information
Showing
5 changed files
with
17 additions
and
18 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
9 changes: 2 additions & 7 deletions
9
...arkus/hibernate/search/orm/elasticsearch/deployment/HibernateSearchManagementEnabled.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 |
---|---|---|
@@ -1,25 +1,20 @@ | ||
package io.quarkus.hibernate.search.orm.elasticsearch.deployment; | ||
|
||
import io.quarkus.hibernate.search.orm.elasticsearch.runtime.HibernateSearchElasticsearchBuildTimeConfig; | ||
import io.quarkus.hibernate.search.orm.elasticsearch.runtime.management.HibernateSearchManagementConfig; | ||
|
||
/** | ||
* Supplier that can be used to only run build steps | ||
* if the Hibernate Search extension and its management is enabled. | ||
*/ | ||
public class HibernateSearchManagementEnabled extends HibernateSearchEnabled { | ||
|
||
private final HibernateSearchManagementConfig config; | ||
|
||
HibernateSearchManagementEnabled(HibernateSearchElasticsearchBuildTimeConfig config, | ||
HibernateSearchManagementConfig managementConfig) { | ||
HibernateSearchManagementEnabled(HibernateSearchElasticsearchBuildTimeConfig config) { | ||
super(config); | ||
this.config = managementConfig; | ||
} | ||
|
||
@Override | ||
public boolean getAsBoolean() { | ||
return super.getAsBoolean() && config.enabled(); | ||
return super.getAsBoolean() && config.management().enabled(); | ||
} | ||
|
||
} |
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
11 changes: 4 additions & 7 deletions
11
...ment/HibernateSearchManagementConfig.java → ...asticsearchBuildTimeConfigManagement.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