Skip to content

Commit

Permalink
## v3.1.0
Browse files Browse the repository at this point in the history
- Updated all skeletons to more ColdBox 7 goodness
  • Loading branch information
lmajano committed May 9, 2023
1 parent 638574d commit ebe93f9
Show file tree
Hide file tree
Showing 11 changed files with 376 additions and 217 deletions.
4 changes: 4 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## v3.1.0

- Updated all skeletons to more ColdBox 7 goodness

## v3.0.0

- Updates for ColdBox 7
Expand Down
3 changes: 2 additions & 1 deletion messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@
"2.4.0": "changelog.md",
"2.6.0": "changelog.md",
"2.7.0": "changelog.md",
"3.0.0": "changelog.md"
"3.0.0": "changelog.md",
"3.1.0": "changelog.md"
}
3 changes: 2 additions & 1 deletion readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ Code completion for all major ColdBox + TestBox functions and scopes:

### Code Skeleton Snippets

- `apiResourceHandler` : Creates a ColdBox API Resource Handler
- `cachebox-config ➝` : Creates a new CacheBox.cfc configuration file
- `config ➝` : Creates a new ColdBox.cfc configuration file
- `cfc ➝` : Creates a new ColdFusion script CFC
Expand All @@ -42,6 +43,7 @@ Code completion for all major ColdBox + TestBox functions and scopes:
- `property ➝` : Creates a new ColdFusion script property
- `routes ➝` : Creates a new routing file
- `resthandler ➝` : Creates a ColdBox Rest Handler
- `resourcehandler` : Creates a ColdBox Resource Handler
- `unit ➝` : Creates a TestBox TDD xUnit Bundle

### Handler Code Snippets
Expand Down Expand Up @@ -100,7 +102,6 @@ Code completion for all major ColdBox + TestBox functions and scopes:

### ColdBox Testing Snippets

- `handlerTest ➝` : Creates a ColdBox Event Handler test case
- `integration ➝` : Creates a top down integration BDD test case
- `interceptorTest ➝` : Creates an Interceptor test case
- `modelTest ➝` : Creates a model test case
Expand Down
107 changes: 61 additions & 46 deletions skeletons/CacheBox.sublime-snippet
Original file line number Diff line number Diff line change
@@ -1,58 +1,73 @@
<snippet>
<content><![CDATA[
/**
* CacheBox Configuration File
*/
component{
component {
/**
* Configure CacheBox for ColdBox Application Operation
*/
function configure(){
// The CacheBox configuration structure DSL
/**
* --------------------------------------------------------------------------
* CacheBox Configuration (https://cachebox.ortusbooks.com)
* --------------------------------------------------------------------------
*/
cacheBox = {
// LogBox config already in coldbox app, not needed
// logBoxConfig = "coldbox.system.web.config.LogBox",
// The defaultCache has an implicit name "default" which is a reserved cache name
// It also has a default provider of cachebox which cannot be changed.
// All timeouts are in minutes
defaultCache = {
objectDefaultTimeout = 120, //two hours default
objectDefaultLastAccessTimeout = 30, //30 minutes idle time
useLastAccessTimeouts = true,
reapFrequency = 2,
freeMemoryPercentageThreshold = 0,
evictionPolicy = "LRU",
evictCount = 1,
maxObjects = 300,
objectStore = "ConcurrentStore", //guaranteed objects
coldboxEnabled = true
/**
* --------------------------------------------------------------------------
* Default Cache Configuration
* --------------------------------------------------------------------------
* The defaultCache has an implicit name "default" which is a reserved cache name
* It also has a default provider of cachebox which cannot be changed.
* All timeouts are in minutes
*/
defaultCache : {
objectDefaultTimeout : 120, // two hours default
objectDefaultLastAccessTimeout : 30, // 30 minutes idle time
useLastAccessTimeouts : true,
reapFrequency : 5,
freeMemoryPercentageThreshold : 0,
evictionPolicy : "LRU",
evictCount : 1,
maxObjects : 300,
objectStore : "ConcurrentStore", // guaranteed objects
coldboxEnabled : true
},
// Register all the custom named caches you like here
caches = {
// Named cache for all coldbox event and view template caching
template = {
provider = "coldbox.system.cache.providers.CacheBoxColdBoxProvider",
properties = {
objectDefaultTimeout = 120,
objectDefaultLastAccessTimeout = 30,
useLastAccessTimeouts = true,
freeMemoryPercentageThreshold = 0,
reapFrequency = 2,
evictionPolicy = "LRU",
evictCount = 2,
maxObjects = 300,
objectStore = "ConcurrentSoftReferenceStore" //memory sensitive
/**
* --------------------------------------------------------------------------
* Custom Cache Regions
* --------------------------------------------------------------------------
* You can use this section to register different cache regions and map them
* to different cache providers
*/
caches : {
/**
* --------------------------------------------------------------------------
* ColdBox Template Cache
* --------------------------------------------------------------------------
* The ColdBox Template cache region is used for event/view caching and
* other internal facilities that might require a more elastic cache.
*/
template : {
provider : "coldbox.system.cache.providers.CacheBoxColdBoxProvider",
properties : {
objectDefaultTimeout : 120,
objectDefaultLastAccessTimeout : 30,
useLastAccessTimeouts : true,
freeMemoryPercentageThreshold : 0,
reapFrequency : 5,
evictionPolicy : "LRU",
evictCount : 2,
maxObjects : 300,
objectStore : "ConcurrentSoftReferenceStore" // memory sensitive
}
}
}
}
}
};
}
}
}
]]></content>
<tabTrigger>cachebox-config</tabTrigger>
<scope>source,text</scope>
<description>CacheBox Configuration File (CaceBox.cfc)</description>
</snippet>
</snippet>
Loading

0 comments on commit ebe93f9

Please sign in to comment.