score

Crates.ioscore
lib.rsscore
version0.2.0
sourcesrc
created_at2017-07-05 05:43:18.110192
updated_at2017-08-27 03:39:43.160358
descriptionDiscrete event simulation library
homepage
repositoryhttps://github.com/jesse99/score
max_upload_size
id21937
size165,769
antsi (github:hashintel:antsi)

documentation

README

About score

score is a general purpose discrete event simulator written in rust. The key types are:

  • Simulation is responsible for coordinating the execution of the simulation.
  • Components are used to define the structure of the simulation. Active components have a thread used to handle events.
  • Events are named messages sheduled to be delivered to a component at a specific time. Events may have am optional payload (which must satisfy the Any and Send traits).
  • The Store is where components persist state. (Using the store allows state to be viewed and changed using GUI tools like sdebug and allows side effects to be carefully managed.)
  • Components use an Effector to make changes. Components can use a an effector to log, change their own state within the store, and schedule events to be sent to arbitrary components.

score's goals include:

  • It should be flexible enough to simulate pretty much any sort of discrete event simulation.
  • It should be efficient and take advantage of multiple cores. Currently all components that have a scheduled event at the same time process the events in parallel. It should also be possible to leverage effectors to do speculative parallel execution.
  • Side effects should be carefully controlled, In particular the only way for a component to affect another component should be via an event.
  • Simulation execution should be deterministic across different runs and across platforms.
  • It should support off line analysis of simulation results. (This isn't in yet but shouldn't be hard to implement).
  • There should be a GUI tool to analyze simulations as they run.

versions:

  • 0.2.0 - added an embedded REST server to support GUIs like sdebug
  • 0.1.0 - lots of improvements
  • 0.0.1 - initial release

Online documentation for the released version can be found on crates.io.

Commit count: 159

cargo fmt