Coldfusion Snippet: Make a sleep timer using Java
I have also included a copy-paste snippet of my actual CFC function.
The snippet is actually very simple:
<cfset thread.sleep(arguments.milliseconds)>
Category Filtering: 'coldfusion'
I have also included a copy-paste snippet of my actual CFC function.
The snippet is actually very simple:
<cfset thread.sleep(arguments.milliseconds)>
The method is self explanatory. You send in some ErrorDetails, the cfcatch structure, and application(cfc) name. The method will then construct a variable using cfsavecontent with the bug report and creates a LogFile in the coldfusion administrator. It then finally sends the bugreport to the email list that you can provide in the constructor of the cfc.
He has created a CFDOCS bot using CFMX7 event gateways. You can find the information here.
I have been using it now everyday. It is an incredible and quick way of getting CFMX function and tag information.
A true indispensable Coldfusion Developer Tool.
Thanks Ben!!
Most of the time the programatic approach will work, but sometimes these little bastards persist. So you have to follow a procedure and clean them out. Below you will find the programmatic way first:
action="Create"
name="factory"
class="coldfusion.server.ServiceFactory">
<cfset RpcService = factory.XmlRpcService>
<cfset RpcService.refreshWebService("http://testwebsite/webservice/myservice.cfc?wsdl")>
<cfset inet = inet.getLocalHost()>
<cfoutput>#inet.getHostName()#</cfoutput>
I would not recommend the first solution on a production environment, due to the nature of somebody peaking in to your requests and responses. However, for development is fine. So to start, find the following file: flex-config.xml which can be found under the following directory:
{CF_ROOT}/WEB-INF/cfform/flex-config.xml
Open the xml file and locate the following section:
<!-- When production-mode=true, the debugging options are always
false and may not be set. -->
<debugging>
<!-- allow override of values in debugging section via
query parameter on a per-request basis, if applicable -->
<process-debug-query-params>true</process-debug-query-params>
......
</debugging>
This is the flex debuggin configuration. So in order to activate the debugger change the following entries to true.
as debug information in client side tracing -->
<remote-objects-debug>false</remote-objects-debug>
<!-- turn on debug to see the request and response on the server side as well
as debug information in client side tracing -->
<web-service-proxy-debug>false</web-service-proxy-debug>
<!-- turn on debug to see the request and response on the server side -->
<http-service-proxy-debug>false</http-service-proxy-debug>
It is a great tool, a basic plug and play application. However, I took the liberty of modifying some of the Look And Feel. I created a new podlayout on the left and use my own site's css. And well, added a few tweaks here and there.
Overall BlogCFC is an incredible tool. As a software engineer I found the code to be extremely well organized and everything where it should be. So a big applause for Mr Ray Camden.
I will start posting my software ideas and personal notes in this blog, so feel free to comment all you want. Suggestions are always welcomed.