diff options
author | lresende <lresende@13f79535-47bb-0310-9956-ffa450edef68> | 2008-08-12 23:50:52 +0000 |
---|---|---|
committer | lresende <lresende@13f79535-47bb-0310-9956-ffa450edef68> | 2008-08-12 23:50:52 +0000 |
commit | f77d19253269af16449e8af0936b944e842e2a4d (patch) | |
tree | b56d0ede1705a773ebabc4ae63624dad267aeb43 /java/sca | |
parent | 8dd1dfb46f140d376388678590f99d37f70de8c5 (diff) |
Refactoring the launcher to follow the same pattern used in other apps (launch.launchxxxx launcher)
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@685380 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to '')
-rw-r--r-- | java/sca/samples/feed-aggregator/README | 9 | ||||
-rw-r--r-- | java/sca/samples/feed-aggregator/build.xml | 2 | ||||
-rw-r--r-- | java/sca/samples/feed-aggregator/src/main/java/launch/LaunchFeedServer.java (renamed from java/sca/samples/feed-aggregator/src/main/java/feed/SampleServer.java) | 11 |
3 files changed, 9 insertions, 13 deletions
diff --git a/java/sca/samples/feed-aggregator/README b/java/sca/samples/feed-aggregator/README index 14f2d94876..f73baec2fd 100644 --- a/java/sca/samples/feed-aggregator/README +++ b/java/sca/samples/feed-aggregator/README @@ -13,11 +13,11 @@ ant run OR if you don't have ant, on Windows do -java -cp ..\..\lib\tuscany-sca-manifest.jar;target\sample-feed-aggregator.jar feed.SampleServer +java -cp ..\..\lib\tuscany-sca-manifest.jar;target\sample-feed-aggregator.jar launch.LaunchFeedServer and on *nix do -java -cp ../../lib/tuscany-sca-manifest.jar:target/sample-feed-aggregator.jar feed.SampleServer +java -cp ../../lib/tuscany-sca-manifest.jar:target/sample-feed-aggregator.jar launch.LaunchFeedServer You should see the following output on the screen. @@ -56,10 +56,11 @@ web-resource/ feed/ AggregatorImpl.java - implementation of the Feed aggregator component - SampleServer.java - starts the SCA Runtime and - publishes the aggregated feeds Sort.java - utilty interface SortImpl.java - implementation of the Sort component + launch + LaunchFeedServer.java - starts the SCA Runtime and + publishes the aggregated feeds resources/ FeedAggregator.composite - the SCA assembly for this sample feed-aggregator.png - a pictorial representation of the diff --git a/java/sca/samples/feed-aggregator/build.xml b/java/sca/samples/feed-aggregator/build.xml index 2118e13db7..0ab6fed7fc 100644 --- a/java/sca/samples/feed-aggregator/build.xml +++ b/java/sca/samples/feed-aggregator/build.xml @@ -17,7 +17,7 @@ * under the License. --> <project name="feed-aggregator" default="compile"> - <property name="test.class" value="feed.SampleServer" /> + <property name="test.class" value="launch.LaunchFeedServer" /> <property name="test.jar" value="sample-feed-aggregator.jar" /> <target name="init"> diff --git a/java/sca/samples/feed-aggregator/src/main/java/feed/SampleServer.java b/java/sca/samples/feed-aggregator/src/main/java/launch/LaunchFeedServer.java index 2aace3daf7..1c549f7cd2 100644 --- a/java/sca/samples/feed-aggregator/src/main/java/feed/SampleServer.java +++ b/java/sca/samples/feed-aggregator/src/main/java/launch/LaunchFeedServer.java @@ -16,15 +16,15 @@ * specific language governing permissions and limitations * under the License. */ -package feed; + +package launch; import java.io.IOException; import org.apache.tuscany.sca.host.embedded.SCADomain; -public class SampleServer { +public class LaunchFeedServer { public static void main(String[] args) throws Exception { - SCADomain scaDomain = SCADomain.newInstance("FeedAggregator.composite"); try { @@ -40,11 +40,6 @@ public class SampleServer { e.printStackTrace(); } - // RssFeed feedService = scaDomain.getService(RssFeed.class, - // "RssAggregatorComponent"); - // SyndFeed syndFeed = feedService.get(); - // SyndFeedOutput output = new SyndFeedOutput(); - // output.output(syndFeed,new PrintWriter(System.out)); scaDomain.close(); System.out.println("Sample Feed server stopped"); |