<?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>thatmattbone.com &#187; erlang-in-lisp</title>
	<atom:link href="http://thatmattbone.com/tag/erlang-in-lisp/feed/" rel="self" type="application/rss+xml" />
	<link>http://thatmattbone.com</link>
	<description></description>
	<lastBuildDate>Sat, 07 Jan 2012 01:20:49 +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>erlang-in-lisp user manual now useful</title>
		<link>http://thatmattbone.com/2008/08/erlang-in-lisp-user-manual-now-useful/</link>
		<comments>http://thatmattbone.com/2008/08/erlang-in-lisp-user-manual-now-useful/#comments</comments>
		<pubDate>Mon, 18 Aug 2008 19:02:00 +0000</pubDate>
		<dc:creator>Matt Bone</dc:creator>
				<category><![CDATA[erlang-in-lisp]]></category>

		<guid isPermaLink="false">http://thatmattbone.com/?p=48</guid>
		<description><![CDATA[<a href="http://thatmattbone.com/2008/08/erlang-in-lisp-user-manual-now-useful/" title="erlang-in-lisp user manual now useful"></a>Most of the Erlang-in-Lisp issues discussed here and on the mailing list this summer have been rolled into the user manual in some form. Get it here in pdf format or here in HTML.]]></description>
			<content:encoded><![CDATA[<a href="http://thatmattbone.com/2008/08/erlang-in-lisp-user-manual-now-useful/" title="erlang-in-lisp user manual now useful"></a><p>Most of the Erlang-in-Lisp issues discussed here and on the mailing list this summer have been rolled into the user manual in some form.  Get it <a href="http://common-lisp.net/project/erlang-in-lisp/manual/manual.pdf">here in pdf format</a> or <a href="http://common-lisp.net/project/erlang-in-lisp/manual/manual.html">here in HTML</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://thatmattbone.com/2008/08/erlang-in-lisp-user-manual-now-useful/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>links, timeouts, and refactoring</title>
		<link>http://thatmattbone.com/2008/07/links-timeouts-and-refactoring/</link>
		<comments>http://thatmattbone.com/2008/07/links-timeouts-and-refactoring/#comments</comments>
		<pubDate>Wed, 30 Jul 2008 15:55:00 +0000</pubDate>
		<dc:creator>Matt Bone</dc:creator>
				<category><![CDATA[erlang-in-lisp]]></category>

		<guid isPermaLink="false">http://thatmattbone.com/?p=47</guid>
		<description><![CDATA[<a href="http://thatmattbone.com/2008/07/links-timeouts-and-refactoring/" title="links, timeouts, and refactoring"></a>First off, I have added some support for timeouts in receive blocks (in erlang this is done with the &#8216;after&#8217; block). For now this is only supported on the unix-process implementation, but should be easy to implement. While I know &#8230;<p class="read-more"><a href="http://thatmattbone.com/2008/07/links-timeouts-and-refactoring/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://thatmattbone.com/2008/07/links-timeouts-and-refactoring/" title="links, timeouts, and refactoring"></a><p>First off, I have added some support for timeouts in receive blocks (in erlang this is done with the &#8216;after&#8217; block).  For now this is only supported on the unix-process implementation, but should be easy to implement.  While I know that the timeouts are &#8216;soft&#8217; I do wonder how they are implemented in Erlang.  For example, does the timeout usually just measure the amount of time spent blocking, or does it include the amount of time spent searching messages already in the process&#8217; mailbox (which could be lengthy if the process has accumulated large amounts of messages for whatever reason).</p>
<p>There is also some preliminary support for process linking.  More specifically, if one process is linked to another, it behaves like an Erlang system process and is notified via a message if the other linked process experiences an error.  </p>
<p>Also there has been some seriuos refactoring.  Much like the Closette implementation discussed in The Art of the Metaobject protocol, the implementation of erlang-in-lisp is separated into a thin macro-layer and a heavier layer based on generic functions (thus most behavior can be overridden if necessary).  The thin macro layer is where something like muproc compatibility would be implemented.  It is essentially the public facing side of erlang-in-lisp.  The generic function layer is for those wishing to extend the functionality of erlang-in-lisp by, for example, introducing a new concurrency strategy.  </p>
<p>On Monday the erlang-in-lisp operation is moving to Bloomington, Indiana.  I&#8217;ll even be able to write code in my new backyard (or on top of my in-apartment washer and dryer!).</p>
]]></content:encoded>
			<wfw:commentRss>http://thatmattbone.com/2008/07/links-timeouts-and-refactoring/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>midterm report</title>
		<link>http://thatmattbone.com/2008/07/midterm-report/</link>
		<comments>http://thatmattbone.com/2008/07/midterm-report/#comments</comments>
		<pubDate>Wed, 09 Jul 2008 17:07:00 +0000</pubDate>
		<dc:creator>Matt Bone</dc:creator>
				<category><![CDATA[erlang-in-lisp]]></category>

		<guid isPermaLink="false">http://thatmattbone.com/?p=46</guid>
		<description><![CDATA[<a href="http://thatmattbone.com/2008/07/midterm-report/" title="midterm report"></a>What has been accomplished?EiL has an implementation of the actors model as illustrated in Erlang. New processes can be spawned, and with the send() and receive() primitives these processes can communicate via message passing. While the spawning of processes is &#8230;<p class="read-more"><a href="http://thatmattbone.com/2008/07/midterm-report/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://thatmattbone.com/2008/07/midterm-report/" title="midterm report"></a><p><span style="font-size:130%;">What has been accomplished?</span><br />EiL has an implementation of the actors model as illustrated in Erlang.  New processes can be spawned, and with the send() and receive() primitives these processes can communicate via message passing.  While the spawning of processes is currently limited to a single machine (i.e. not distributed), distribution is possible if processes are spawned by hand on remote machines.  Erlang style process registration (mapping a particular process to a name) is supported and is in fact written in EiL using the send() and receive() primitives.</p>
<p>Currently EiL contains two concurrency strategies: unix processes and threads.  The decision about which concurrency mechanism to use must be made when EiL is started, and thus the two concurrency strategies cannot be mixed at the moment (some changes to the API should make this possible, and this should be a goal). However, programs written for EiL are unaware of the underlying concurrency mechanism.  For example, to run the ping-pong example with unix-process based concurrency we simply:</p>
<p><span style="font-family: courier new;">ERLANG-IN-LISP> (toplevel :process-class &#8216;unix-process)</span><br /><span style="font-family: courier new;">ERLANG-IN-LISP> (ping-pong 3)</span><br /><span style="font-family: courier new;">&#8230;&#8230;</span><br /><span style="font-family: courier new;">ERLANG-IN-LISP> (toplevel-exit)</span></p>
<p>To use thread-based concurrency we need only change the keyword to the toplevel function:</p>
<p><span style="font-family: courier new;">ERLANG-IN-LISP> (toplevel :process-class &#8216;thread-process)</span></p>
<p>Thus the goal of pluggable concurrency as described in the original proposal has been accomplished.  To a certain extent, so has the goal of pluggable messaging.  However, messaging is tightly coupled to the concurrency mechanism (i.e. processes serialize messages and communicate via sockets while threads simply exchange references to the messages in memory).  Truly pluggable messaging is best left to each concurrency strategy (as opposed to introducing another layer of abstraction).  Thus unix-processes may choose to communicate via secure or unsecure sockets while these options would be unavailable to threads.</p>
<p><span style="font-size:130%;">What remains to be accomplished?</span><br />Much remains to be accomplished.  Most important is linked processes.  I believe this can be accomplished by relying on the Common Lisp condition system.  Processes will maintain a link set as in Erlang, and conditions will be handled and forwarded via the messaging primitives to interested processes.  While I have sketched out a plan to this end, no code has yet been written.</p>
<p>True distribution including the remote spawning of processes remains as well.  The main sticking point is how to serialize closures and ship them off to a remote system.  While we can easily send a function name and the required arguments to a remote process and hope that the remote process knows about that function, this is not ideal (and, in fact spawn() only takes a thunk at the moment, so we&#8217;d need to figure out how to serialize an anonymous function to capture these arguments&#8230;that or have two separate APIs like spawn() and remote-spawn()).  We may also wish to generate bindings for the erl_interface so that EiL nodes and code written in EiL can play nicely in an Erlang cluster.</p>
<p>Finally, our ultimate goal of compiling Erlang to EiL remains.  To this end, we should focus on compiling Core Erlang only.  It may be helpful to develop &#8216;core EiL&#8217; and then build a Lispier macro-based front end for user consumption.</p>
]]></content:encoded>
			<wfw:commentRss>http://thatmattbone.com/2008/07/midterm-report/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>serializing continuations</title>
		<link>http://thatmattbone.com/2008/07/serializing-continuations/</link>
		<comments>http://thatmattbone.com/2008/07/serializing-continuations/#comments</comments>
		<pubDate>Mon, 07 Jul 2008 20:58:00 +0000</pubDate>
		<dc:creator>Matt Bone</dc:creator>
				<category><![CDATA[erlang-in-lisp]]></category>

		<guid isPermaLink="false">http://thatmattbone.com/?p=45</guid>
		<description><![CDATA[<a href="http://thatmattbone.com/2008/07/serializing-continuations/" title="serializing continuations"></a>Some people in the weblocks community have been thinking about some of the things I&#8217;ve been pondering. No real answers. I need to play with the continuations in arnesi and cl-cont, but if we can&#8217;t move them between address spaces &#8230;<p class="read-more"><a href="http://thatmattbone.com/2008/07/serializing-continuations/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://thatmattbone.com/2008/07/serializing-continuations/" title="serializing continuations"></a><p>Some people in the weblocks community <a href="http://groups.google.com/group/weblocks/browse_thread/thread/93fd60a7c8ab802d/c51a12c6755031e3?lnk=gst&amp;q=serialize+continuation">have been thinking about</a> some of the things I&#8217;ve been pondering.  No real answers.  I need to play with the continuations in arnesi and cl-cont, but if we can&#8217;t move them between address spaces (either distributed or in different unix processes) it&#8217;s all for naught.</p>
]]></content:encoded>
			<wfw:commentRss>http://thatmattbone.com/2008/07/serializing-continuations/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>matching Erlang&#8217;s receive semantics</title>
		<link>http://thatmattbone.com/2008/07/matching-erlangs-receive-semantics/</link>
		<comments>http://thatmattbone.com/2008/07/matching-erlangs-receive-semantics/#comments</comments>
		<pubDate>Wed, 02 Jul 2008 18:59:00 +0000</pubDate>
		<dc:creator>Matt Bone</dc:creator>
				<category><![CDATA[erlang-in-lisp]]></category>

		<guid isPermaLink="false">http://thatmattbone.com/?p=44</guid>
		<description><![CDATA[<a href="http://thatmattbone.com/2008/07/matching-erlangs-receive-semantics/" title="matching Erlang&#039;s receive semantics"></a>On Sunday and Monday I patched our version of receive. It now matches the Erlang semantics of blocking until a suitable match is found. This works in the unix-process and thread based concurrency models (it required changes to the API, &#8230;<p class="read-more"><a href="http://thatmattbone.com/2008/07/matching-erlangs-receive-semantics/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://thatmattbone.com/2008/07/matching-erlangs-receive-semantics/" title="matching Erlang&#039;s receive semantics"></a><p>On Sunday and Monday I patched our version of receive.  It now matches the Erlang semantics of blocking until a suitable match is found.  This works in the unix-process and thread based concurrency models (it required changes to the API, but shows how we should grow the pluggable concurrency API in an organic fashion (and it shows that it actually works)).  Receive timeouts are not implemented, though, so that remains.</p>
<p>My biggest worry at the moment is the half-assed serialization strategy I have for shipping off PIDs and how this isn&#8217;t working for spawning remote processes.  Sure I can ship off a function name, arguments, and invoke on a remote server no problem&#8230;but this doesn&#8217;t really match the Lisp semantics (or common sense semantics).  I really need some closure serialization ala Termite.</p>
]]></content:encoded>
			<wfw:commentRss>http://thatmattbone.com/2008/07/matching-erlangs-receive-semantics/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>the great CLOS experiment</title>
		<link>http://thatmattbone.com/2008/06/the-great-clos-experiment/</link>
		<comments>http://thatmattbone.com/2008/06/the-great-clos-experiment/#comments</comments>
		<pubDate>Fri, 20 Jun 2008 19:21:00 +0000</pubDate>
		<dc:creator>Matt Bone</dc:creator>
				<category><![CDATA[erlang-in-lisp]]></category>

		<guid isPermaLink="false">http://thatmattbone.com/?p=42</guid>
		<description><![CDATA[<a href="http://thatmattbone.com/2008/06/the-great-clos-experiment/" title="the great CLOS experiment"></a>I just committed the last touches on some pretty major changes in the erlang-in-lisp epmd branch. I was distracted from my linking/registering work on Tuesday by the fragility of the original design. I had an idea to use CLOS and &#8230;<p class="read-more"><a href="http://thatmattbone.com/2008/06/the-great-clos-experiment/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://thatmattbone.com/2008/06/the-great-clos-experiment/" title="the great CLOS experiment"></a><p>I just committed the last touches on some pretty major changes in the erlang-in-lisp epmd branch.  I was distracted from my linking/registering work on Tuesday by the fragility of the original design.  I had an idea to use CLOS and hoped this would help achieve our goals of pluggable concurrency and pluggable networking as set out in our proposal.  I think it worked out; the two branches (main and epmd) currently have the same functionality.  However, the epmd branch has an additional layer of abstraction.  The concrete implementations of send/spawn/receive can be switched an runtime, and if the appropriate methods are implemented communication should be possible between implementations (currently there is only one implementation).  </p>
<p>Next steps are to finally publish my todo list, test distribution (the way things are setup now, it should be working already), and return to my work on registering/linking/spawning remote processes.  The CLOS experiment did suck up some considerable time, but I&#8217;d still like to finish remote spawning and registration by monday.  </p>
<p>One final note, this is really the first time I&#8217;ve used CLOS extensively.  My initial attraction to Lisp and other languages with an appreciation for functional style came out of a frustration with the tedium of Java.  I guess I closely associated OOP with Java and was never very interested in persuing an OO style in these languages.  Working with CLOS and generic methods, however, really is OO done right and appropriately melds FP and OOP.  For example, specializing on two variables in method feels very functional (actually it makes me feel like I&#8217;m using Haskell&#8230;is that a good thing?), but we can still have side-effects within the objects themselves.  I&#8217;m rambling; I like CLOS.</p>
]]></content:encoded>
			<wfw:commentRss>http://thatmattbone.com/2008/06/the-great-clos-experiment/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>sname, name, self, node</title>
		<link>http://thatmattbone.com/2008/06/sname-name-self-node/</link>
		<comments>http://thatmattbone.com/2008/06/sname-name-self-node/#comments</comments>
		<pubDate>Tue, 17 Jun 2008 06:57:00 +0000</pubDate>
		<dc:creator>Matt Bone</dc:creator>
				<category><![CDATA[erlang-in-lisp]]></category>

		<guid isPermaLink="false">http://thatmattbone.com/?p=41</guid>
		<description><![CDATA[<a href="http://thatmattbone.com/2008/06/sname-name-self-node/" title="sname, name, self, node"></a>One of the things I&#8217;ve always been unclear on is how a server binds to particular address. This became apparent today in my erlang-in-lisp work with iolib and erlang itself. I had been messing around with distributing the ping-pong example &#8230;<p class="read-more"><a href="http://thatmattbone.com/2008/06/sname-name-self-node/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://thatmattbone.com/2008/06/sname-name-self-node/" title="sname, name, self, node"></a><p>One of the things I&#8217;ve always been unclear on is how a server binds to particular address.  This became apparent today in my erlang-in-lisp work with iolib and erlang itself.  I had been messing around with distributing the ping-pong example last week and things were not going as smoothly as I&#8217;d initially hoped.  It was all coming down to dns, the hosts file, and binding the server to the wrong address.  Today I tried the example in erlang, and my mistake became clear when I read up on the behavior of erlang with regards to &#8216;short names&#8217; and &#8216;long names&#8217; (it seems erlang is fond of adopting somewhat unusual terminology). </p>
<p>It turns out that some of my thinking last week was unacceptable; I&#8217;d been expecting self() to return information that could only be retrieved after a connection to a particular process.  This is impossible given the semantics of self().  Furthermore, I&#8217;d forgotten about the node() BIF in erlang.  By matching the behavior of the sname and name command line parameters in erlang, all has become clear.  The user specifies the hostname (or sometimes the IP address) to which the erlang (or erlang-in-lisp) process should be bound.  While this may seem a bit tedious at first blush, it really does (along with the cookie system) prevent unsuspecting users from casually opening up erlang processes to the outside world.  This will be (has been) duplicated in eil (though there is still a runtime typing problem keeping things from working properly at the moment&#8230;hopefully trivial).</p>
<p>Tomorrow I&#8217;m planning to swing by Loyola to pick up my &#8216;alumni card&#8217;.  I hope it allows me into the library (it should) to check out &#8220;Unix Network Programming&#8221; as I think this reference will be useful in the coming days.  I&#8217;m planning to tackle distribution and linking processes simultaneously this week.  I&#8217;m also hoping to be diligent in writing unit tests as I&#8217;ve found myself retyping the same test code at the repl over the last several days. </p>
<p>I&#8217;ve also been wondering about an erlang grammar.  Does one exist and could be use it in something like a lisp packrat parser?  Off to bed now&#8230;I hope this post does not sound like gibberish in the morning <img src='http://thatmattbone.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://thatmattbone.com/2008/06/sname-name-self-node/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ping-pong</title>
		<link>http://thatmattbone.com/2008/06/ping-pong/</link>
		<comments>http://thatmattbone.com/2008/06/ping-pong/#comments</comments>
		<pubDate>Thu, 05 Jun 2008 22:39:00 +0000</pubDate>
		<dc:creator>Matt Bone</dc:creator>
				<category><![CDATA[erlang-in-lisp]]></category>

		<guid isPermaLink="false">http://thatmattbone.com/?p=40</guid>
		<description><![CDATA[<a href="http://thatmattbone.com/2008/06/ping-pong/" title="ping-pong"></a>The ping-pong example is working with one caveat. Matches against patterns with just one atom must still be wrapped in a list. This is annoying, but we can fix it. This first step happened a bit more slowly than I&#8217;d &#8230;<p class="read-more"><a href="http://thatmattbone.com/2008/06/ping-pong/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://thatmattbone.com/2008/06/ping-pong/" title="ping-pong"></a><p>The ping-pong example is working with one caveat.  Matches against patterns with just one atom must still be wrapped in a list.  This is annoying, but we can fix it.</p>
<p>This first step happened a bit more slowly than I&#8217;d like, but I can see where we&#8217;re going now.  We&#8217;re on our way.</p>
]]></content:encoded>
			<wfw:commentRss>http://thatmattbone.com/2008/06/ping-pong/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>eil: top-level</title>
		<link>http://thatmattbone.com/2008/06/eil-top-level/</link>
		<comments>http://thatmattbone.com/2008/06/eil-top-level/#comments</comments>
		<pubDate>Thu, 05 Jun 2008 18:14:00 +0000</pubDate>
		<dc:creator>Matt Bone</dc:creator>
				<category><![CDATA[erlang-in-lisp]]></category>

		<guid isPermaLink="false">http://thatmattbone.com/?p=39</guid>
		<description><![CDATA[<a href="http://thatmattbone.com/2008/06/eil-top-level/" title="eil: top-level"></a>One of the things we may want to think about for erlang-in-lisp is a top level. In erlang, one can send and receive messages right at the REPL because it is a process with a mailbox. For us, we have &#8230;<p class="read-more"><a href="http://thatmattbone.com/2008/06/eil-top-level/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://thatmattbone.com/2008/06/eil-top-level/" title="eil: top-level"></a><p>One of the things we may want to think about for erlang-in-lisp is a top level.  In erlang, one can send and receive messages right at the REPL because it is a process with a mailbox.  For us, we have to do some additional bookkeeping (thus the standard REPL is not an erlang-in-lisp process).  This should be easy to implement and handy to some.</p>
]]></content:encoded>
			<wfw:commentRss>http://thatmattbone.com/2008/06/eil-top-level/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>simple example working</title>
		<link>http://thatmattbone.com/2008/06/simple-example-working/</link>
		<comments>http://thatmattbone.com/2008/06/simple-example-working/#comments</comments>
		<pubDate>Wed, 04 Jun 2008 03:36:00 +0000</pubDate>
		<dc:creator>Matt Bone</dc:creator>
				<category><![CDATA[erlang-in-lisp]]></category>

		<guid isPermaLink="false">http://thatmattbone.com/?p=38</guid>
		<description><![CDATA[<a href="http://thatmattbone.com/2008/06/simple-example-working/" title="simple example working"></a>I have a very simple example (sort of) working in erlang-in-lisp/examples.lisp. I did a quick hack to integrate fare-match into send/receive. The matching really isn&#8217;t working because the message is being mangled before it is sent over the socket. More &#8230;<p class="read-more"><a href="http://thatmattbone.com/2008/06/simple-example-working/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<a href="http://thatmattbone.com/2008/06/simple-example-working/" title="simple example working"></a><p>I have a very simple example (sort of) working in erlang-in-lisp/examples.lisp.  I did a quick hack to integrate fare-match into send/receive.  The matching really isn&#8217;t working because the message is being mangled before it is sent over the socket.  More tomorrow&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://thatmattbone.com/2008/06/simple-example-working/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

