smparkes-eventmachine 0.12.10
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +15 -0
- data/README +81 -0
- data/Rakefile +374 -0
- data/docs/COPYING +60 -0
- data/docs/ChangeLog +211 -0
- data/docs/DEFERRABLES +133 -0
- data/docs/EPOLL +141 -0
- data/docs/GNU +281 -0
- data/docs/INSTALL +13 -0
- data/docs/KEYBOARD +38 -0
- data/docs/LEGAL +25 -0
- data/docs/LIGHTWEIGHT_CONCURRENCY +70 -0
- data/docs/PURE_RUBY +75 -0
- data/docs/RELEASE_NOTES +94 -0
- data/docs/SMTP +2 -0
- data/docs/SPAWNED_PROCESSES +89 -0
- data/docs/TODO +8 -0
- data/eventmachine.gemspec +40 -0
- data/examples/ex_channel.rb +43 -0
- data/examples/ex_queue.rb +2 -0
- data/examples/helper.rb +2 -0
- data/ext/binder.cpp +125 -0
- data/ext/binder.h +46 -0
- data/ext/cmain.cpp +827 -0
- data/ext/cplusplus.cpp +202 -0
- data/ext/ed.cpp +1901 -0
- data/ext/ed.h +424 -0
- data/ext/em.cpp +2288 -0
- data/ext/em.h +229 -0
- data/ext/emwin.cpp +300 -0
- data/ext/emwin.h +94 -0
- data/ext/epoll.cpp +26 -0
- data/ext/epoll.h +25 -0
- data/ext/eventmachine.h +122 -0
- data/ext/eventmachine_cpp.h +96 -0
- data/ext/extconf.rb +150 -0
- data/ext/fastfilereader/extconf.rb +85 -0
- data/ext/fastfilereader/mapper.cpp +214 -0
- data/ext/fastfilereader/mapper.h +59 -0
- data/ext/fastfilereader/rubymain.cpp +127 -0
- data/ext/files.cpp +94 -0
- data/ext/files.h +65 -0
- data/ext/kb.cpp +81 -0
- data/ext/page.cpp +107 -0
- data/ext/page.h +51 -0
- data/ext/pipe.cpp +349 -0
- data/ext/project.h +156 -0
- data/ext/rubymain.cpp +1194 -0
- data/ext/sigs.cpp +89 -0
- data/ext/sigs.h +32 -0
- data/ext/ssl.cpp +460 -0
- data/ext/ssl.h +94 -0
- data/java/.classpath +8 -0
- data/java/.project +17 -0
- data/java/src/com/rubyeventmachine/EmReactor.java +570 -0
- data/java/src/com/rubyeventmachine/EmReactorException.java +40 -0
- data/java/src/com/rubyeventmachine/EventableChannel.java +69 -0
- data/java/src/com/rubyeventmachine/EventableDatagramChannel.java +189 -0
- data/java/src/com/rubyeventmachine/EventableSocketChannel.java +364 -0
- data/java/src/com/rubyeventmachine/application/Application.java +194 -0
- data/java/src/com/rubyeventmachine/application/Connection.java +74 -0
- data/java/src/com/rubyeventmachine/application/ConnectionFactory.java +37 -0
- data/java/src/com/rubyeventmachine/application/DefaultConnectionFactory.java +46 -0
- data/java/src/com/rubyeventmachine/application/PeriodicTimer.java +38 -0
- data/java/src/com/rubyeventmachine/application/Timer.java +54 -0
- data/java/src/com/rubyeventmachine/tests/ApplicationTest.java +109 -0
- data/java/src/com/rubyeventmachine/tests/ConnectTest.java +148 -0
- data/java/src/com/rubyeventmachine/tests/EMTest.java +80 -0
- data/java/src/com/rubyeventmachine/tests/TestDatagrams.java +53 -0
- data/java/src/com/rubyeventmachine/tests/TestServers.java +75 -0
- data/java/src/com/rubyeventmachine/tests/TestTimers.java +90 -0
- data/lib/em/buftok.rb +138 -0
- data/lib/em/callback.rb +26 -0
- data/lib/em/channel.rb +57 -0
- data/lib/em/connection.rb +564 -0
- data/lib/em/deferrable.rb +192 -0
- data/lib/em/file_watch.rb +54 -0
- data/lib/em/future.rb +61 -0
- data/lib/em/messages.rb +66 -0
- data/lib/em/process_watch.rb +44 -0
- data/lib/em/processes.rb +119 -0
- data/lib/em/protocols/header_and_content.rb +138 -0
- data/lib/em/protocols/httpclient.rb +263 -0
- data/lib/em/protocols/httpclient2.rb +590 -0
- data/lib/em/protocols/line_and_text.rb +125 -0
- data/lib/em/protocols/linetext2.rb +161 -0
- data/lib/em/protocols/memcache.rb +323 -0
- data/lib/em/protocols/object_protocol.rb +45 -0
- data/lib/em/protocols/postgres3.rb +247 -0
- data/lib/em/protocols/saslauth.rb +175 -0
- data/lib/em/protocols/smtpclient.rb +357 -0
- data/lib/em/protocols/smtpserver.rb +547 -0
- data/lib/em/protocols/socks4.rb +66 -0
- data/lib/em/protocols/stomp.rb +200 -0
- data/lib/em/protocols/tcptest.rb +53 -0
- data/lib/em/protocols.rb +36 -0
- data/lib/em/queue.rb +61 -0
- data/lib/em/spawnable.rb +85 -0
- data/lib/em/streamer.rb +130 -0
- data/lib/em/timers.rb +56 -0
- data/lib/em/version.rb +3 -0
- data/lib/eventmachine.rb +1592 -0
- data/lib/evma/callback.rb +32 -0
- data/lib/evma/container.rb +75 -0
- data/lib/evma/factory.rb +77 -0
- data/lib/evma/protocol.rb +87 -0
- data/lib/evma/reactor.rb +48 -0
- data/lib/evma.rb +32 -0
- data/lib/jeventmachine.rb +257 -0
- data/lib/pr_eventmachine.rb +1022 -0
- data/setup.rb +1585 -0
- data/tasks/cpp.rake_example +77 -0
- data/tests/client.crt +31 -0
- data/tests/client.key +51 -0
- data/tests/test_attach.rb +126 -0
- data/tests/test_basic.rb +284 -0
- data/tests/test_channel.rb +63 -0
- data/tests/test_connection_count.rb +35 -0
- data/tests/test_defer.rb +47 -0
- data/tests/test_epoll.rb +160 -0
- data/tests/test_error_handler.rb +35 -0
- data/tests/test_errors.rb +82 -0
- data/tests/test_exc.rb +55 -0
- data/tests/test_file_watch.rb +49 -0
- data/tests/test_futures.rb +198 -0
- data/tests/test_get_sock_opt.rb +30 -0
- data/tests/test_handler_check.rb +37 -0
- data/tests/test_hc.rb +218 -0
- data/tests/test_httpclient.rb +218 -0
- data/tests/test_httpclient2.rb +153 -0
- data/tests/test_inactivity_timeout.rb +50 -0
- data/tests/test_kb.rb +60 -0
- data/tests/test_ltp.rb +182 -0
- data/tests/test_ltp2.rb +317 -0
- data/tests/test_next_tick.rb +133 -0
- data/tests/test_object_protocol.rb +37 -0
- data/tests/test_pause.rb +70 -0
- data/tests/test_pending_connect_timeout.rb +48 -0
- data/tests/test_process_watch.rb +48 -0
- data/tests/test_processes.rb +128 -0
- data/tests/test_proxy_connection.rb +92 -0
- data/tests/test_pure.rb +125 -0
- data/tests/test_queue.rb +44 -0
- data/tests/test_running.rb +42 -0
- data/tests/test_sasl.rb +72 -0
- data/tests/test_send_file.rb +242 -0
- data/tests/test_servers.rb +76 -0
- data/tests/test_smtpclient.rb +83 -0
- data/tests/test_smtpserver.rb +85 -0
- data/tests/test_spawn.rb +322 -0
- data/tests/test_ssl_args.rb +79 -0
- data/tests/test_ssl_methods.rb +50 -0
- data/tests/test_ssl_verify.rb +82 -0
- data/tests/test_timers.rb +162 -0
- data/tests/test_ud.rb +36 -0
- data/tests/testem.rb +31 -0
- data/web/whatis +7 -0
- metadata +237 -0
data/tests/test_ud.rb
ADDED
@@ -0,0 +1,36 @@
|
|
1
|
+
# $Id$
|
2
|
+
#
|
3
|
+
# Author:: Francis Cianfrocca (gmail: blackhedd)
|
4
|
+
# Homepage:: http://rubyeventmachine.com
|
5
|
+
# Date:: 8 April 2006
|
6
|
+
#
|
7
|
+
# See EventMachine and EventMachine::Connection for documentation and
|
8
|
+
# usage examples.
|
9
|
+
#
|
10
|
+
#----------------------------------------------------------------------------
|
11
|
+
#
|
12
|
+
# Copyright (C) 2006-07 by Francis Cianfrocca. All Rights Reserved.
|
13
|
+
# Gmail: blackhedd
|
14
|
+
#
|
15
|
+
# This program is free software; you can redistribute it and/or modify
|
16
|
+
# it under the terms of either: 1) the GNU General Public License
|
17
|
+
# as published by the Free Software Foundation; either version 2 of the
|
18
|
+
# License, or (at your option) any later version; or 2) Ruby's License.
|
19
|
+
#
|
20
|
+
# See the file COPYING for complete licensing information.
|
21
|
+
#
|
22
|
+
#---------------------------------------------------------------------------
|
23
|
+
#
|
24
|
+
#
|
25
|
+
#
|
26
|
+
|
27
|
+
$:.unshift "../lib"
|
28
|
+
require 'eventmachine'
|
29
|
+
require 'test/unit'
|
30
|
+
|
31
|
+
class TestUserDefinedEvents < Test::Unit::TestCase
|
32
|
+
|
33
|
+
def test_a
|
34
|
+
end
|
35
|
+
|
36
|
+
end
|
data/tests/testem.rb
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
# $Id$
|
2
|
+
|
3
|
+
require 'test/unit'
|
4
|
+
|
5
|
+
module EmTestRunner
|
6
|
+
@em_root = File.expand_path(File.dirname(__FILE__) + '/../')
|
7
|
+
@lib_dir = File.join(@em_root, 'lib')
|
8
|
+
@ext_dir = File.join(@em_root, 'ext')
|
9
|
+
@java_dir = File.join(@em_root, 'java')
|
10
|
+
|
11
|
+
def self.run(glob = 'test_*.rb')
|
12
|
+
$:.unshift(@lib_dir)
|
13
|
+
$:.unshift(@ext_dir)
|
14
|
+
$:.unshift(@java_dir)
|
15
|
+
|
16
|
+
case glob
|
17
|
+
when Array
|
18
|
+
files = glob
|
19
|
+
else
|
20
|
+
files = Dir[File.dirname(__FILE__) + '/' + glob]
|
21
|
+
end
|
22
|
+
|
23
|
+
files.each do |tc|
|
24
|
+
require tc
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
28
|
+
|
29
|
+
if __FILE__ == $0
|
30
|
+
EmTestRunner.run
|
31
|
+
end
|
data/web/whatis
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
EventMachine is a library for Ruby, C++, and Java programs. It provides event-driven I/O using the Reactor pattern.
|
2
|
+
|
3
|
+
EventMachine is designed to simultaneously meet two key needs:
|
4
|
+
- Extremely high scalability, performance and stability for the most demanding production environments; and
|
5
|
+
- An API that <i>eliminates</i> the complexities of high-performance threaded network programming, allowing engineers to concentrate on their application logic.
|
6
|
+
|
7
|
+
This unique combination makes EventMachine a premier choice for designers of critical networked applications, including web servers and proxies, email and IM production systems, authentication/authorization processors, and many more.
|
metadata
ADDED
@@ -0,0 +1,237 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: smparkes-eventmachine
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.12.10
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Francis Cianfrocca
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
|
12
|
+
date: 2009-10-24 00:00:00 -07:00
|
13
|
+
default_executable:
|
14
|
+
dependencies: []
|
15
|
+
|
16
|
+
description: |
|
17
|
+
EventMachine implements a fast, single-threaded engine for arbitrary network
|
18
|
+
communications. It's extremely easy to use in Ruby. EventMachine wraps all
|
19
|
+
interactions with IP sockets, allowing programs to concentrate on the
|
20
|
+
implementation of network protocols. It can be used to create both network
|
21
|
+
servers and clients. To create a server or client, a Ruby program only needs
|
22
|
+
to specify the IP address and port, and provide a Module that implements the
|
23
|
+
communications protocol. Implementations of several standard network protocols
|
24
|
+
are provided with the package, primarily to serve as examples. The real goal
|
25
|
+
of EventMachine is to enable programs to easily interface with other programs
|
26
|
+
using TCP/IP, especially if custom protocols are required.
|
27
|
+
|
28
|
+
email: garbagecat10@gmail.com
|
29
|
+
executables: []
|
30
|
+
|
31
|
+
extensions:
|
32
|
+
- ext/extconf.rb
|
33
|
+
- ext/fastfilereader/extconf.rb
|
34
|
+
extra_rdoc_files: []
|
35
|
+
|
36
|
+
files:
|
37
|
+
- .gitignore
|
38
|
+
- README
|
39
|
+
- Rakefile
|
40
|
+
- docs/COPYING
|
41
|
+
- docs/ChangeLog
|
42
|
+
- docs/DEFERRABLES
|
43
|
+
- docs/EPOLL
|
44
|
+
- docs/GNU
|
45
|
+
- docs/INSTALL
|
46
|
+
- docs/KEYBOARD
|
47
|
+
- docs/LEGAL
|
48
|
+
- docs/LIGHTWEIGHT_CONCURRENCY
|
49
|
+
- docs/PURE_RUBY
|
50
|
+
- docs/RELEASE_NOTES
|
51
|
+
- docs/SMTP
|
52
|
+
- docs/SPAWNED_PROCESSES
|
53
|
+
- docs/TODO
|
54
|
+
- eventmachine.gemspec
|
55
|
+
- examples/ex_channel.rb
|
56
|
+
- examples/ex_queue.rb
|
57
|
+
- examples/helper.rb
|
58
|
+
- ext/binder.cpp
|
59
|
+
- ext/binder.h
|
60
|
+
- ext/cmain.cpp
|
61
|
+
- ext/cplusplus.cpp
|
62
|
+
- ext/ed.cpp
|
63
|
+
- ext/ed.h
|
64
|
+
- ext/em.cpp
|
65
|
+
- ext/em.h
|
66
|
+
- ext/emwin.cpp
|
67
|
+
- ext/emwin.h
|
68
|
+
- ext/epoll.cpp
|
69
|
+
- ext/epoll.h
|
70
|
+
- ext/eventmachine.h
|
71
|
+
- ext/eventmachine_cpp.h
|
72
|
+
- ext/extconf.rb
|
73
|
+
- ext/fastfilereader/extconf.rb
|
74
|
+
- ext/fastfilereader/mapper.cpp
|
75
|
+
- ext/fastfilereader/mapper.h
|
76
|
+
- ext/fastfilereader/rubymain.cpp
|
77
|
+
- ext/files.cpp
|
78
|
+
- ext/files.h
|
79
|
+
- ext/kb.cpp
|
80
|
+
- ext/page.cpp
|
81
|
+
- ext/page.h
|
82
|
+
- ext/pipe.cpp
|
83
|
+
- ext/project.h
|
84
|
+
- ext/rubymain.cpp
|
85
|
+
- ext/sigs.cpp
|
86
|
+
- ext/sigs.h
|
87
|
+
- ext/ssl.cpp
|
88
|
+
- ext/ssl.h
|
89
|
+
- java/.classpath
|
90
|
+
- java/.project
|
91
|
+
- java/src/com/rubyeventmachine/EmReactor.java
|
92
|
+
- java/src/com/rubyeventmachine/EmReactorException.java
|
93
|
+
- java/src/com/rubyeventmachine/EventableChannel.java
|
94
|
+
- java/src/com/rubyeventmachine/EventableDatagramChannel.java
|
95
|
+
- java/src/com/rubyeventmachine/EventableSocketChannel.java
|
96
|
+
- java/src/com/rubyeventmachine/application/Application.java
|
97
|
+
- java/src/com/rubyeventmachine/application/Connection.java
|
98
|
+
- java/src/com/rubyeventmachine/application/ConnectionFactory.java
|
99
|
+
- java/src/com/rubyeventmachine/application/DefaultConnectionFactory.java
|
100
|
+
- java/src/com/rubyeventmachine/application/PeriodicTimer.java
|
101
|
+
- java/src/com/rubyeventmachine/application/Timer.java
|
102
|
+
- java/src/com/rubyeventmachine/tests/ApplicationTest.java
|
103
|
+
- java/src/com/rubyeventmachine/tests/ConnectTest.java
|
104
|
+
- java/src/com/rubyeventmachine/tests/EMTest.java
|
105
|
+
- java/src/com/rubyeventmachine/tests/TestDatagrams.java
|
106
|
+
- java/src/com/rubyeventmachine/tests/TestServers.java
|
107
|
+
- java/src/com/rubyeventmachine/tests/TestTimers.java
|
108
|
+
- lib/em/buftok.rb
|
109
|
+
- lib/em/callback.rb
|
110
|
+
- lib/em/channel.rb
|
111
|
+
- lib/em/connection.rb
|
112
|
+
- lib/em/deferrable.rb
|
113
|
+
- lib/em/file_watch.rb
|
114
|
+
- lib/em/future.rb
|
115
|
+
- lib/em/messages.rb
|
116
|
+
- lib/em/process_watch.rb
|
117
|
+
- lib/em/processes.rb
|
118
|
+
- lib/em/protocols.rb
|
119
|
+
- lib/em/protocols/header_and_content.rb
|
120
|
+
- lib/em/protocols/httpclient.rb
|
121
|
+
- lib/em/protocols/httpclient2.rb
|
122
|
+
- lib/em/protocols/line_and_text.rb
|
123
|
+
- lib/em/protocols/linetext2.rb
|
124
|
+
- lib/em/protocols/memcache.rb
|
125
|
+
- lib/em/protocols/object_protocol.rb
|
126
|
+
- lib/em/protocols/postgres3.rb
|
127
|
+
- lib/em/protocols/saslauth.rb
|
128
|
+
- lib/em/protocols/smtpclient.rb
|
129
|
+
- lib/em/protocols/smtpserver.rb
|
130
|
+
- lib/em/protocols/socks4.rb
|
131
|
+
- lib/em/protocols/stomp.rb
|
132
|
+
- lib/em/protocols/tcptest.rb
|
133
|
+
- lib/em/queue.rb
|
134
|
+
- lib/em/spawnable.rb
|
135
|
+
- lib/em/streamer.rb
|
136
|
+
- lib/em/timers.rb
|
137
|
+
- lib/em/version.rb
|
138
|
+
- lib/eventmachine.rb
|
139
|
+
- lib/evma.rb
|
140
|
+
- lib/evma/callback.rb
|
141
|
+
- lib/evma/container.rb
|
142
|
+
- lib/evma/factory.rb
|
143
|
+
- lib/evma/protocol.rb
|
144
|
+
- lib/evma/reactor.rb
|
145
|
+
- lib/jeventmachine.rb
|
146
|
+
- lib/pr_eventmachine.rb
|
147
|
+
- setup.rb
|
148
|
+
- tasks/cpp.rake_example
|
149
|
+
- tests/client.crt
|
150
|
+
- tests/client.key
|
151
|
+
- tests/test_attach.rb
|
152
|
+
- tests/test_basic.rb
|
153
|
+
- tests/test_channel.rb
|
154
|
+
- tests/test_connection_count.rb
|
155
|
+
- tests/test_defer.rb
|
156
|
+
- tests/test_epoll.rb
|
157
|
+
- tests/test_error_handler.rb
|
158
|
+
- tests/test_errors.rb
|
159
|
+
- tests/test_exc.rb
|
160
|
+
- tests/test_file_watch.rb
|
161
|
+
- tests/test_futures.rb
|
162
|
+
- tests/test_get_sock_opt.rb
|
163
|
+
- tests/test_handler_check.rb
|
164
|
+
- tests/test_hc.rb
|
165
|
+
- tests/test_httpclient.rb
|
166
|
+
- tests/test_httpclient2.rb
|
167
|
+
- tests/test_inactivity_timeout.rb
|
168
|
+
- tests/test_kb.rb
|
169
|
+
- tests/test_ltp.rb
|
170
|
+
- tests/test_ltp2.rb
|
171
|
+
- tests/test_next_tick.rb
|
172
|
+
- tests/test_object_protocol.rb
|
173
|
+
- tests/test_pause.rb
|
174
|
+
- tests/test_pending_connect_timeout.rb
|
175
|
+
- tests/test_process_watch.rb
|
176
|
+
- tests/test_processes.rb
|
177
|
+
- tests/test_proxy_connection.rb
|
178
|
+
- tests/test_pure.rb
|
179
|
+
- tests/test_queue.rb
|
180
|
+
- tests/test_running.rb
|
181
|
+
- tests/test_sasl.rb
|
182
|
+
- tests/test_send_file.rb
|
183
|
+
- tests/test_servers.rb
|
184
|
+
- tests/test_smtpclient.rb
|
185
|
+
- tests/test_smtpserver.rb
|
186
|
+
- tests/test_spawn.rb
|
187
|
+
- tests/test_ssl_args.rb
|
188
|
+
- tests/test_ssl_methods.rb
|
189
|
+
- tests/test_ssl_verify.rb
|
190
|
+
- tests/test_timers.rb
|
191
|
+
- tests/test_ud.rb
|
192
|
+
- tests/testem.rb
|
193
|
+
- web/whatis
|
194
|
+
has_rdoc: true
|
195
|
+
homepage: http://rubyeventmachine.com
|
196
|
+
licenses: []
|
197
|
+
|
198
|
+
post_install_message:
|
199
|
+
rdoc_options:
|
200
|
+
- --title
|
201
|
+
- EventMachine
|
202
|
+
- --main
|
203
|
+
- README
|
204
|
+
- --line-numbers
|
205
|
+
- -x
|
206
|
+
- lib/em/version
|
207
|
+
- -x
|
208
|
+
- lib/emva
|
209
|
+
- -x
|
210
|
+
- lib/evma/
|
211
|
+
- -x
|
212
|
+
- lib/pr_eventmachine
|
213
|
+
- -x
|
214
|
+
- lib/jeventmachine
|
215
|
+
require_paths:
|
216
|
+
- lib
|
217
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
218
|
+
requirements:
|
219
|
+
- - ">="
|
220
|
+
- !ruby/object:Gem::Version
|
221
|
+
version: "0"
|
222
|
+
version:
|
223
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
224
|
+
requirements:
|
225
|
+
- - ">="
|
226
|
+
- !ruby/object:Gem::Version
|
227
|
+
version: "0"
|
228
|
+
version:
|
229
|
+
requirements: []
|
230
|
+
|
231
|
+
rubyforge_project: eventmachine
|
232
|
+
rubygems_version: 1.3.5
|
233
|
+
signing_key:
|
234
|
+
specification_version: 3
|
235
|
+
summary: Ruby/EventMachine library
|
236
|
+
test_files: []
|
237
|
+
|