Skip to content

Commit a1521e0

Browse files
committed
update readme
1 parent dfbb084 commit a1521e0

File tree

3 files changed

+2
-201
lines changed

3 files changed

+2
-201
lines changed

docs/customruleguide.md

Lines changed: 0 additions & 135 deletions
This file was deleted.

flowhealthcheck-core.iml

Lines changed: 0 additions & 8 deletions
This file was deleted.

readme.md

Lines changed: 2 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ _An Extensible Rule Engine capable of conducting static analysis on the metadata
66
- [Core Functions](#core-functions)
77
- [Configurations](#configurations)
88
- [Rule Configuration](#rule-configuration)
9-
- [Custom Rule Interface](#custom-rule-interface)
109
- [Exception Configuration](#exception-configuration)
1110
- [Development Setup](#development-setup)
1211

@@ -147,65 +146,13 @@ Using the rules section of your configurations, you can specify the list of rule
147146
"rules": {
148147
"<RuleName>": {
149148
"severity": "<Severity>",
150-
"expression": "<Expression>",
151-
"path": "<Path>"
149+
"expression": "<Expression>"
152150
}
153151
}
154152
}
155153
```
156154

157-
### \*\*Beta\*\* Advanced Rule Configuration
158-
159-
Advanced rules provide granular control by allowing rules to be intentionally disabled at the rule level, ensuring consistent application across all flows. Additionally, the concept of suppressions is introduced, enabling users to "whitelist" specific components. This mechanism allows for exceptions to be defined, offering flexibility in rule enforcement while maintaining overall governance and compliance.
160-
161-
JSON
162-
163-
```json
164-
{
165-
"rules": {
166-
"<RuleName>": {
167-
"path": "local_path_of_your_js_file", // optional: when defined, this configuration will be used for the engine to recognize your custom rule
168-
"severity": "<User Configured Severity>",
169-
"expression": "<User Configured Expression which only applies to rules that take in `options`>",
170-
"disabled": "true", // optional: when true, rule will not be applied to all flows being scanned
171-
"suppressions": ["<User Configured Suppressions>"] // optional: when defined, takes an array of suppressed elements (not based on name but on specific type)
172-
}
173-
}
174-
}
175-
```
176-
177-
YAML
178-
179-
```yaml
180-
rules:
181-
MissingFaultPath: # User Defined Rule configuration
182-
path: "local_path_of_your_js_file" # Optional: when defined, this configuration will be used for the engine to recognize your rule
183-
severity: error # Optional: User Defined severity, can be `info`, `warn`, `error`
184-
expression: ">=58" # Optional: User defined expression, only applies if rule is Configurable=true
185-
disabled: "true" # Optional: when true, rule will not be applied to all flows being scanned
186-
suppressions: # Optional: when defined, takes an array of elements to be suppressed, keys can be found on suppressionElements on the rule definition
187-
- LogACall # Optional: when defined, rule engine will look at suppressionElement defined on the rule to match against this list
188-
```
189-
190-
- **Severity:**
191-
192-
- Optional values for severity are "error", "warning", and "note".
193-
- If severity is provided, it overwrites the default severity, which is "error".
194-
195-
- **Expression:**
196-
197-
- Expression is used to overwrite standard values in configurable rules.
198-
199-
- **Path:**
200-
201-
- If a path is provided, it can either replace an existing rule with a new rule definition or load a custom rule.
202-
- Ensure that the rule name used in the path matches the exported class name of the rule.
203-
204-
### Custom Rule Interface
205-
206-
To create custom rules that can be loaded using the path attribute of the rule configurations, they need to adhere to the IRuleInterface. Please refer to the _[Custom Rule Creation Guide](https://github.com/Lightning-Flow-Scanner/lightning-flow-scanner-core/tree/master/docs/customruleguide.md)_ for detailed instructions.
207-
208-
### Exception Configuration
155+
### \*\Exception Configuration
209156

210157
Specifying exceptions allows you to exclude specific scenarios from rule enforcement. Exceptions can be specified at the flow, rule, or result level to provide fine-grained control. Below is a breakdown of the available attributes of exception configuration:
211158

@@ -225,15 +172,12 @@ Specifying exceptions allows you to exclude specific scenarios from rule enforce
225172
```
226173

227174
- **FlowName:**
228-
229175
- The name of the flow where exceptions apply.
230176

231177
- **RuleName:**
232-
233178
- The name of the rule for which exceptions are defined.
234179

235180
- **ResultName:**
236-
237181
- The specific result or condition within the rule for which exceptions are specified.
238182

239183
## Development Setup

0 commit comments

Comments
 (0)