<?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>logic involved &#187; note to self</title> <atom:link href="http://www.coliena.com/blog/category/notetoself/feed/" rel="self" type="application/rss+xml" /><link>http://www.coliena.com/blog</link> <description>... more often than not ...</description> <lastBuildDate>Sat, 21 Jan 2012 18:09:36 +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>&#8220;unbound wildcard type&#8221; errors in Scala</title><link>http://www.coliena.com/blog/2011/02/unbound-wildcard-type-errors-in-scala/</link> <comments>http://www.coliena.com/blog/2011/02/unbound-wildcard-type-errors-in-scala/#comments</comments> <pubDate>Wed, 16 Feb 2011 17:36:17 +0000</pubDate> <dc:creator>niels</dc:creator> <category><![CDATA[development]]></category> <category><![CDATA[note to self]]></category> <category><![CDATA[scala]]></category><guid
isPermaLink="false">http://coliena.com/blog/?p=474</guid> <description><![CDATA[In Scala 2.8.1, I ran into problems while compiling this: object Test { def log(item: _) : Unit = println(&#34;you logged &#34; + item) &#160; def main(args: Array[String]) : Unit = { log(42) } } The error message wasn&#8217;t not helping that much at the first glance: /home/niels/tmp/test.scala:3: error: unbound wildcard type def log(item: _) [...]]]></description> <content:encoded><![CDATA[<p>In <a
href="http://www.scala-lang.org/">Scala 2.8.1</a>, I ran into problems while compiling this:</p><div
class="wp_syntax"><div
class="code"><pre class="text" style="font-family:monospace;">object Test
{
  def log(item: _) : Unit = 
    println(&quot;you logged &quot; + item)
&nbsp;
  def main(args: Array[String]) : Unit =
  {
    log(42)
  }
}</pre></div></div><p>The error message wasn&#8217;t not helping that much at the first glance:</p><div
class="wp_syntax"><div
class="code"><pre class="text" style="font-family:monospace;">/home/niels/tmp/test.scala:3: error: unbound wildcard type
	def log(item: _) : Unit = 
                      ^</pre></div></div><p>To fix it, change the prototype of the log function like this:</p><div
