Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/olix0r/cgolws
Conway's Game of Life: The Web Service
https://github.com/olix0r/cgolws
Last synced: about 1 month ago
JSON representation
Conway's Game of Life: The Web Service
- Host: GitHub
- URL: https://github.com/olix0r/cgolws
- Owner: olix0r
- License: mit
- Created: 2015-01-01T17:34:47.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2015-01-01T17:35:32.000Z (almost 10 years ago)
- Last Synced: 2023-03-11T01:23:02.724Z (over 1 year ago)
- Language: Clojure
- Size: 133 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# cgolws
Conway's Game of Life as a Service
A small client-server app in Clojure & ClojureScript that runs
conway's game of life simulation.The server exposes a single API endpoint, `/evolve`, that accepts POST
requests that takes an
[EDN-formatted](https://github.com/edn-format/edn) world
representation like:{:width 3
:height 3
:age 0
:board [[true false false]
[false true false]
[false false true]]}And responds with an evolved board state:
{:width 3
:height 3
:age 1
:board [[false false false]
[false true false]
[false false false]]}The server parallelizes processing of this value, so it should provide
an advantage over client-side processing for large datasets. The
server performs some sanity-checking of the posted data and will
return a 400 if it cannot be validated. If data is posted
without a `:board`, however, a randomized board state will be
generated.## Prerequisites
You will need [Leiningen][1] 1.7.0 or above installed.
[1]: https://github.com/technomancy/leiningen
## Running
To start a web server for the application, run:
lein ring server
Then visit http://localhost:3000/
## License
Copyright © 2014 Oliver Gould