Login   Register  
PHP Classes
elePHPant
Icontem

File: test/bootstrap.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of AlexanderC  >  Threadator  >  test/bootstrap.php  >  Download  
File: test/bootstrap.php
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: Threadator
Create threads and send messages between them
Author: By
Last change: added more flexible communication driver setup
Date: 7 months ago
Size: 453 bytes
 

Contents

Class file image Download
<?php
/**
 * @author AlexanderC <self@alexanderc.me>
 * @date 4/9/14
 * @time 9:46 AM
 */

define('T_MAX'5);

require 
__DIR__ '/../vendor/autoload.php';

$runtime = new \Threadator\Runtime();
$factory = new \Threadator\Factory($runtime);

// the last argument are the parameters for redis connect() method
$communication = \Threadator\Communication\Communication::create($runtime'redis', ['127.0.0.1']);
$runtime->setCommunication($communication);