Changeset 191
- Timestamp:
- 06/14/06 20:47:10 (3 years ago)
- Location:
- fusebox5
- Files:
-
- 4 modified
-
fusebox5.cfm (modified) (2 diffs)
-
fuseboxApplication.cfc (modified) (2 diffs)
-
myFusebox.cfc (modified) (3 diffs)
-
skeleton/fusebox.xml.cfm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
fusebox5/fusebox5.cfm
r189 r191 182 182 </cftry> 183 183 <!--- 184 must special case development- no-load mode since it causes circuits to reload during184 must special case development-circuit-load mode since it causes circuits to reload during 185 185 the compile (post-load) phase and therefore must be exclusive 186 186 ---> … … 188 188 <cfset request._fuseboxLog.trace("Fusebox","Compiling requested fuseaction '#attributes.fuseaction#'") /> 189 189 </cfif> 190 <cfif _fba.mode is "development- no-load">190 <cfif _fba.mode is "development-circuit-load"> 191 191 <cflock name="#application.ApplicationName#_fusebox_#FUSEBOX_APPLICATION_KEY#" type="exclusive" timeout="300"> 192 192 <cfset _parsedFileData = _fba.compileRequest(attributes.fuseaction,myFusebox) /> -
fusebox5/fuseboxApplication.cfc
r190 r191 494 494 detail="You specified a Circuit of #arguments.circuit# which is not defined." /> 495 495 </cfif> 496 <!--- FB5: development- no-load only reloads the requested circuit --->497 <cfif this.mode is "development- no-load">496 <!--- FB5: development-circuit-load only reloads the requested circuit ---> 497 <cfif this.mode is "development-circuit-load"> 498 498 <!--- FB5: ensure we only reload each circuit once per request ---> 499 499 <cfif not structKeyExists(request._fuseboxCircuitsLoaded,arguments.circuit)> … … 657 657 </cfif> 658 658 <cfset alias = children[i].xmlAttributes.alias /> 659 <!--- record each circuit load per request - optimization for development- no-load mode --->659 <!--- record each circuit load per request - optimization for development-circuit-load mode ---> 660 660 <cfset request._fuseboxCircuitsLoaded[alias] = true /> 661 661 <cfif structKeyExists(previousCircuits,alias) and -
fusebox5/myFusebox.cfc
r190 r191 65 65 this.parameters = structNew(); 66 66 67 // the basic default is development mode67 // the basic default is development-full-load mode: 68 68 this.parameters.load = true; 69 this.parameters.parse = true; 70 this.parameters.execute = true; 71 // FB5: new execution parameters: 69 72 this.parameters.clean = false; // don't delete parsed files by default 70 this.parameters.parse = true;71 73 this.parameters.parseall = false; // don't compile all fuseactions by default 72 this.parameters.execute = true;73 74 74 75 this.parameters.userProvidedLoadParameter = false; … … 102 103 <cfif structKeyExists(theFusebox,"mode")> 103 104 <cfswitch expression="#theFusebox.mode#"> 105 <!--- FB41 backward compatibility - now deprecated ---> 104 106 <cfcase value="development"> 107 <cfif structKeyExists(theFusebox,"strictMode") and theFusebox.strictMode> 108 <!--- since we don't load fusebox.xml if we throw an exception, we must fixup the value for the next run ---> 109 <cfset theFusebox.mode = "development-full-load" /> 110 <cfthrow type="fusebox.badGrammar.deprecated" 111 message="Deprecated feature" 112 detail="'development' is a deprecated execution mode - use 'development-full-load' instead." /> 113 </cfif> 105 114 <cfset this.parameters.load = true /> 106 115 <cfset this.parameters.parse = true /> 107 116 <cfset this.parameters.execute = true /> 108 117 </cfcase> 109 <!--- FB5: new option - loading is slower so it's worth not loading everything--->110 <cfcase value="development- no-load">111 <cfset this.parameters.load = false />118 <!--- FB5: replacement for old development mode ---> 119 <cfcase value="development-full-load"> 120 <cfset this.parameters.load = true /> 112 121 <cfset this.parameters.parse = true /> 113 122 <cfset this.parameters.execute = true /> 114 123 </cfcase> 115 <!--- FB5: new option - loading is slower so it's worth having a parse-only mode--->116 <cfcase value="development- parse-only">124 <!--- FB5: new option - does not load fusebox.xml and therefore does not (re-)load fuseboxApplication object ---> 125 <cfcase value="development-circuit-load"> 117 126 <cfset this.parameters.load = false /> 118 127 <cfset this.parameters.parse = true /> … … 124 133 <cfset this.parameters.execute = true /> 125 134 </cfcase> 135 <cfdefaultcase> 136 <!--- since we don't load fusebox.xml if we throw an exception, we must fixup the value for the next run ---> 137 <cfset theFusebox.mode = "development-full-load" /> 138 <cfthrow type="fusebox.badGrammar.invalidParameterValue" 139 message="Parameter has invalid value" 140 detail="The parameter 'mode' must be one of 'development-full-load', 'development-circuit-load' or 'production' in the fusebox.xml file." /> 141 </cfdefaultcase> 126 142 </cfswitch> 127 143 </cfif> -
fusebox5/skeleton/fusebox.xml.cfm
r186 r191 17 17 <parameters> 18 18 <parameter name="defaultFuseaction" value="app.welcome" /> 19 <!-- you probably want to change this to developmentmode: -->20 <parameter name="mode" value="development- no-load" />19 <!-- you may want to change this to development-full-load mode: --> 20 <parameter name="mode" value="development-circuit-load" /> 21 21 <!-- change this to something more secure: --> 22 22 <parameter name="password" value="skeleton" />
