72 lines
1.2 KiB
Markdown
72 lines
1.2 KiB
Markdown
# Configuration Examples
|
|
|
|
## Default Cache (5 minutes)
|
|
```json
|
|
{
|
|
"github": {
|
|
"token": "ghp_your_github_token_here",
|
|
"repositories": [
|
|
{
|
|
"owner": "facebook",
|
|
"name": "react"
|
|
}
|
|
]
|
|
},
|
|
"server": {
|
|
"port": 3001,
|
|
"host": "0.0.0.0"
|
|
}
|
|
}
|
|
```
|
|
|
|
## Short Cache (1 minute)
|
|
```json
|
|
{
|
|
"github": {
|
|
"token": "ghp_your_github_token_here",
|
|
"repositories": [
|
|
{
|
|
"owner": "facebook",
|
|
"name": "react"
|
|
}
|
|
]
|
|
},
|
|
"server": {
|
|
"port": 3001,
|
|
"host": "0.0.0.0"
|
|
},
|
|
"cache": {
|
|
"timeoutMinutes": 1
|
|
}
|
|
}
|
|
```
|
|
|
|
## Long Cache (15 minutes)
|
|
```json
|
|
{
|
|
"github": {
|
|
"token": "ghp_your_github_token_here",
|
|
"repositories": [
|
|
{
|
|
"owner": "facebook",
|
|
"name": "react"
|
|
}
|
|
]
|
|
},
|
|
"server": {
|
|
"port": 3001,
|
|
"host": "0.0.0.0"
|
|
},
|
|
"cache": {
|
|
"timeoutMinutes": 15
|
|
}
|
|
}
|
|
```
|
|
|
|
## Cache Configuration Notes
|
|
|
|
- **timeoutMinutes**: Sets how long API responses are cached (in minutes)
|
|
- **Default**: 5 minutes if not specified
|
|
- **Range**: Any positive number (1 minute minimum recommended)
|
|
- **Live Reload**: Changes to cache timeout require server restart to take effect
|
|
- **Memory Usage**: Longer cache times = more memory usage but fewer API calls |