Permalink
Browse files

Heed an idea by Shae Erisson: Hello Combinatorrent!

  • Loading branch information...
1 parent ffd1fca commit 0c56b08dc27db28f07ac253968f1fcdc84f4f3a9 @jlouis committed Mar 22, 2010
@@ -1,8 +1,8 @@
-name: HaskellTorrent
+name: Combinatorrent
category: Network
-version: 0.1.1
+version: 0.2.0
category: Network
-description: HaskellTorrent provides a BitTorrent client, based on the CML library
+description: Combinatorrent provides a BitTorrent client, based on the CML library
for concurrency. This is an early preview release which is capable of
downloading files from various torrent trackers, but have not yet
demonstrated to be correct in all aspects.
@@ -36,9 +36,9 @@ flag threadscope
description: Enable the eventlog necessary for ThreadScope
default: False
-executable HaskellTorrent
+executable Combinatorrent
hs-source-dirs: src
- main-is: HaskellTorrent.hs
+ main-is: Combinatorrent.hs
other-modules: Protocol.BCode, Protocol.Wire,
Data.Queue,
Process.ChokeMgr, Process.Console, Process.FS, Process.Listen,
View
@@ -1,11 +1,11 @@
-Haskell Torrent - a haskell bittorrent client.
-==========
+Combinatorrent - a bittorrent client.
+=====================================
Introduction
----------
-This is a Haskell bittorrent client. I am the introduction document
-and I need to be written by some generous soul!
+This is a bittorrent client. I am the introduction document and I need to be
+written by some generous soul!
Installation
------------
@@ -20,9 +20,9 @@ torrent in our $HOME/bin directory.
Usage
-----------------
-Haskell torrent can currently only do one very simple thing. If you call it with
+Combinatorrent can currently only do one very simple thing. If you call it with
- HaskellTorrent foo.torrent
+ Combinatorrent foo.torrent
then it will begin downloading the file in foo.torrent to the current
directory via the Bittorrent protocol.
@@ -36,14 +36,10 @@ explanation of these)
- 003, 004, 020,
-Haskell-torrent is not supporting these BEPs, but strives to do so one day:
+Combinatorrent is not supporting these BEPs, but strives to do so one day:
- - 005, 006, 007, 010, 012, 015, 009, 023, 018, 021, 022, 024, 026, 027,
- 028, 029, 030, 031, 032
-
-Haskell-torrent will probably never support these BEPs:
-
- - 016, 017, 019
+ - 005, 006, 007, 009, 010, 012, 015, 016, 017, 018, 019, 023, 021, 022,
+ 024, 026, 027, 028, 029, 030, 031, 032
Debugging
---------
@@ -52,12 +48,12 @@ For debugging, jlouis tends to use the following:
make conf build test
-This builds HaskellTorrent with the *Debug* flag set and also builds the
+This builds Combinatorrent with the *Debug* flag set and also builds the
software with profiling by default so it is easy to hunt down performance
regressions. It also runs the internal test-suite for various values. There
are a couple of interesting targets in the top-level Makefile
-Reading material for hacking HaskellTorrent:
+Reading material for hacking Combinatorrent:
--------------------------------------------
- [Protocol specification - BEP0003](http://www.bittorrent.org/beps/bep_0003.html):
@@ -81,22 +77,22 @@ Reading material for hacking HaskellTorrent:
quite a lot.
- ["Concurrent Programming in ML" - John. H. Reppy](http://www.amazon.com/Concurrent-Programming-ML-John-Reppy/dp/0521480892)
- This book describes the CML system which HaskellTorrent uses. The basic
+ This book describes the CML system which Combinatorrent use. The basic
idea of CML is that of higher order events. That is, events which can
be abstractly manipulated before being synchronized on. For instance,
CML events are a Functor instance, though the code currently does not
reflect that. This also provisions for fair selective receives
with dynamic choice of which events may fire.
- ["A Concurrent ML library in Concurrent Haskell" - Avik Chaudhuri, ICFP 2009](http://www.cs.umd.edu/~avik/projects/cmllch/)
- The paper behind the CML library which HaskellTorrent uses. It
+ The paper behind the CML library which Combinatorrent use. It
describes a way to transform the first-order MVar and ForkIO structures
of concurrent haskell into a higher order CML language by use of a
clever matchmaking algorithm.
- ["Supervisor Behaviour"](http://erlang.org/doc/design_principles/sup_princ.html)
From the Erlang documentation. How the Erlang Supervisor behaviour
- works. The Supervisor and process structure of HaskellTorrent is
+ works. The Supervisor and process structure of Combinatorrent is
somewhat inspired by the Erlang ditto.
Source code Hierarchy
@@ -105,7 +101,8 @@ Source code Hierarchy
- **Data**: Data structures.
- **Queue**: Functional queues. Standard variant with two lists.
- - **Process**: Process definitions for the different processes comprising Haskell Torrent
+ - **Process**: Process definitions for the different processes comprising
+ Combinatorrent
- **ChokeMgr**: Manages choking and unchoking of peers, based upon the current speed of the peer
and its current state. Global for multiple torrents.
- **Console**: Simple console process. Only responds to 'quit' at the moment.
@@ -127,7 +124,7 @@ Source code Hierarchy
- **Top Level**:
- **Digest**: SHA1 digests as used in the bittorrent protocol.
- **FS**: Low level Filesystem code. Interacts with files.
- - **HaskellTorrent**: Main entry point to the code. Sets up processes.
+ - **Combinatorrent**: Main entry point to the code. Sets up processes.
- **Logging**: Logging interface.
- **LoggingTypes**: Types and instances used by the Logging framework.
- **PeerTypes**: Types used by peers.
View
@@ -16,8 +16,8 @@ The main program is just to make Cabal lift it. But we will override testing.
> main = defaultMainWithHooks hooks
> where hooks = autoconfUserHooks { runTests = runTests' }
-Running tests is to call HaskellTorrent with its parameters for tests:
+Running tests is to call Combinatorrent with its parameters for tests:
> runTests' :: Args -> Bool -> PackageDescription -> LocalBuildInfo -> IO ()
> runTests' _ _ _ lbi = system testprog >> return ()
-> where testprog = (buildDir lbi) </> "HaskellTorrent" </> "HaskellTorrent --tests"
+> where testprog = (buildDir lbi) </> "Combinatorrent" </> "Combinatorrent --tests"
View
@@ -109,10 +109,6 @@ Items for later (no particular order)
is relevant for this client.
- Process monitoring in general. Think.
- Write a fuzzing framework for bittorrent.
- - shapr wants this to be combinatorrent. Change to this name. It rocks
- and people I've talked to really likes it.
- - ksf wants this to be named torroid, a torroid is a torrent in the
- category of haskell programs.
- Consider using STM, MVars/Chans in the long run and Push back on the
CML use.
@@ -54,7 +54,7 @@ progOpts args = do
case getOpt Permute options args of
(o,n,[] ) -> return (o, n)
(_,_,errs) -> ioError (userError (concat errs ++ usageInfo header options))
- where header = "Usage: HaskellTorrent [OPTION...] file"
+ where header = "Usage: Combinatorrent [OPTION...] file"
run :: ([Flag], [String]) -> IO ()
run (flags, files) = do
View
@@ -1,4 +1,4 @@
--- Define a set of test instances of common things used in HaskellTorrent
+-- Define a set of test instances of common types
-- Portions of this code is taken from "Real World Haskell"
module TestInstance
()
View
@@ -115,7 +115,9 @@ defaultOptimisticSlots = 2
defaultPort :: PortID
defaultPort = PortNumber $ fromInteger 1579
--- | The current version of Haskell-Torrent. It should be be here.
+-- | The current version of the Combinatorrent protocol string. This is bumped
+-- whenever we make a radical change to the protocol communication or fix a grave bug.
+-- It provides a way for trackers to disallow versions of the client which are misbehaving.
haskellTorrentVersion :: String
haskellTorrentVersion = "d001"
View
@@ -1,4 +1,4 @@
--- | Haskell-torrent version
+-- | Combinatorrent version
module Version (version) where
githead :: String
View
@@ -1,3 +1,3 @@
dummytest:
- ../dist/build/HaskellTorrent/HaskellTorrent testfile.txt.torrent
+ ../dist/build/Combinatorrent/Combinatorrent testfile.txt.torrent

0 comments on commit 0c56b08

Please sign in to comment.