krpc

KRPC protocol implementation https://github.com/cobit/krpc

Latest on Hackage:0.6.1.0

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.

BSD3 licensed by Sam Truzjan
Maintained by Sam Truzjan

Synopsis

KRPC is simple remote procedure call mechanism used by bittorrent DHT but might be used anywhere else.

Description

KRPC basically consisting of bencoded dictionaries sent over UDP. This implementation provides extra safiety by separation of procedure signature and implementation and baking procedure type in host language, thus it's hard to shoot yourself in the foot accidently.

See bittorrent DHT specification for detailed protocol description.

Example

TODO

Modules

  • Remote.KRPC — simple interface which reduce all RPC related stuff to a few lines. Should be used in the first place.

  • Remote.KRPC.Protocol — raw protocol implementation.

  • Remote.KRPC.Scheme — message validation.

Documentation

For usage see examples in `examples` directory. For documentation see haddock generated documentation.

Build Status Build Status

Maintainer

Feel free to report bugs and suggestions via github issue tracker or the mail.

Changes

2014-02-19 Sam Truzjan <pxqr.sta@gmail.com>

0.6.0.0

API changes:

* Added isActive: this predicate can be used to implement
MonadActive instance and useful for resource
initialization/finalization sanity check.

2014-01-08 Sam Truzjan <pxqr.sta@gmail.com>

0.6.0.0: Logging + exceptions.

API changes:

* MonadLogger is superclass of MonadKRPC;
* KError hidden from Network.KRPC;
* HandlerFailure added;
* QueryFailure and getQueryCount added.

2013-12-25 Sam Truzjan <pxqr.sta@gmail.com>

0.5.0.0: Major API changes.

* Added transaction handling;
* Use the same socket for server and client;
* New query function will infer query method from request/response
datatypes.
* Added MonadKRPC and KRPC classes.

2013-11-26 Sam Truzjan <pxqr.sta@gmail.com>

* 0.4.1.1: Fixed build failure on GHC == 7.4.*

2013-10-17 Sam Truzjan <pxqr.sta@gmail.com>

* 0.4.1.0: Use bencoding-0.4.*

2013-10-03 Sam Truzjan <pxqr.sta@gmail.com>

* 0.4.0.1: Minor documentation fixes.

2013-10-03 Sam Truzjan <pxqr.sta@gmail.com>

* 0.4.0.0: IPv6 support.

2013-09-28 Sam Truzjan <pxqr.sta@gmail.com>

* 0.3.0.0: Use bencoding-0.3.*
* Rename Remote.* to Network.* modules.

2013-09-28 Sam Truzjan <pxqr.sta@gmail.com>

* 0.2.2.0: Use bencoding-0.2.2.*

2013-08-27 Sam Truzjan <pxqr.sta@gmail.com>

* 0.2.0.0: Async API have been removed, use /async/ package
instead.
* Expose caller address in handlers.

2013-07-09 Sam Truzjan <pxqr.sta@gmail.com>

* 0.1.1.0: Allow passing raw argument\/result dictionaries.

2013-07-09 Sam Truzjan <pxqr.sta@gmail.com>

* 0.1.0.0: Initial version.
comments powered byDisqus