Skip to content

Commit

Permalink
UNOMI-856: return all rules when calling /rules endpoints (#707)
Browse files Browse the repository at this point in the history
* UNOMI-856: return all rules when calling /rules endpoints

* UNOMI-856: add javadoc
  • Loading branch information
jsinovassin authored Nov 5, 2024
1 parent 97830e3 commit d6ee5bd
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public interface RulesService {

/**
* Retrieves the metadata for all known rules.
*
* Note that it only includes the rules in memory, not those persisted in storage.
* @return the Set of known metadata
*/
Set<Metadata> getRuleMetadatas();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public void setRulesService(RulesService rulesService) {

/**
* Retrieves the metadata for all known rules.
*
* Note that it only includes the rules in memory, not those persisted in storage.
* @return the Set of known metadata
*/
@GET
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ public void resetAllRuleStatistics() {

public Set<Metadata> getRuleMetadatas() {
Set<Metadata> metadatas = new HashSet<Metadata>();
for (Rule rule : persistenceService.getAllItems(Rule.class, 0, 50, null).getList()) {
for (Rule rule : allRules) {
metadatas.add(rule.getMetadata());
}
return metadatas;
Expand Down

0 comments on commit d6ee5bd

Please sign in to comment.