Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pluf/scion
A processing model to implement nonbloking HTTP server
https://github.com/pluf/scion
Last synced: about 23 hours ago
JSON representation
A processing model to implement nonbloking HTTP server
- Host: GitHub
- URL: https://github.com/pluf/scion
- Owner: pluf
- License: gpl-3.0
- Created: 2020-10-19T22:32:51.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2021-02-10T02:07:05.000Z (almost 4 years ago)
- Last Synced: 2024-05-02T16:06:10.705Z (7 months ago)
- Language: PHP
- Size: 154 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# scion
[![Build Status](https://travis-ci.com/pluf/scion.svg?branch=master)](https://travis-ci.com/pluf/scion)
[![Total Downloads](https://poser.pugx.org/pluf/scion/downloads)](https://packagist.org/packages/pluf/scion)
[![License](https://poser.pugx.org/pluf/scion/license)](https://packagist.org/packages/pluf/scion)A processing model to implement nonbloking server
It is verey common in HTTP
It merges Middlewares and View
## Concepts
- Process
- Unit
- Dataflow### Process
Process is a php function
### Unit
Unit is a list of process.
An unit add a login and flow to process.
Default flow is sequensial, so, all process executed sequensially.
#### Labeled process
You may label a process for an special goal.
Build in label:
- condition: jumbs to the end of unit if the return value is false.
Note: condition processes are not joined to the data flow, but handnle flows.
### Dataflow
TO send data to the successor processes a container is used.
Each process can access resources which produced in previus process.
The backward data flow is generated by return values.
## How to install
composer install pluf/scion
## Quick startCreate a simple index.php
add the following code
doProcess(['a'=>1, 'b'=>4]);
run the code
php index.php
The resullt will be:
$>php index.php
result is: 5
$>## Learn More
Learn more at these links:
- [Website](https://pluf.ir/products/scion)
- [Documentation](https://pluf.ir/products/scion-document)
- [Resources](https://pluf.ir/products/scion-Resources)## Contributors
Please see [CONTRIBUTING](CONTRIBUTING.md) for details.
### Code Contributors
This project exists thanks to all the people who contribute. [Contribute](CONTRIBUTING.md).