<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to Tutorial</title><link>https://sourceforge.net/p/rupy/wiki/Tutorial/</link><description>Recent changes to Tutorial</description><atom:link href="https://sourceforge.net/p/rupy/wiki/Tutorial/feed" rel="self"/><language>en</language><lastBuildDate>Fri, 13 Mar 2015 09:59:55 -0000</lastBuildDate><atom:link href="https://sourceforge.net/p/rupy/wiki/Tutorial/feed" rel="self" type="application/rss+xml"/><item><title>Discussion for Tutorial page</title><link>https://sourceforge.net/p/rupy/wiki/Tutorial/</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Originally posted by: &lt;a class="" href="http://code.google.com/u/107481926010117983765" rel="nofollow"&gt;pragmati...@gmail.com&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;In order to run the chat (talk) sample on Ubuntu, I had to make the following changes: &lt;/p&gt;
&lt;p&gt;1. Navigate to http folder, execute the command &lt;strong&gt;chmod +x run.sh&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;2. Modify run.sh to &lt;strong&gt;java -classpath .:bin/http.jar:../talk/lib/json.jar se.rupy.http.Daemon -verbose -pass secret&lt;/strong&gt;&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Anonymous</dc:creator><pubDate>Fri, 13 Mar 2015 09:59:55 -0000</pubDate><guid>https://sourceforge.net8e0c94c17d71e7572b9f311fd457803953da6057</guid></item><item><title>Tutorial modified by Anonymous</title><link>https://sourceforge.net/p/rupy/wiki/Tutorial/</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;&lt;strong&gt;&lt;em&gt;Prerequisites&lt;/em&gt;&lt;/strong&gt;&lt;em&gt;: You need a &lt;a class="" href="http://www.oracle.com/technetwork/java/javase/downloads/index.html" rel="nofollow"&gt;JDK &lt;/a&gt; and &lt;a class="" href="http://ant.apache.org" rel="nofollow"&gt;Ant&lt;/a&gt; installed on your computer and added to the path. Also you might need to add JAVA_HOME and ANT_HOME environment variables.&lt;/em&gt;&lt;/p&gt;
&lt;hr /&gt;
&lt;h3 id="local"&gt;local&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;Download the &lt;a class="" href="http://rupy.googlecode.com/files/page-0.6.zip" rel="nofollow"&gt;page&lt;/a&gt; application, together with the latest &lt;a class="" href="http://rupy.googlecode.com/files/rupy-1.1.zip" rel="nofollow"&gt;rupy&lt;/a&gt; and extract them to the same folder. Go to the http/ folder first and start rupy with either the &lt;em&gt;run.bat&lt;/em&gt; or &lt;em&gt;run.sh&lt;/em&gt; script depending on your OS. Then go to the page/ folder and run the &lt;em&gt;ant local&lt;/em&gt; task, this should build and deploy the test application to your rupy server. Now try browsing to &lt;a href="http://localhost:8000" rel="nofollow"&gt;http://localhost:8000&lt;/a&gt;. &lt;/p&gt;
&lt;/blockquote&gt;
&lt;hr /&gt;
&lt;h3 id="remote"&gt;remote&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;If you wan't to deploy to &lt;a class="" href="http://host.rupy.se" rel="nofollow"&gt;host.rupy.se&lt;/a&gt; you can follow the &lt;strong&gt;local&lt;/strong&gt; tutorial above with these changes: &lt;/p&gt;
&lt;/blockquote&gt;
&lt;ol&gt;
&lt;li&gt;You need to edit the &lt;em&gt;page/build.xml&lt;/em&gt; script with your domain and the password given to you when you register at &lt;a class="" href="http://host.rupy.se" rel="nofollow"&gt;host.rupy.se&lt;/a&gt;. &lt;/li&gt;
&lt;li&gt;You should run &lt;em&gt;ant remote&lt;/em&gt; instead of &lt;em&gt;ant local&lt;/em&gt;. &lt;/li&gt;
&lt;/ol&gt;
&lt;hr /&gt;
&lt;p&gt;We have started the development of &lt;a class="" href="http://sprout.googlecode.com" rel="nofollow"&gt;sprout&lt;/a&gt;, a simple blogger; based on top of rupy and &lt;a class="" href="http://memory.googlecode.com" rel="nofollow"&gt;memory&lt;/a&gt;. If you want a real-world example of rupy in action try this out! &lt;/p&gt;
&lt;hr /&gt;
&lt;p&gt;Let's create a rootservice (when you browse to "/") that returns 'hello'. &lt;/p&gt;
&lt;div class="codehilite"&gt;&lt;pre&gt;&lt;span class="n"&gt;import&lt;/span&gt; &lt;span class="n"&gt;se&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;rupy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;http&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="o"&gt;*&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="n"&gt;public&lt;/span&gt; &lt;span class="n"&gt;Hello&lt;/span&gt; &lt;span class="n"&gt;extends&lt;/span&gt; &lt;span class="n"&gt;Service&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="n"&gt;public&lt;/span&gt; &lt;span class="n"&gt;String&lt;/span&gt; &lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="s"&gt;"/"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="n"&gt;public&lt;/span&gt; &lt;span class="kt"&gt;void&lt;/span&gt; &lt;span class="n"&gt;filter&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Event&lt;/span&gt; &lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="n"&gt;throws&lt;/span&gt; &lt;span class="n"&gt;Event&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;Exception&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="n"&gt;event&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;output&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="n"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"hello"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Compile the Hello class above and put it in a jar file (hello.jar in the example below), then upload it to a running rupy server (run.bat or run.sh) in your ant script like this: &lt;/p&gt;
&lt;div class="codehilite"&gt;&lt;pre&gt;&lt;span class="nt"&gt;&amp;lt;target&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"deploy"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;java&lt;/span&gt; &lt;span class="na"&gt;fork=&lt;/span&gt;&lt;span class="s"&gt;"yes"&lt;/span&gt; &lt;span class="na"&gt;classname=&lt;/span&gt;&lt;span class="s"&gt;"se.rupy.http.Deploy"&lt;/span&gt; &lt;span class="na"&gt;classpath=&lt;/span&gt;&lt;span class="s"&gt;"http.jar"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;arg&lt;/span&gt; &lt;span class="na"&gt;line=&lt;/span&gt;&lt;span class="s"&gt;"localhost:8000"&lt;/span&gt;&lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;arg&lt;/span&gt; &lt;span class="na"&gt;line=&lt;/span&gt;&lt;span class="s"&gt;"hello.jar"&lt;/span&gt;&lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;arg&lt;/span&gt; &lt;span class="na"&gt;line=&lt;/span&gt;&lt;span class="s"&gt;"secret"&lt;/span&gt;&lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;&lt;span class="c"&gt;&amp;lt;!-- see run.bat and run.sh --&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/java&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/target&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Anonymous</dc:creator><pubDate>Fri, 13 Mar 2015 09:59:55 -0000</pubDate><guid>https://sourceforge.net5b28eee08f18f5af22d4829fc876f73843c75370</guid></item></channel></rss>