nitro 0.8.0 → 0.9.3
Sign up to get free protection for your applications and to get access to all the features.
- data/AUTHORS +3 -4
- data/ChangeLog +418 -0
- data/LICENSE +1 -1
- data/README +157 -89
- data/RELEASES +50 -0
- data/Rakefile +5 -7
- data/benchmark/nitro/bench.rb +5 -0
- data/benchmark/nitro/simple-webrick-n-200.txt +44 -0
- data/benchmark/nitro/static-webrick-n-200.txt +43 -0
- data/benchmark/nitro/tiny-lhttpd-n-200-c-5.txt +43 -0
- data/benchmark/nitro/tiny-webrick-n-200-c-5.txt +44 -0
- data/benchmark/nitro/tiny-webrick-n-200.txt +44 -0
- data/benchmark/nitro/tiny2-webrick-n-200.txt +44 -0
- data/{lib/nitro/server/cluster.rb → bin/cluster} +26 -30
- data/bin/proto/README +2 -2
- data/bin/proto/{apache.conf → conf/apache.conf} +0 -0
- data/bin/proto/conf/app.conf.rb +22 -0
- data/bin/proto/conf/lhttpd.conf +236 -0
- data/bin/proto/ctl +4 -0
- data/bin/proto/lib/README +5 -0
- data/bin/proto/log/README +3 -0
- data/bin/proto/root/fcgi.rb +6 -0
- data/bin/proto/root/index.xhtml +65 -7
- data/bin/proto/root/m/nitro.png +0 -0
- data/examples/blog/README +7 -5
- data/examples/blog/{apache.conf → conf/apache.conf} +0 -0
- data/examples/blog/conf/app.conf.rb +56 -0
- data/examples/blog/conf/lhttpd.conf +236 -0
- data/examples/blog/ctl +4 -0
- data/examples/blog/lib/blog.rb +11 -136
- data/examples/blog/lib/blog/controller.rb +99 -0
- data/examples/blog/lib/blog/model.rb +39 -0
- data/examples/blog/log/README +3 -0
- data/examples/blog/root/comments.xhtml +2 -2
- data/examples/blog/root/fcgi.rb +6 -0
- data/examples/blog/root/index.xhtml +4 -5
- data/examples/blog/root/login.xhtml +2 -2
- data/examples/blog/root/style.xsl +9 -9
- data/examples/blog/root/view_entry.xhtml +2 -2
- data/examples/flash/conf/app.conf.rb +23 -0
- data/examples/flash/ctl +4 -0
- data/examples/flash/log/README +3 -0
- data/examples/flash/root/index.xhtml +0 -9
- data/examples/flash/root/show_inline_text.xhtml +10 -5
- data/examples/no_xsl_blog/README +12 -0
- data/examples/no_xsl_blog/conf/apache.conf +0 -0
- data/examples/no_xsl_blog/conf/app.conf.rb +57 -0
- data/examples/no_xsl_blog/conf/lhttpd.conf +236 -0
- data/examples/no_xsl_blog/ctl +4 -0
- data/examples/no_xsl_blog/lib/blog.rb +20 -0
- data/examples/no_xsl_blog/lib/blog/controller.rb +102 -0
- data/examples/no_xsl_blog/lib/blog/model.rb +39 -0
- data/examples/no_xsl_blog/lib/blog/template.rb +134 -0
- data/examples/no_xsl_blog/log/README +3 -0
- data/examples/no_xsl_blog/root/comments.xhtml +41 -0
- data/examples/no_xsl_blog/root/entry_form.xhtml +22 -0
- data/examples/no_xsl_blog/root/fcgi.rb +6 -0
- data/examples/no_xsl_blog/root/index.xhtml +39 -0
- data/examples/no_xsl_blog/root/login.xhtml +21 -0
- data/examples/no_xsl_blog/root/m/bubbles.gif +0 -0
- data/examples/no_xsl_blog/root/m/comments_curve.gif +0 -0
- data/examples/no_xsl_blog/root/m/down.gif +0 -0
- data/examples/no_xsl_blog/root/m/footer_bg.gif +0 -0
- data/examples/no_xsl_blog/root/m/garrow.gif +0 -0
- data/examples/no_xsl_blog/root/m/gbull.gif +0 -0
- data/examples/no_xsl_blog/root/m/grbull.gif +0 -0
- data/examples/no_xsl_blog/root/m/h1_bg.gif +0 -0
- data/examples/no_xsl_blog/root/m/header_bg.gif +0 -0
- data/examples/no_xsl_blog/root/m/nitro.gif +0 -0
- data/examples/no_xsl_blog/root/m/obull.gif +0 -0
- data/examples/no_xsl_blog/root/m/page_bg.gif +0 -0
- data/examples/no_xsl_blog/root/m/rss.gif +0 -0
- data/examples/no_xsl_blog/root/m/side_title_bg.gif +0 -0
- data/examples/no_xsl_blog/root/m/sidebar_bg.gif +0 -0
- data/examples/no_xsl_blog/root/recent_posts.xhtml +14 -0
- data/examples/no_xsl_blog/root/style.css +301 -0
- data/examples/no_xsl_blog/root/view_entry.xhtml +25 -0
- data/examples/no_xsl_blog/root/view_entry.xml +12 -0
- data/examples/og/run.rb +2 -2
- data/examples/tiny/README +2 -2
- data/examples/tiny/conf/apache.conf +5 -0
- data/examples/tiny/conf/app.conf.rb +21 -0
- data/examples/tiny/conf/lhttpd.conf +236 -0
- data/examples/tiny/ctl +4 -0
- data/examples/tiny/log/README +3 -0
- data/examples/tiny/root/fcgi.rb +6 -0
- data/examples/tiny/root/index.xhtml +7 -4
- data/examples/tiny/root/nitro.png +0 -0
- data/lib/glue.rb +13 -9
- data/lib/glue/array.rb +1 -1
- data/lib/glue/cache.rb +1 -1
- data/lib/glue/flexob.rb +12 -0
- data/lib/glue/hash.rb +1 -1
- data/lib/glue/inflector.rb +2 -2
- data/lib/glue/logger.rb +4 -8
- data/lib/glue/misc.rb +14 -0
- data/lib/glue/number.rb +1 -1
- data/lib/glue/object.rb +26 -0
- data/lib/glue/pool.rb +1 -1
- data/lib/glue/property.rb +84 -91
- data/lib/glue/string.rb +1 -1
- data/lib/glue/time.rb +1 -1
- data/lib/glue/validation.rb +1 -1
- data/lib/nitro.rb +18 -6
- data/lib/nitro/adaptors/cgi.rb +291 -0
- data/lib/nitro/adaptors/fastcgi.rb +42 -0
- data/lib/nitro/adaptors/runner.rb +123 -0
- data/lib/nitro/adaptors/webrick.rb +110 -0
- data/lib/nitro/buffering.rb +43 -0
- data/lib/nitro/builders/form.rb +1 -1
- data/lib/nitro/builders/rss.rb +1 -1
- data/{bin → lib/nitro}/cluster.rb +26 -30
- data/lib/nitro/context.rb +82 -0
- data/lib/nitro/controller.rb +50 -0
- data/lib/nitro/cookie.rb +46 -0
- data/lib/nitro/dispatcher.rb +105 -0
- data/lib/nitro/filters.rb +9 -10
- data/lib/nitro/localization.rb +42 -0
- data/lib/nitro/mail.rb +11 -14
- data/lib/nitro/render.rb +275 -0
- data/lib/nitro/request.rb +128 -0
- data/lib/nitro/response.rb +38 -0
- data/lib/nitro/scaffold.rb +11 -11
- data/lib/nitro/session.rb +84 -0
- data/lib/nitro/{server/shaders.rb → shaders.rb} +56 -36
- data/lib/nitro/ui/pager.rb +23 -26
- data/lib/nitro/{sitemap.rb → ui/sitemap.rb} +4 -12
- data/lib/nitro/uri.rb +1 -1
- data/lib/nitro/version.rb +10 -8
- data/lib/og.rb +66 -65
- data/lib/og/backend.rb +1 -1
- data/lib/og/backends/mysql.rb +48 -52
- data/lib/og/backends/psql.rb +34 -37
- data/lib/og/connection.rb +15 -15
- data/lib/og/enchant.rb +16 -9
- data/lib/og/meta.rb +127 -54
- data/lib/og/mock.rb +18 -18
- data/lib/og/version.rb +6 -4
- data/lib/parts/content.rb +4 -8
- data/test/glue/tc_logger.rb +3 -0
- data/test/glue/tc_property.rb +19 -3
- data/test/nitro/adaptors/tc_cgi.rb +63 -0
- data/test/nitro/adaptors/tc_webrick.rb +15 -0
- data/test/nitro/builders/tc_xml.rb +2 -2
- data/test/nitro/tc_context.rb +13 -0
- data/test/nitro/tc_controller.rb +47 -0
- data/test/nitro/tc_dispatcher.rb +64 -0
- data/test/nitro/tc_session.rb +20 -0
- data/test/nitro/{tc_sitemap.rb → ui/tc_sitemap.rb} +1 -1
- data/test/root/blog/list.xhtml +6 -0
- data/test/tc_og.rb +41 -4
- metadata +115 -59
- data/bin/proto/app.rb +0 -20
- data/bin/proto/config.rb +0 -77
- data/examples/blog/app.rb +0 -21
- data/examples/blog/config.rb +0 -95
- data/examples/blog/env.rb +0 -22
- data/examples/flash/README +0 -34
- data/examples/flash/app.rb +0 -20
- data/examples/flash/config.rb +0 -38
- data/examples/flash/lib/flash.rb +0 -40
- data/examples/flash/tmp.swf +0 -0
- data/examples/tiny/app.rb +0 -19
- data/examples/tiny/config.rb +0 -29
- data/examples/tiny/root/nitro-small.png +0 -0
- data/lib/nitro/application.rb +0 -217
- data/lib/nitro/config.rb +0 -128
- data/lib/nitro/events.rb +0 -122
- data/lib/nitro/html.rb +0 -151
- data/lib/nitro/http.rb +0 -102
- data/lib/nitro/l10n.rb +0 -30
- data/lib/nitro/server.rb +0 -59
- data/lib/nitro/server/appserver.rb +0 -67
- data/lib/nitro/server/cookie.rb +0 -87
- data/lib/nitro/server/dispatcher.rb +0 -62
- data/lib/nitro/server/filters.rb +0 -75
- data/lib/nitro/server/filters/autologin.rb +0 -51
- data/lib/nitro/server/fragment.rb +0 -70
- data/lib/nitro/server/handlers.rb +0 -127
- data/lib/nitro/server/render.rb +0 -426
- data/lib/nitro/server/request.rb +0 -658
- data/lib/nitro/server/requestpart.rb +0 -54
- data/lib/nitro/server/script.rb +0 -387
- data/lib/nitro/server/server.rb +0 -57
- data/lib/nitro/server/session.rb +0 -220
- data/lib/nitro/server/user.rb +0 -46
- data/lib/nitro/server/webrick.rb +0 -180
- data/lib/nitro/service.rb +0 -26
- data/lib/xsl/ui.xsl +0 -51
- data/lib/xsl/xforms.xsl +0 -28
- data/test/nitro/server/tc_cookie.rb +0 -34
- data/test/nitro/server/tc_filters.rb +0 -38
- data/test/nitro/server/tc_request.rb +0 -70
- data/test/nitro/server/tc_requestpart.rb +0 -28
- data/test/nitro/server/tc_session.rb +0 -34
- data/test/nitro/tc_events.rb +0 -44
- data/test/nitro/tc_html.rb +0 -79
- data/test/nitro/tc_http.rb +0 -18
data/README
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
= Nitro 0.
|
1
|
+
= Nitro 0.9.0
|
2
2
|
|
3
3
|
Nitro is an efficient, yet simple engine for developing professional Web
|
4
4
|
Applications using the Ruby language. Nitro aims to provide a robust
|
@@ -7,17 +7,51 @@ over a server cluster. However, Nitro can also power simple web
|
|
7
7
|
applications for deployment on intranets or even personal computers.
|
8
8
|
Nitro integrates the powerful Og Object-Relational mapping library.
|
9
9
|
|
10
|
-
Nitro is a multiparadigm application framework and
|
11
|
-
from Rails, Wee, PHP, JSP and .NET
|
10
|
+
Nitro is a multiparadigm application framework and will incorporate ideas
|
11
|
+
from Rails, Wee, PHP, JSP and Microsoft.NET.
|
12
12
|
|
13
13
|
|
14
14
|
== Features
|
15
15
|
|
16
16
|
A short summary of the major features:
|
17
17
|
|
18
|
+
* Multiparadigm web appliacations.
|
19
|
+
|
20
|
+
You can write applications in the ASP/JSP/PHP style, ie by writting
|
21
|
+
server pages that are automatically transalted to Ruby code by
|
22
|
+
Nitro.
|
23
|
+
|
24
|
+
Alternatively, you can write Rails style application by utilizing
|
25
|
+
the powerfull Controller mechanism.
|
26
|
+
|
27
|
+
* Advanced Code generation.
|
28
|
+
|
29
|
+
Nitro in essence writes your Web application for you. The system
|
30
|
+
provides a number of domain spefic language extensions (meta-languages)
|
31
|
+
to automate generate of common code (OR mapping, validation,
|
32
|
+
forms generation, syndication, markup and more).
|
33
|
+
|
34
|
+
* Object-Relational Mapping
|
35
|
+
|
36
|
+
Nitro integrates the Og (ObjectGraph) object-relational mapping
|
37
|
+
library. Og provides transparent serialization of object graphs to a RDBMS
|
38
|
+
backend. Unlike other similar libraries Og maps standard Ruby
|
39
|
+
objects to SQL tables and not vice versa. Og provides a meta language
|
40
|
+
to describe the relations between objects, a flexible and intuitive api
|
41
|
+
for querieng the database, raw access to the SQL language if needed
|
42
|
+
(for example to fine tune the automatically generated SQL tables, or
|
43
|
+
for custom queries), provides automatic validation, suports deserialization
|
44
|
+
to Ruby objects or tuples, automatically generates join tables for
|
45
|
+
many_to_many relations and provides a collection of usefull Mixins to
|
46
|
+
synthesize common Entities.
|
47
|
+
|
48
|
+
Og is a combination of the best features of Active Record and the
|
49
|
+
former O-R mapping library included in Nitro (NDB). Adapters for
|
50
|
+
PostgreSQL and MySQL are included.
|
51
|
+
|
18
52
|
* XML server pages (.xhtml)
|
19
53
|
|
20
|
-
Nitro uses standard,
|
54
|
+
Nitro uses standard, fully xml compliant xhtml pages with logic
|
21
55
|
code, thus combining the power of embededed Ruby (like erb, eruby)
|
22
56
|
with the xml compliance of Amrita. Even though it is a 'Callback'
|
23
57
|
style templating system it is flexible enough to run as 'Pipeline'
|
@@ -27,6 +61,7 @@ A short summary of the major features:
|
|
27
61
|
|
28
62
|
<!-- example page -->
|
29
63
|
<html>
|
64
|
+
|
30
65
|
<?r
|
31
66
|
title = 'Example'
|
32
67
|
version = params['version']
|
@@ -39,6 +74,32 @@ A short summary of the major features:
|
|
39
74
|
<?r end ?>
|
40
75
|
|
41
76
|
</html>
|
77
|
+
|
78
|
+
* Action / Fragment Synthesis
|
79
|
+
|
80
|
+
Nitro actions and templates can include other actions or templates
|
81
|
+
to allow for component-based development.
|
82
|
+
|
83
|
+
Here is an example of including an action from a template:
|
84
|
+
|
85
|
+
<render href="list" />
|
86
|
+
|
87
|
+
or
|
88
|
+
|
89
|
+
<inject href="list" />
|
90
|
+
|
91
|
+
or from an action:
|
92
|
+
|
93
|
+
list()
|
94
|
+
|
95
|
+
Nitro server pages can include fragments at 'Compile' time or at
|
96
|
+
'RunTime' time.
|
97
|
+
|
98
|
+
<!-- compile time include (static include) -->
|
99
|
+
<?include href="myfile.inc" />
|
100
|
+
|
101
|
+
<!-- run time include (dynamic include) -->
|
102
|
+
<include href="myfile.inc" />
|
42
103
|
|
43
104
|
* Shaders, XSLT templates
|
44
105
|
|
@@ -52,45 +113,23 @@ A short summary of the major features:
|
|
52
113
|
precompiles the xsl transformation along with other transformations
|
53
114
|
(for example localization) essentially providing a computationally
|
54
115
|
free transformation step.
|
55
|
-
|
56
|
-
* Multi phase evaluation
|
57
116
|
|
58
|
-
|
117
|
+
* Multiple Platforms
|
59
118
|
|
60
|
-
|
119
|
+
Runs on Linux and Windows. Has not been tested under MacOSX and
|
120
|
+
other Unices.
|
61
121
|
|
62
|
-
|
63
|
-
'RunTime' time.
|
64
|
-
|
65
|
-
<!-- compile time include (static include) -->
|
66
|
-
<?include href="myfile.si" />
|
67
|
-
|
68
|
-
<!-- run time include (dynamic include) -->
|
69
|
-
<include href="myfile.si" />
|
122
|
+
* Multiple Adaptors
|
70
123
|
|
124
|
+
Nitro supports multiple web server configurations. Out of the box
|
125
|
+
it supports WEBrick (pure ruby), Lighttpd (fastcgi), Apache (fastcgi).
|
126
|
+
More options will be available in the future.
|
127
|
+
|
71
128
|
* Minimum configuration
|
72
129
|
|
73
130
|
Configuration files are kept to the absolute minimum. The target
|
74
131
|
is to have no configuration files at all.
|
75
132
|
|
76
|
-
* Object-Relational Mapping
|
77
|
-
|
78
|
-
Nitro integrates the Og (ObjectGraph) object-relational mapping
|
79
|
-
library. Og provides transparent serialization of object graphs to a RDBMS
|
80
|
-
backend. Unlike other similar libraries Og maps standard Ruby
|
81
|
-
objects to SQL tables and not vice versa. Og provides a meta language
|
82
|
-
to describe the relations between objects, a flexible and intuitive api
|
83
|
-
for querieng the database, raw access to the SQL language if needed
|
84
|
-
(for example to fine tune the automatically generated SQL tables, or
|
85
|
-
for custom queries), provides automatic validation, suports deserialization
|
86
|
-
to Ruby objects or tuples, automatically generates join tables for
|
87
|
-
many_to_many relations and provides a collection of usefull Mixins to
|
88
|
-
synthesize common Entities.
|
89
|
-
|
90
|
-
Og is a combination of the best features of Active Record and the
|
91
|
-
former O-R mapping library included in Nitro (NDB). Adapters for
|
92
|
-
PostgreSQL and MySQL are included.
|
93
|
-
|
94
133
|
* Distributed State
|
95
134
|
|
96
135
|
Nitro provides a powerfull distributed state mechanism that utilizes
|
@@ -108,6 +147,15 @@ A short summary of the major features:
|
|
108
147
|
Moreover, Nitro provides the fine-grained filtering method pioneered
|
109
148
|
by Rails where you can attach single methods, blocks, objects or
|
110
149
|
modules, before, after or arrounf actions.
|
150
|
+
|
151
|
+
* Parts
|
152
|
+
|
153
|
+
Parts are organized modules of web services. A Web Framework that
|
154
|
+
integrates a large collection of parts (User management, Blog,
|
155
|
+
Fora, CMS, Personalization, ..) will be released by Navel.
|
156
|
+
|
157
|
+
Other libraries of parts are expected from the Ruby community when
|
158
|
+
the Part API is finalized.
|
111
159
|
|
112
160
|
* Hierarchical Caching
|
113
161
|
|
@@ -122,6 +170,10 @@ A short summary of the major features:
|
|
122
170
|
The engine calculates intra-page dependencies automatically. A variety
|
123
171
|
of invalidation strategies can be implemented.
|
124
172
|
|
173
|
+
* Multi phase evaluation
|
174
|
+
|
175
|
+
Experimental, facilitates efficient HTTP1.1 caching.
|
176
|
+
|
125
177
|
* Programmatic xhtml rendering.
|
126
178
|
|
127
179
|
options = ['Male', 'Female']
|
@@ -154,13 +206,9 @@ A short summary of the major features:
|
|
154
206
|
|
155
207
|
Experimental.
|
156
208
|
|
157
|
-
* Simple events manager.
|
158
|
-
|
159
|
-
Experimental.
|
160
|
-
|
161
209
|
* Advanced debuging features
|
162
210
|
|
163
|
-
* When running in debug mode, all exceptions
|
211
|
+
* When running in debug mode, all exceptions raised are logged
|
164
212
|
to a special debug panel in the current page. Find out the offending
|
165
213
|
file and line from the exception dump, fix the bug, refresh the page.
|
166
214
|
|
@@ -173,15 +221,6 @@ A short summary of the major features:
|
|
173
221
|
state, diagnose bugs all via IRB by simply setting breakpoints in
|
174
222
|
your applications by the call of a method.
|
175
223
|
|
176
|
-
* Parts
|
177
|
-
|
178
|
-
Parts are organized modules of web services. A Web Framework that
|
179
|
-
integrates a large collection of parts (User management, Blog,
|
180
|
-
Fora, CMS, Personalization, ..) will be released by Navel.
|
181
|
-
|
182
|
-
Other libraries of parts are expected from the Ruby community when
|
183
|
-
the Part API is finalized.
|
184
|
-
|
185
224
|
* UI Components
|
186
225
|
|
187
226
|
Nitro is distributed with a collection of usefull UI components
|
@@ -212,29 +251,48 @@ Documentation for Nitro can be found at
|
|
212
251
|
|
213
252
|
Nitro requires the following applications or libraries:
|
214
253
|
|
215
|
-
* Ruby 1.8.1 and greater
|
216
|
-
|
254
|
+
* Ruby 1.8.1 and greater
|
255
|
+
http://www.ruby-lang.org
|
256
|
+
Version 1.8.2 is recomended
|
217
257
|
|
218
|
-
|
219
|
-
Will be optional in a future version.
|
258
|
+
The following applications or libraries are OPTIONAL:
|
220
259
|
|
221
|
-
|
222
|
-
|
223
|
-
* PostgreSQL (http://www.postgres.org)
|
260
|
+
* PostgreSQL
|
261
|
+
http://www.postgres.org
|
224
262
|
Used for Database driven web applications.
|
225
263
|
|
226
|
-
* MySQL
|
264
|
+
* MySQL
|
265
|
+
http://www.mysql.org
|
227
266
|
Used for Database driven web applications.
|
228
267
|
|
229
|
-
* Ruby-psql
|
268
|
+
* Ruby-psql
|
269
|
+
http://www.postgresql.jp/interfaces/ruby/archive/ruby-postgres-0.7.1.tar.gz
|
230
270
|
Ruby interface to the PostgreSQL RDBMS.
|
231
271
|
|
232
|
-
* Ruby-mysql
|
272
|
+
* Ruby-mysql
|
273
|
+
http://tmtm.org/ja/ruby/mysql/README_en.html
|
233
274
|
Ruby interface to the MySQL RDBMS.
|
234
275
|
|
235
|
-
* Ruby-XSLT
|
276
|
+
* Ruby-XSLT
|
277
|
+
http://gregoire.lejeune.free.fr/ruby-xslt_0.4.0.tar.gz
|
236
278
|
Used for XSLT based templates.
|
237
279
|
|
280
|
+
* Apache 2.0
|
281
|
+
http://www.apache.org
|
282
|
+
Used to host application in production environments.
|
283
|
+
|
284
|
+
* Lighttpd
|
285
|
+
http://www.lighttpd.net/
|
286
|
+
A lean and efficient web server. A perfect companion to Nitro.
|
287
|
+
|
288
|
+
* Ruby-fcgi
|
289
|
+
http://www.moonwolf.com/ruby/archive/ruby-fcgi-0.8.5.tar.gz
|
290
|
+
Used for FCGI based applications.
|
291
|
+
|
292
|
+
* FastCGI development kit
|
293
|
+
http://www.fastcgi.com/dist/fcgi.tar.gz
|
294
|
+
Needed to compile the C-version of the ruby fcgi library.
|
295
|
+
|
238
296
|
Please install the required applications and libraries before continuing
|
239
297
|
with the installation of Nitro.
|
240
298
|
|
@@ -248,7 +306,7 @@ gem install nitro
|
|
248
306
|
|
249
307
|
Then try to run the examples/tiny Example application.
|
250
308
|
|
251
|
-
A tar.gz distribution is also available on http://www.
|
309
|
+
A tar.gz distribution is also available on http://www.rubyforge.com/projects/nitro
|
252
310
|
|
253
311
|
|
254
312
|
== Running the example applications
|
@@ -263,7 +321,15 @@ $ vi conf/apache.conf
|
|
263
321
|
|
264
322
|
edit user, group,DocumentRoot root as needed.
|
265
323
|
|
266
|
-
|
324
|
+
or
|
325
|
+
|
326
|
+
$vi conf/lhttpd.conf
|
327
|
+
|
328
|
+
edit as needed, or
|
329
|
+
|
330
|
+
$ vi conf/app.conf.rb
|
331
|
+
|
332
|
+
$ ruby ctl
|
267
333
|
|
268
334
|
this script starts the distributed session cluster, apache and the
|
269
335
|
application server.
|
@@ -274,17 +340,19 @@ to stop the application execute:
|
|
274
340
|
|
275
341
|
$ ./ctl stop
|
276
342
|
|
277
|
-
* examples/
|
343
|
+
* examples/blog
|
278
344
|
|
279
|
-
A simple application to demonstrate xsl skins,
|
345
|
+
A simple Blog application to demonstrate xsl skins, Og models,
|
346
|
+
xml dispatchers and more.
|
280
347
|
|
281
|
-
$ cd nitro/examples/
|
348
|
+
$ cd nitro/examples/blog
|
282
349
|
|
283
350
|
$ vi conf/apache.conf
|
351
|
+
$ vi conf/lhttpd.conf
|
284
352
|
|
285
|
-
edit
|
353
|
+
edit the configuration as needed.
|
286
354
|
|
287
|
-
$ vi conf/
|
355
|
+
$ vi conf/app.conf.rb
|
288
356
|
|
289
357
|
edit the postgresql user and password
|
290
358
|
|
@@ -299,33 +367,20 @@ edit the configuration file to include
|
|
299
367
|
|
300
368
|
instead.
|
301
369
|
|
302
|
-
|
303
|
-
|
370
|
+
there is no need to initialize the database, Og automatically
|
371
|
+
takes cate of this.
|
304
372
|
|
305
|
-
$ ruby
|
373
|
+
$ ruby ctl
|
306
374
|
|
307
|
-
|
308
|
-
|
309
|
-
this script starts the distributed session cluster, apache and the
|
310
|
-
application server.
|
375
|
+
this script starts the the blog application using the WEBrick
|
376
|
+
adapter.
|
311
377
|
|
312
378
|
browse http://127.0.0.1:8080
|
313
379
|
|
314
|
-
to attach an irb console to the running server, execute from
|
315
|
-
another shell:
|
316
|
-
|
317
|
-
$ cd /examples/simple
|
318
|
-
|
319
|
-
$ irb -r env.rb
|
320
|
-
|
321
|
-
to stop the application execute:
|
322
|
-
|
323
|
-
$ ./ctl stop
|
324
|
-
|
325
380
|
|
326
381
|
== Debuging Nitro applications
|
327
382
|
|
328
|
-
Have "tail -f" commands running on
|
383
|
+
Have "tail -f" commands running on log/app.log in your application
|
329
384
|
directory. Nitro will automatically display debugging and runtime
|
330
385
|
information to these files. Debugging info will also be shown in the
|
331
386
|
browser when running in debug mode.
|
@@ -337,9 +392,11 @@ bin
|
|
337
392
|
Commands and wizards.
|
338
393
|
|
339
394
|
examples/
|
340
|
-
Various examples. 'tiny' is a minimal example, 'blog' is a
|
341
|
-
nice looking Blog implementation, '
|
342
|
-
is
|
395
|
+
Various examples. 'tiny' is a minimal example, 'blog' is a
|
396
|
+
fully working and nice looking Blog implementation, 'no_xsl_blog'
|
397
|
+
is the same example without using XSLT, 'og' contains some Og
|
398
|
+
examples and 'flash' is an example for generating binary content
|
399
|
+
for a Nitro response.
|
343
400
|
|
344
401
|
lib/nitro
|
345
402
|
Nitro library source files.
|
@@ -350,9 +407,13 @@ lib/og
|
|
350
407
|
lib/glue
|
351
408
|
Common source files.
|
352
409
|
|
410
|
+
lib/parts
|
411
|
+
Nitro Web Framework parts. A part is a module of functionality
|
412
|
+
|
353
413
|
test
|
354
414
|
Unit and functional tests.
|
355
415
|
|
416
|
+
|
356
417
|
== Running Tests
|
357
418
|
|
358
419
|
The easiest way to run the included unit tests is through Rake:
|
@@ -367,16 +428,23 @@ runs all tests except the database tests.
|
|
367
428
|
|
368
429
|
Rake can be found at http://rake.rubyforge.org
|
369
430
|
|
431
|
+
|
370
432
|
== Support
|
371
433
|
|
372
434
|
For any questions regarding Nitro, feel free to ask on the ruby-talk
|
373
435
|
mailing list (which is mirrored to comp.lang.ruby) or contact
|
374
436
|
mailto:gm@navel.gr.
|
375
437
|
|
438
|
+
A Nitro specific mailing list is also available. Please subscribe
|
439
|
+
to nitro-general@rubyforge.com. The homepage for this list
|
440
|
+
is available here:
|
441
|
+
|
442
|
+
http://rubyforge.org/mailman/listinfo/nitro-general
|
443
|
+
|
376
444
|
|
377
445
|
== Licence
|
378
446
|
|
379
|
-
Copyright (c) 2004 Navel Ltd (http://www.navel.gr)
|
447
|
+
Copyright (c) 2004-2005 Navel Ltd (http://www.navel.gr)
|
380
448
|
|
381
449
|
Nitro (http://www.navel.gr/nitro) is copyrighted free software
|
382
450
|
created and maintained by George Moschovitis (mailto:gm@navel.gr)
|
data/RELEASES
CHANGED
@@ -1,3 +1,53 @@
|
|
1
|
+
== Version 0.9.3 was released on 01/02/2005.
|
2
|
+
|
3
|
+
A *very* important release. A new abstract rendering
|
4
|
+
pipeline is introduced. This pipeline allows for multiple
|
5
|
+
adaptors (WEBrick, fastcgi are included).
|
6
|
+
|
7
|
+
Many classes have be rewritten using *clean* code,
|
8
|
+
and the directory structure has improved again. All
|
9
|
+
unused and obsolete files have been removed. A new
|
10
|
+
version of the Blog example was included. This version
|
11
|
+
does not use XSLT and runs on Windows.
|
12
|
+
|
13
|
+
If you havent seen Nitro or you had problems with an
|
14
|
+
earlier version, this is the time to revisit this
|
15
|
+
project!
|
16
|
+
|
17
|
+
Most notable additions:
|
18
|
+
|
19
|
+
* Drastically improved source code readability.
|
20
|
+
|
21
|
+
* New abstract rendering pipeline. Benefits:
|
22
|
+
|
23
|
+
* multiple adaptors.
|
24
|
+
* better unit tests.
|
25
|
+
* optimized memory allocation.
|
26
|
+
* more modular desing.
|
27
|
+
|
28
|
+
* FastCGI support (tested with Lighttpd).
|
29
|
+
|
30
|
+
* no_xsl_blog example.
|
31
|
+
|
32
|
+
This new example is easier to setup, even on Windows.
|
33
|
+
This also demonstrates that Nitro does NOT force
|
34
|
+
the use of XSLT.
|
35
|
+
|
36
|
+
* No global variables used for nitro configuration.
|
37
|
+
|
38
|
+
* Updated the docs to better reflect the rappidly
|
39
|
+
evolving codebase.
|
40
|
+
|
41
|
+
* Og metalanguage relations insert metadata into
|
42
|
+
the target class, useful for advanced scaffolders.
|
43
|
+
|
44
|
+
* Og refer_to meta-language command.
|
45
|
+
|
46
|
+
* Many bug fixes and small optimizations.
|
47
|
+
|
48
|
+
The next version will stabilize the Nitro api.
|
49
|
+
|
50
|
+
|
1
51
|
== Version 0.8 was released on 12/01/2005.
|
2
52
|
|
3
53
|
A snapshot of the latest code. Cool new features,
|