<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>gruchalski.com &#187; ColdFusion</title>
	<atom:link href="http://gruchalski.com/category/cfml/coldfusion/feed/" rel="self" type="application/rss+xml" />
	<link>http://gruchalski.com</link>
	<description>just another blog in all that noise...</description>
	<lastBuildDate>Tue, 20 Dec 2011 22:25:09 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>ColdFusion 9 crashing? Try different garbage collection</title>
		<link>http://gruchalski.com/2011/03/24/coldfusion-9-crashing-try-different-garbage-collection/</link>
		<comments>http://gruchalski.com/2011/03/24/coldfusion-9-crashing-try-different-garbage-collection/#comments</comments>
		<pubDate>Thu, 24 Mar 2011 17:30:17 +0000</pubDate>
		<dc:creator>radekg</dc:creator>
				<category><![CDATA[ColdFusion]]></category>

		<guid isPermaLink="false">http://gruchalski.com/?p=504</guid>
		<description><![CDATA[For the ICS application we are using ColdFusion 9. For quite a while we had a major problem. Our CF server kept crashing at least once a day without any warning. One minute it was running just fine, 30 seconds later all memory was consumed (3GB assigned for the JVM). Server was totally becoming unresponsive [...]]]></description>
			<content:encoded><![CDATA[<p>For the <a href="/2011/03/23/what-ive-been-up-to-for-over-3-5-years/">ICS</a> application we are using ColdFusion 9. For quite a while we had a major problem. Our CF server kept crashing at least once a day without any warning. One minute it was running just fine, 30 seconds later all memory was consumed (3GB assigned for the JVM). Server was totally becoming unresponsive and the only way to bring it back to life was restarting CF service.</p>
<p>FusionReactor was no help for us, nor memory snapshots. It looked like we were blind, couldn&#8217;t find the problem. The code was optimised as much as possible, we went through every query, created indexes on the databases, profiled it, var&#8217;d all variables in the CFCs and so on &#8211; nothing was helping. And then finally, Saturday morning that was, a breakthrough: there&#8217;s clearly a problem with garbage collection (how obvious was that…), how can we tune it? Turns out that JVM supports 3 different collectors: throughput (-XX:+UseParallelGC), concurrent (-XX:+UseConcMarkSweepGC) and incremental (-XX:+UseTrainGC) &#8211; here&#8217;s the details <a href="http://www.oracle.com/technetwork/java/gc-tuning-5-138395.html">&#8220;Tuning Garbage Collection with the 5.0 Java[tm] Virtual Machine&#8221;</a>. My first thought was that we may have problems because we&#8217;re running in a VM, each of those VMs has 4 virtual CPUs assigned. According to the JVM docs we should have 4 collector threads by default. Somehow, at some point they were all failing to collect. So I changed the collector to concurrent and since then, about 5 weeks ago we had no crashes at all.</p>
<p>This is what I&#8217;m using for JVM settings:</p>
<p><code>-server -Dsun.io.useCanonCaches=false -XX:MaxPermSize=192m -XX:+UseConcMarkSweepGC -Xbatch -Dcoldfusion.rootDir={application.home}/../ -Dcoldfusion.libPath={application.home}/../lib -XX:+HeapDumpOnOutOfMemoryError -XX:MinHeapFreeRatio=10 -XX:MaxHeapFreeRatio=20</code></p>
]]></content:encoded>
			<wfw:commentRss>http://gruchalski.com/2011/03/24/coldfusion-9-crashing-try-different-garbage-collection/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>ColdFusion compiler is broken</title>
		<link>http://gruchalski.com/2009/09/22/coldfusion-compiler-is-broken/</link>
		<comments>http://gruchalski.com/2009/09/22/coldfusion-compiler-is-broken/#comments</comments>
		<pubDate>Tue, 22 Sep 2009 10:09:33 +0000</pubDate>
		<dc:creator>radekg</dc:creator>
				<category><![CDATA[ColdFusion]]></category>

		<guid isPermaLink="false">http://gruchalski.com/?p=363</guid>
		<description><![CDATA[Following on a tweet from Sean Corfield, I couldn&#8217;t believe it is possible to create a function called if, else, while and so on as well as declare variable called var. Here is the code that may hurt your head: [sourcecode lang="cf"] &#60;cffunction name=&#34;if&#34;&#62; &#60;cfargument name=&#34;val1&#34; /&#62; &#60;cfargument name=&#34;val2&#34; /&#62; &#60;cfif val1 eq val2&#62; &#60;cfreturn [...]]]></description>
			<content:encoded><![CDATA[<p>Following on <a href="http://twitter.com/seancorfield/status/4113568458">a tweet</a> from Sean Corfield, I couldn&#8217;t believe it is possible to create a function called <em>if</em>, <em>else</em>, <em>while</em> and so on as well as declare variable called <em>var</em>. Here is the code that may hurt your head:</p>
<pre>[sourcecode lang="cf"]
&lt;cffunction name=&quot;if&quot;&gt;
	&lt;cfargument name=&quot;val1&quot; /&gt;
	&lt;cfargument name=&quot;val2&quot; /&gt;
	&lt;cfif val1 eq val2&gt;
		&lt;cfreturn true /&gt;
	&lt;/cfif&gt;
	&lt;cfreturn false /&gt;
&lt;/cffunction&gt;
&lt;cffunction name=&quot;hello&quot;&gt;
	&lt;cfset var var = 2 /&gt;
	&lt;cfreturn var /&gt;
&lt;/cffunction&gt;
&lt;cfif if( hello(), 2 )&gt;
	LOL
&lt;/cfif&gt;
[/sourcecode]</pre>
<p>How cool is that ;)</p>
]]></content:encoded>
			<wfw:commentRss>http://gruchalski.com/2009/09/22/coldfusion-compiler-is-broken/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>ColdFusion to Flex serializer needs better error messages</title>
		<link>http://gruchalski.com/2009/09/02/coldfusion-to-flex-serializer-needs-better-error-messages/</link>
		<comments>http://gruchalski.com/2009/09/02/coldfusion-to-flex-serializer-needs-better-error-messages/#comments</comments>
		<pubDate>Wed, 02 Sep 2009 09:44:03 +0000</pubDate>
		<dc:creator>radekg</dc:creator>
				<category><![CDATA[Adobe Flex/AIR]]></category>
		<category><![CDATA[ColdFusion]]></category>
		<category><![CDATA[Moan]]></category>

		<guid isPermaLink="false">http://gruchalski.com/?p=353</guid>
		<description><![CDATA[I&#8217;m using Flex with ColdFusion for a long time now but sometimes I really can&#8217;t stand these two products together. I&#8217;m sending nested CFCs through the remote object back to Flex so ColdFusion has to serialize them to the form that may be understood by Flex. But I&#8217;ve got an error, somewhere I have an [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m using Flex with ColdFusion for a long time now but sometimes I really can&#8217;t stand these two products together. I&#8217;m sending nested CFCs through the remote object back to Flex so ColdFusion has to serialize them to the form that may be understood by Flex. But I&#8217;ve got an error, somewhere I have an empty string where number is expected. You would expect that CF is smart enough to tell you what the problem is? Nope, it says:</p>
<p><code>Unable to invoke CFC - The value '' cannot be converted to a number.</code></p>
<p>And here is the stack trace:</p>
<pre>[sourcecode lang="cf"]
        [0] &quot;coldfusion.runtime.Cast._double(Cast.java:652)&quot;
        [1] &quot;coldfusion.runtime.Cast._double(Cast.java:632)&quot;
        [2] &quot;coldfusion.runtime.Cast._double(Cast.java:786)&quot;
        [3] &quot;coldfusion.flash.messaging.io.amf.Translator.CFASSerializer.translate(CFASSerializer.java:545)&quot;
        [4] &quot;coldfusion.flash.messaging.io.amf.Translator.CFASSerializer.translate(CFASSerializer.java:494)&quot;
        [5] &quot;coldfusion.flash.messaging.io.amf.Translator.CFASSerializer.translate(CFASSerializer.java:387)&quot;
        [6] &quot;coldfusion.flash.messaging.io.amf.Translator.CFASSerializer.translate(CFASSerializer.java:81)&quot;
        [7] &quot;coldfusion.flash.messaging.io.amf.Translator.CFASSerializer.translate(CFASSerializer.java:512)&quot;
        [8] &quot;coldfusion.flash.messaging.io.amf.Translator.CFASSerializer.translate(CFASSerializer.java:494)&quot;
        [9] &quot;coldfusion.flash.filter.CFCInvokeFilter.invoke(CFCInvokeFilter.java:160)&quot;
        [10] &quot;coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:279)&quot;
        [11] &quot;coldfusion.filter.MonitoringFilter.invoke(MonitoringFilter.java:40)&quot;
        [12] &quot;coldfusion.flash.filter.CFCInvokeDebugFilter.invoke(CFCInvokeDebugFilter.java:54)&quot;
        [13] &quot;coldfusion.flash.filter.CFCInvokePathFilter.invoke(CFCInvokePathFilter.java:70)&quot;
        [14] &quot;coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilter.java:28)&quot;
        [15] &quot;coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)&quot;
        [16] &quot;coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22)&quot;
        [17] &quot;coldfusion.flash.messaging.ColdFusionAdapter.invoke(ColdFusionAdapter.java:223)&quot;
        [18] &quot;flex.messaging.services.RemotingService.serviceMessage(RemotingService.java:173)&quot;
        [19] &quot;flex.messaging.MessageBroker.routeMessageToService(MessageBroker.java:1165)&quot;
        [20] &quot;flex.messaging.endpoints.AbstractEndpoint.serviceMessage(AbstractEndpoint.java:757)&quot;
        [21] &quot;flex.messaging.endpoints.amf.MessageBrokerFilter.invoke(MessageBrokerFilter.java:117)&quot;
        [22] &quot;flex.messaging.endpoints.amf.LegacyFilter.invoke(LegacyFilter.java:158)&quot;
        [23] &quot;flex.messaging.endpoints.amf.SessionFilter.invoke(SessionFilter.java:48)&quot;
        [24] &quot;flex.messaging.endpoints.amf.BatchProcessFilter.invoke(BatchProcessFilter.java:67)&quot;
        [25] &quot;flex.messaging.endpoints.amf.SerializationFilter.invoke(SerializationFilter.java:145)&quot;
        [26] &quot;flex.messaging.endpoints.AMFEndpoint.service(AMFEndpoint.java:122)&quot;
        [27] &quot;flex.messaging.MessageBrokerServlet.service(MessageBrokerServlet.java:438)&quot;
        [28] &quot;coldfusion.flex.ColdFusionMessageBrokerServlet.service(ColdFusionMessageBrokerServlet.java:50)&quot;
        [29] &quot;javax.servlet.http.HttpServlet.service(HttpServlet.java:853)&quot;
        [30] &quot;coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:89)&quot;
        [31] &quot;jrun.servlet.FilterChain.doFilter(FilterChain.java:86)&quot;
        [32] &quot;coldfusion.filter.FlashRequestControlFilter.doFilter(FlashRequestControlFilter.java:71)&quot;
        [33] &quot;coldfusion.bootstrap.BootstrapFilter.doFilter(BootstrapFilter.java:46)&quot;
        [34] &quot;jrun.servlet.FilterChain.doFilter(FilterChain.java:94)&quot;
        [35] &quot;jrun.servlet.FilterChain.service(FilterChain.java:101)&quot;
        [36] &quot;jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:106)&quot;
        [37] &quot;jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)&quot;
        [38] &quot;jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:286)&quot;
        [39] &quot;jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:543)&quot;
        [40] &quot;jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.java:203)&quot;
        [41] &quot;jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPool.java:320)&quot;
        [42] &quot;jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:428)&quot;
        [43] &quot;jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool.java:266)&quot;
        [44] &quot;jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)&quot;
[/sourcecode]</pre>
<p>Helpful, heh?</p>
<p>Why, WHY! it does not say what property is causing the problem? Surely it knows, it just keeps it for itself. Adobe &#8211; please fix!</p>
]]></content:encoded>
			<wfw:commentRss>http://gruchalski.com/2009/09/02/coldfusion-to-flex-serializer-needs-better-error-messages/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