class="wp_syntax"><div
class="code"><pre class="text" style="font-family:monospace;">	def log(item: Any) : Unit =</pre></div></div><p>There is a pretty good overview of the Scala type hierarchy on the <a
href="http://www.scala-lang.org/node/128">Scala homepage</a>. In short, Scala Objects are subtypes of AnyRef. Primitive types (Int, Boolean, &#8230;) are subtypes of &#8220;AnyVal&#8221;. Both &#8220;AnyRef&#8221; and &#8220;AnyVal&#8221; are subtypes of &#8220;Any&#8221;, and substituting &#8220;Any&#8221; with &#8220;_&#8221; in prototypes and templates is not allowed in Scala 2.8.</p> ]]></content:encoded> <wfw:commentRss>http://www.coliena.com/blog/2011/02/unbound-wildcard-type-errors-in-scala/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Apples vs. Oranges</title><link>http://www.coliena.com/blog/2010/08/apples-vs-oranges/</link> <comments>http://www.coliena.com/blog/2010/08/apples-vs-oranges/#comments</comments> <pubDate>Thu, 19 Aug 2010 09:15:15 +0000</pubDate> <dc:creator>niels</dc:creator> <category><![CDATA[life out there]]></category> <category><![CDATA[note to self]]></category> <category><![CDATA[applesvsoranges]]></category><guid
isPermaLink="false">http://coliena.com/blog/?p=362</guid> <description><![CDATA[Apparently comparing apples and oranges makes sense after all: Apples and Oranges &#8212; A Comparison by Scott A. Sandford, NASA Ames Research Center, Mountain View, California]]></description> <content:encoded><![CDATA[<p>Apparently comparing apples and oranges makes sense after all:<br
/> <a
href="http://improb.com/airchives/paperair/volume1/v1i3/air-1-3-apples.html">Apples and Oranges &#8212; A Comparison by Scott A. Sandford, NASA Ames Research Center, Mountain View, California</a></p> ]]></content:encoded> <wfw:commentRss>http://www.coliena.com/blog/2010/08/apples-vs-oranges/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Fighting painfully slow SMB shares</title><link>http://www.coliena.com/blog/2008/10/fighting-painfully-slow-smb-shares/</link> <comments>http://www.coliena.com/blog/2008/10/fighting-painfully-slow-smb-shares/#comments</comments> <pubDate>Sun, 05 Oct 2008 19:26:55 +0000</pubDate> <dc:creator>niels</dc:creator> <category><![CDATA[helpdesk]]></category> <category><![CDATA[note to self]]></category><guid
isPermaLink="false">http://coliena.com/blog/?p=28</guid> <description><![CDATA[If you are running Vista or Mac OS X 10.5 / Leopard, you might have noticed that accessing files on Samba shares over your corporate network is dreadfully slow. Note that I&#8217;m not talking about network as in &#8220;my 10mbit Ethernet at home&#8221;, but as in &#8220;those strange fiber optic thingies running to my computer&#8221; [...]]]></description> <content:encoded><![CDATA[<p>If you are running Vista or Mac OS X 10.5 / Leopard, you might have noticed that accessing files on Samba shares over your corporate network is dreadfully slow. Note that I&#8217;m not talking about network as in &#8220;my 10mbit Ethernet at home&#8221;, but as in &#8220;those strange fiber optic thingies running to my computer&#8221; (even though the problem occurs on slower networks as well).</p><p>But why is Samba such a pain suddenly?<br
/> <span
id="more-28"></span></p><p>The short version: because Vista and Leopard have a different behind-the-scenes network config than XP and Tiger.</p><p>The long version: when you receive a file over a network, the file is chopped in packets, which are sent to your system one after the other. Whenever you have received a packet, you will send a notice of receipt to the server (&#8220;ok, I got packet XYZ, and it is intact&#8221;). Obviously, sending all these acknowledgments creates quite some traffic. That&#8217;s why Vista and Leopard use bulk acks: you don&#8217;t send an ack for every packet, but you wait until you have received (let&#8217;s say) 10 packets and send one ack for all of them.</p><p>And that &#8220;you wait until&#8221; is the tricky part. Because Samba is a synchronous protocol, the server won&#8217;t send the next packet until it has received the ack for the last.</p><p>Get the picture?<br
/> There&#8217;s a timeout, of course &#8211; your system won&#8217;t wait for eternity until it sends an ack for the &lt; 10 packets it had received. The timeout should be ~100ms on your system. But 1/10 of a second between each small packet sums up to a hell of a time.</p><p>And that&#8217;s why Samba can be really slow.</p><p>Now, the obvious solution to this problem is to use a shorter delayed ack. BUT DON&#8217;T PLAY WITH YOUR SYSTEM IF YOU DON&#8217;T KNOW EXACTLY WHAT YOU ARE DOING!</p><p>If you are running Windows, try this: <a
title="delayed ack on Win boxes" href="http://smallvoid.com/article/winnt-nagle-algorithm.html">set a delayed ack value in your registry</a>.</p><p>You are happily working on Mac OS X? Then enter this command:</p><pre>sudo sysctl -w net.inet.tcp.delayed_ack=0</pre>]]></content:encoded> <wfw:commentRss>http://www.coliena.com/blog/2008/10/fighting-painfully-slow-smb-shares/feed/</wfw:commentRss> <slash:comments>1</slash:comments> </item> <item><title>Using WebTest on sites with broken SSL certificates</title><link>http://www.coliena.com/blog/2008/09/using-webtest-on-sites-with-broken-ssl-certificates/</link> <comments>http://www.coliena.com/blog/2008/09/using-webtest-on-sites-with-broken-ssl-certificates/#comments</comments> <pubDate>Thu, 25 Sep 2008 16:24:52 +0000</pubDate> <dc:creator>niels</dc:creator> <category><![CDATA[development]]></category> <category><![CDATA[note to self]]></category><guid
isPermaLink="false">http://coliena.com/blog/?p=31</guid> <description><![CDATA[I really like Canoo WebTest for testing web user interfaces. And I&#8217;m delighted to see that Lee Butts found a way to test web sites with broken SSL certs Learn more about it at his blog.]]></description> <content:encoded><![CDATA[<p>I really like <a
title="Canoo WebTest" href="http://webtest.canoo.com">Canoo WebTest</a> for testing web user interfaces. And I&#8217;m delighted to see that <a
title="Lee Butts" href="http://www.leebutts.com" target="_blank">Lee Butts</a> found a way to test web sites with broken SSL certs <img
src='http://www.coliena.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /></p><p>Learn more about it at <a
title="leebutts.com" href="http://www.leebutts.com/2008/09/how-to-webtest-site-using-invalid-ssl.html">his blog</a>.</p> ]]></content:encoded> <wfw:commentRss>http://www.coliena.com/blog/2008/09/using-webtest-on-sites-with-broken-ssl-certificates/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> </channel> </rss>
<!-- Served from: www.coliena.com @ 2012-02-06 01:17:11 by W3 Total Cache -->
