Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Document a new example idea: Using Reflex from POE programs.

If this can be made to work, it represents an incremental migration
path from POE to Reflex.  Begin with a POE program, and gradually
incorporate Reflex code.  Eventually (har) port everything over.
  • Loading branch information...
commit c3ae474440a5a6eefaf05561e5411402d0675761 1 parent 394ca14
@rcaputo authored
Showing with 49 additions and 2 deletions.
  1. +2 −2 dist.ini
  2. +47 −0 eg/
4 dist.ini
@@ -1,5 +1,5 @@
name = Reflex
-version = 0.071
+version = 0.072
author = Rocco Caputo <>
license = Perl_5
copyright_holder = Rocco Caputo
@@ -35,7 +35,7 @@ git_remote = gh
-;[ReportVersions] ; Fails with Moose & MooseX::Role::Parameterized
47 eg/
@@ -0,0 +1,47 @@
+#!/usr/bin/env perl
+use warnings;
+use strict;
+die "This is a stub of an example. See the source for notes to make it real.\n";
+It should be possible to use Reflex within POE programs without ill effects.
+ Install Bot::BasicBot.
+ Create a Bot::BasicBot version of
+ Embed a Reflex::Server within the bot.
+ The server should take significant time to respond.
+ This will allow requests to back up, testing re-entrancy.
+ Use Reflex::Client within the bot to talk to a server.
+ Test re-entrancy.
+ Two or more requests should back up in the server.
+ The bot, the server, and the client should all keep working.
+17:18 kthakore : awnstudio_: yeah me
+17:18 kthakore : dngor: right ..
+17:18 kthakore : but how do I plug it into Bot::BasicBot
+17:19 dngor : When you get the trigger from Bot::BasicBot, open a
+ socket, send a request, and wait for a response.
+17:19 dngor : You could use IO::Socket::INET and
+ $poe_kernel->select_read(), or something higher level.
+17:19 kthakore :
+17:20 kthakore : but where do I get $poe_kernel from?
+17:20 dngor : If the server is localhost, the connect() will tend to
+ pass or fail pretty quickly... unless your firewall is
+ interfering with localhost. So blocking is generally not
+ a problem.
+17:20 kthakore : I mean I know BasicBot uses Poe
+17:20 dngor : Presumably Bot::BasicBot passes it to you, in the
+ standard POE way. If not, POE::Kernel exports it.
+17:21 dngor : Hm. There's an excellent exercise. Using Reflex INSIDE
+ POE components.
+17:21 dngor : Bot::BasicBot + Reflex::Client
+17:22 kthakore : dngor: whut is reflex ... and how do I use it?
+17:23 dngor : It's neither here nor there. I'm just brainstorming aloud.
+17:23 kthakore : dngor: oh ok
Please sign in to comment.
Something went wrong with that request. Please try again.