You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by sl...@apache.org on 2007/06/01 17:26:35 UTC

svn commit: r543504 - in /incubator/tuscany/sandbox/slaws/httpserver.php: README htdocs/AlertDisplay.php htdocs/AlertDisplayJson.php htdocs/Alerts.xsd htdocs/AlertsSources.wsdl htdocs/Cached_Alerts.xml htdocs/index.html htdocs/service.smd

Author: slaws
Date: Fri Jun  1 08:26:34 2007
New Revision: 543504

URL: http://svn.apache.org/viewvc?view=rev&rev=543504
Log:
Fix up to match new server interfaces

Added:
    incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplayJson.php   (with props)
    incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/service.smd   (with props)
Modified:
    incubator/tuscany/sandbox/slaws/httpserver.php/README
    incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplay.php   (contents, props changed)
    incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/Alerts.xsd
    incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertsSources.wsdl
    incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/Cached_Alerts.xml
    incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/index.html

Modified: incubator/tuscany/sandbox/slaws/httpserver.php/README
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/slaws/httpserver.php/README?view=diff&rev=543504&r1=543503&r2=543504
==============================================================================
--- incubator/tuscany/sandbox/slaws/httpserver.php/README (original)
+++ incubator/tuscany/sandbox/slaws/httpserver.php/README Fri Jun  1 08:26:34 2007
@@ -1,30 +1,25 @@
 Alert Aggregator - PHP Display Component
 ========================================
 
-This httpserver configuration includes a PHP implementation of the display
-component that replaces the python component in sample.display.
+This httpserver configuration includes a PHP implementation of the 
+feed aggregator display component
 
-The HTTPD configuration created by the startserver scrips relies on the 
-PHP_HOME environment variable in order to install PHP in Apache as follows:
+The startserver script can be used to start up an HTTPD server
+configured to run the display component. It relies on two environment
+variables being correctl configured. See the top of startserver.bat.
 
-LoadModule php5_module %PHP_HOME%\php5apache2.dll
-AddType application/x-httpd-php .php 
-PHPIniDir %PHP_HOME% 
+PHP must be configured to include the PHP SCA_SDO v1.2.1 extension from PECL.
+
+http://pecl.php.net/package/sca_sdo
 
-PHP must be configured to include the PHP SCA_SDO extension from PECL.
 This provides the SCA and SDO support that the display component relies on. 
-Currently you must have the version from the AVOCET branch as changes have
-been made here that this application requires. 
 
-To run the AlertAggregator sample with the PHP component you must start the
-original HTTP server, e.g., on windows
+To run the display component on windows. 
 
-> cd AlertAggregator\httpserver
-> startserver.bat
+> cd httpserver.php
 
-and then start the HTTPD server that servers the PHP part of the application, e.g.,
+fix up the paths at the top of startserver.bat and then
 
-> cd AlertAggregator\httpserver.php
 > startserver.bat
 
 then point your browser at 

Modified: incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplay.php
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplay.php?view=diff&rev=543504&r1=543503&r2=543504
==============================================================================
--- incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplay.php (original)
+++ incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplay.php Fri Jun  1 08:26:34 2007
@@ -53,13 +53,13 @@
         $request->parm = "AString";
         $new_alerts = $this->alert_service->getAllNewAlerts($request);
    
-        foreach($new_alerts->parm as $alert){
+        foreach($new_alerts->parm->Alert as $alert){
             $new_alert = $cached_alerts->createDataObject('Alert');
             $new_alert->Title    = $alert->Title;
             $new_alert->Summary  = $alert->Summary;
             $new_alert->Address  = $alert->Address;
             $new_alert->Date     = $alert->Date; 
-            $new_alert->SourceId = $alert->Sourceid;  
+            $new_alert->SourceId = $alert->SourceId;  
             $new_alert->Unread   = true;         
         }
                
@@ -104,8 +104,7 @@
         
         $return_summary = "";
 
-        foreach($cached_alerts->alert as $alert){
-SCA::$logger->log($alert->Id . " vs " . $alert_id );             
+        foreach($cached_alerts->alert as $alert){         
             if (strcmp($alert->Id,$alert_Id) == 0){
                 SCA::$logger->log("Match");
                 $alert->Unread = false;
@@ -128,17 +127,12 @@
                                                           "getAlertSources");
         $request->parm = "AString";
         $alert_sources = $this->alert_sources_service->getAlertSources($request);
-
-// some debug        
-//ob_start();
-//print_r( $alert_sources );
-//$debug = ob_get_contents();
-//ob_end_clean();
-//SCA::$logger->log($debug);
-        
+       
         $return_table = "<TABLE border='0'>\n";        
-    
-        foreach ($alert_sources->parm as $alert_source){
+
+        $no_of_sources = 0;
+
+        foreach ($alert_sources->parm->Source as $alert_source){
             $source_id = $alert_source->Id;
             $return_row = <<<SOURCEROW
 <TR CLASS="source_$source_id" >
@@ -174,9 +168,63 @@
   </TD>
 </TR>
 SOURCEROW;
-            $return_table = $return_table . $return_row;        
+            $return_table = $return_table . $return_row;  
+            $no_of_sources = $no_of_sources + 1;      
         }
 
+        $source_id = $no_of_sources + 1;
+
+        $return_row = <<<ADDROW
+<TR CLASS="source_$source_id">
+  <TD COLSPAN="4" CLASS="clickable link" ONCLICK="showAddNewSource('$source_id')">Add new Alert Source</TD>
+</TR>
+<TR ID="add_source_$source_id" CLASS="hidden source_$source_id">
+  <TD COLSPAN="4">
+    <TABLE CLASS="sourceDetailsTable">
+      <TR>
+        <TD>Source name:</TD>
+        <TD>
+          <INPUT ID="source_{$source_id}_name" TYPE="TEXT" SIZE="50">
+        </TD>
+      </TR>
+      <TR>
+        <TD>Source address:</TD>
+        <TD>
+          <INPUT ID="source_{$source_id}_address" TYPE="TEXT" SIZE="50">
+        </TD>
+      </TR>
+      <TR>
+        <TD>Source type:</TD>
+        <TD>
+          <SELECT ID="source_{$source_id}_type" ONCHANGE="showSourceType('$source_id')">
+            <OPTION value="rss" selected="selected">RSS/Atom feed</OPTION>"
+          </SELECT>
+        </TD>
+      </TR>
+      <TR ID="add_rss_source">
+        <TD COLSPAN="2">
+          <TABLE CLASS="sourceDetailsTable">
+            <TR>
+              <TD>Feed address:</TD>
+              <TD>
+                 <INPUT ID="source_{$source_id}_feedAddress" TYPE="TEXT" SIZE="50"/>
+              </TD>
+            </TR>
+          </TABLE>
+        </TD>
+      </TR>
+      <TR>
+        <TD>
+          <INPUT TYPE="BUTTON" VALUE="Add" ONCLICK="addSource('$source_id')">
+          <INPUT TYPE="BUTTON" VALUE="Cancel" ONCLICK="hideAddNewSource('$source_id')">
+        </TD>
+      </TR>
+    </TABLE>
+  </TD>
+</TR>
+ADDROW;
+
+        $return_table = $return_table . $return_row;
         $return_table = $return_table . "</TABLE>\n";
         return $return_table;
     }
@@ -185,29 +233,41 @@
       * @param integer $source_id
       * @return string
       */ 
-    public function deleteAlertSource($source_id){
-        # Use the alertService reference    
-        $this->alertService->removeAlertSource($source_id);
-        
-        //TODO
+    public function deleteAlertSource($source_id){ 
+        $this->alert_sources_service->removeAlertSource($source_id);
     }
         
     /**
-      * @param Source $alert_source http://tuscany.apache.org/sca/samples/aggregator/types
+      * @param SingleSourceType $alert_source http://tuscany.apache.org/sca/samples/aggregator/types
       */ 
-    public function addAlertSource($alert_source){
-        # Use the alertService reference    
-        $this->alertService->addAlertSource($alert_source);
+    public function addAlertSource($alert_source){    
+        $request = $this->alert_sources_service->createDataObject("http://tuscany.apache.org/sca/samples/aggregator/sources",
+                                                                   "addAlertSource");
+        $source = $request->createDataObject("parm");
+
+        $source->Name    = $alert_source->Name;
+        $source->Address = $alert_source->Address;
+        $source->Id      = $alert_source->Id;
+        $source->Type    = $alert_source->Type;        
+
+        $this->alert_sources_service->addAlertSource($request);
     }
 
     /**
-      * @param Source $alert_source http://tuscany.apache.org/sca/samples/aggregator/types
+      * @param SourceType $alert_source http://tuscany.apache.org/sca/samples/aggregator/types
       */ 
-    public function updateAlertSource($alert_source){
-        # Use the alertService reference    
-        $this->alertService->updateAlertSource($alert_source);
+    public function updateAlertSource($alert_source){ 
+        $this->alert_sources_service->updateAlertSource($alert_source);
     }
 }
+
+/* Some debugging lines
+ob_start();
+print_r( $new_alerts );
+$debug = ob_get_contents();
+ob_end_clean();
+SCA::$logger->log($debug);
+*/
 ?>
 
 

Propchange: incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplay.php
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplayJson.php
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplayJson.php?view=auto&rev=543504
==============================================================================
--- incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplayJson.php (added)
+++ incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplayJson.php Fri Jun  1 08:26:34 2007
@@ -0,0 +1,56 @@
+<?php
+/*
++----------------------------------------------------------------------+
+| Copyright IBM Corporation 2007.                                      |
+| All Rights Reserved.                                                 |
++----------------------------------------------------------------------+
+|                                                                      |
+| Licensed under the Apache License, Version 2.0 (the "License"); you  |
+| may not use this file except in compliance with the License. You may |
+| obtain a copy of the License at                                      |
+| http://www.apache.org/licenses/LICENSE-2.0                           |
+|                                                                      |
+| Unless required by applicable law or agreed to in writing, software  |
+| distributed under the License is distributed on an "AS IS" BASIS,    |
+| WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or      |
+| implied. See the License for the specific language governing         |
+| permissions and limitations under the License.                       |
++----------------------------------------------------------------------+
+| Author: SL                                                           |
++----------------------------------------------------------------------+
+$Id: ContactEmailService.php,v 1.1.2.1 2007/04/27 11:17:45 slaws Exp $
+*/
+
+include 'SCA/SCA.php';
+
+/**
+ * Service for sending emails
+ * 
+ * @service
+ * @binding.restrpc
+ */
+class AlertDisplayJson {
+
+    /**
+     * @reference
+     * @binding.jsonrpc C:\simon\Projects\Tuscany\service.smd
+     */
+    public $alert_service;
+
+
+
+    /**
+     * Send a simple text email with the options of using short names for addresses.
+     *
+     * @return string
+     */
+    public function getAlerts() {
+
+        $alerts = $this->alert_service->getAllNewAlerts("SomeString");
+
+        return $alerts;
+
+    }
+}
+
+?>

Propchange: incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertDisplayJson.php
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/Alerts.xsd
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/Alerts.xsd?view=diff&rev=543504&r1=543503&r2=543504
==============================================================================
--- incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/Alerts.xsd (original)
+++ incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/Alerts.xsd Fri Jun  1 08:26:34 2007
@@ -40,9 +40,6 @@
     	</sequence>        
     </complexType>
        
-    <element name="Config" type="ns:ConfigType"/>
-    <element name="Source" type="ns:SourceType"/>
-
     <complexType name="SourceType">
     	<sequence>
     		<element name="Name" type="string" maxOccurs="1" minOccurs="1"/>
@@ -71,4 +68,13 @@
     		<element name="Source" type="ns:SourceType" maxOccurs="unbounded" minOccurs="0"/>
     	</sequence>
     </complexType>
+    
+    <complexType name="SingleSourceType">
+    	<sequence>
+    		<element name="Source" type="ns:SourceType"/>
+    	</sequence>
+    </complexType>    
+    
+    <element name="Config" type="ns:ConfigType"/>
+    <element name="Source" type="ns:SourceType"/>
 </schema>

Modified: incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertsSources.wsdl
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertsSources.wsdl?view=diff&rev=543504&r1=543503&r2=543504
==============================================================================
--- incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertsSources.wsdl (original)
+++ incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/AlertsSources.wsdl Fri Jun  1 08:26:34 2007
@@ -48,6 +48,22 @@
                     </sequence>
                 </complexType>
             </element>
+            
+            <element name="addAlertSource">
+                <xsd:complexType>
+                    <sequence>
+                        <element name="parm" type="alerter:SourceType"/>                    
+                    </sequence>                
+                </xsd:complexType>
+            </element> 
+            
+            <element name="addAlertSourceResponse">
+                <complexType>
+                    <sequence>
+                        <element name="parm" type="string" />
+                    </sequence>
+                </complexType>
+            </element>                       
 
         </xsd:schema>
     </wsdl:types>
@@ -58,12 +74,23 @@
     <wsdl:message name="GetAlertSourcesResponse">
         <wsdl:part element="tns:getAlertSourcesResponse" name="parameters" />
     </wsdl:message>
+    
+    <wsdl:message name="AddAlertSourceRequest">
+        <wsdl:part element="tns:addAlertSource" name="parameters" />
+    </wsdl:message>
+    <wsdl:message name="AddAlertSourceResponse">
+        <wsdl:part element="tns:addAlertSourceResponse" name="parameters" />
+    </wsdl:message>    
 
     <wsdl:portType name="AlertsSourcesPortType">
         <wsdl:operation name="getAlertSources">
             <wsdl:input message="tns:GetAlertSourcesRequest" name="GetAlertSourcesRequestMsg" />
             <wsdl:output message="tns:GetAlertSourcesResponse" name="GetAlertSourcesResponseMsg" />
         </wsdl:operation>
+        <wsdl:operation name="addAlertSource">
+            <wsdl:input message="tns:AddAlertSourceRequest" name="AddAlertSourceRequestMsg" />
+            <wsdl:output message="tns:AddAlertSourceResponse" name="AddAlertSourceResponseMsg" />
+        </wsdl:operation>        
    </wsdl:portType>
 
     <wsdl:binding name="AlertsSourcesBinding" type="tns:AlertsSourcesPortType">
@@ -76,7 +103,16 @@
             <wsdl:output name="GetAlertSourcesResponseMsg">
                 <wsdlsoap:body use="literal" />
             </wsdl:output>
-        </wsdl:operation>           
+        </wsdl:operation>  
+        <wsdl:operation name="addAlertSource">
+            <wsdlsoap:operation soapAction="" />
+            <wsdl:input name="AddAlertSourceRequestMsg">
+                <wsdlsoap:body use="literal" />
+            </wsdl:input>
+            <wsdl:output name="AddAlertSourceResponseMsg">
+                <wsdlsoap:body use="literal" />
+            </wsdl:output>
+        </wsdl:operation>                  
     </wsdl:binding>
 
     <wsdl:service name="AlertsSourcesService">

Modified: incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/Cached_Alerts.xml
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/Cached_Alerts.xml?view=diff&rev=543504&r1=543503&r2=543504
==============================================================================
--- incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/Cached_Alerts.xml (original)
+++ incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/Cached_Alerts.xml Fri Jun  1 08:26:34 2007
@@ -1,3 +1,2 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<Alerts xmlns="http://tuscany.apache.org/sca/samples/aggregator/types" xmlns:tns="http://tuscany.apache.org/sca/samples/aggregator/types" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><Alert SourceId="1" Unread="false" Id="alert_0"><Title>Polymer Vision's Readius rollable display gets face time</Title><Summary>Filed under: Cellphones, DisplaysTalk about a long time coming, as what is now Polymer Vision has seemed to finally put all the pieces together and produce an actual working product from the idea envisioned by Philips around two years ago. We knew the spinoff was looking to commercialize the product later this year, but after nearly 24 months of coming up empty, a bit of understandable skepticism begins to seep through. Nevertheless, the firm's rollable, pocket-friendly "Cellular-Book" was out and showing its stuff at 3GSM, proving that there's at least something there to put on store shelves. Although the unit on display was indeed a standalone device -- sport
 ing 16 shades of grey, USB, "10-days" of battery life, 4GB of internal storage, and GPRS, EDGE, and DVB-H connectivity just like we'd heard -- Polymer Vision is actually hoping to integrate its e-paper technology into mobile handset displays in the near future. Sadly, there still didn't seem to be any hints of a release date for the nifty pocket reader, but be sure to click on through for the very long awaited pictures of the Readius in action.[Via Slashdot]Continue reading Polymer Vision's Readius rollable display gets face time Read | Permalink | Email this | CommentsBOLD MOVES: THE FUTURE OF FORD A new documentary series. Be part of the transformation as it happens in real-timeOffice Depot Featured Gadget: Xbox 360 Platinum System Packs the power to bring games to life!
-       </Summary><Address>http://feeds.engadget.com/~r/weblogsinc/engadget/~3/92945682/</Address><Date>2007-02-19T15:54:00</Date></Alert><Alert SourceId="" Unread="true" Id="alert_1"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_2"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_3"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_4"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_5"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_6"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:
 nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_7"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_8"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_9"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_10"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_11"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_12"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_13"><Ti
 tle xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_14"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_15"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_16"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_17"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_18"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_19"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true
 "/></Alert><Alert SourceId="" Unread="true" Id="alert_20"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_21"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_22"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_23"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_24"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_25"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_26"><Title xsi:nil="true"/><Summary
  xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_27"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_28"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_29"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_30"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_31"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_32"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="
 " Unread="true" Id="alert_33"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_34"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_35"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_36"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_37"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_38"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_39"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xs
 i:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_40"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_41"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_42"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_43"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_44"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_45"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_46
 "><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert><Alert SourceId="" Unread="true" Id="alert_47"><Title xsi:nil="true"/><Summary xsi:nil="true"/><Address xsi:nil="true"/><Date xsi:nil="true"/></Alert></Alerts>
+<Alerts xmlns="http://tuscany.apache.org/sca/samples/aggregator/types" xmlns:tns="http://tuscany.apache.org/sca/samples/aggregator/types" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"></Alerts>

Modified: incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/index.html
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/index.html?view=diff&rev=543504&r1=543503&r2=543504
==============================================================================
--- incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/index.html (original)
+++ incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/index.html Fri Jun  1 08:26:34 2007
@@ -19,7 +19,7 @@
 
 <HTML>
 <HEAD>
-    <TITLE>Apache Tuscany Alert Aggregator Sample</TITLE>
+    <TITLE>Apache Tuscany Feed Aggregator Sample</TITLE>
     <link REL="stylesheet" TYPE="text/css" href="style.css">
 </HEAD>
 
@@ -84,7 +84,7 @@
   }
 
   // Call this function again after x minutes
-  setTimeout("getAlerts();", 5*60000);
+  //setTimeout("getAlerts();", 5*60000);
 }
 
 function displayAlert(url, alertid)
@@ -176,7 +176,7 @@
         }
         if(xmlHttp.readyState==4)
         {            
-            getSources();
+        //    getSources();
         }
     }
     xmlHttp.open("POST",url,true);
@@ -243,25 +243,25 @@
     var name = document.getElementById("source_"+sourceid+"_name").value;
     var address = document.getElementById("source_"+sourceid+"_address").value;
 
-    var sourceXML = "<source xmlns=\"http://tuscany.apache.org/samples/alerter\" type=\""+type+"\" id=\""+sourceid+"\">";
-    sourceXML += "<name>"+name+"</name>";
-    sourceXML += "<address>"+address+"</address>";
+    var sourceXML = "<Source xmlns=\"http://tuscany.apache.org/sca/samples/aggregator/types\" Type=\""+type+"\" Id=\""+sourceid+"\">";
+    sourceXML += "<Name>"+name+"</Name>";
+    sourceXML += "<Address>"+address+"</Address>";
 
     if(type=="rss")
     {
         var feedAddress = document.getElementById("source_"+sourceid+"_feedAddress").value;
-        sourceXML += "<feedAddress>"+feedAddress+"</feedAddress>";
+        sourceXML += "<FeedAddress>"+feedAddress+"</FeedAddress>";
     }
     else if(type=="pop")
     {
         var popServer = document.getElementById("source_"+sourceid+"_popServer").value;
-        sourceXML += "<popServer>"+popServer+"</popServer>";
+        sourceXML += "<PopServer>"+popServer+"</PopServer>";
         var popUsername = document.getElementById("source_"+sourceid+"_popUsername").value;
-        sourceXML += "<popUsername>"+popUsername+"</popUsername>";
+        sourceXML += "<PopUsername>"+popUsername+"</PopUsername>";
         var popPassword = document.getElementById("source_"+sourceid+"_popPassword").value;
-        sourceXML += "<popPassword>"+popPassword+"</popPassword>";
+        sourceXML += "<PopPassword>"+popPassword+"</PopPassword>";
     }
-    sourceXML += "</source>";
+    sourceXML += "</Source>";
 
     return sourceXML;
 }

Added: incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/service.smd
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/service.smd?view=auto&rev=543504
==============================================================================
--- incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/service.smd (added)
+++ incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/service.smd Fri Jun  1 08:26:34 2007
@@ -0,0 +1 @@
+{"SMDVersion":".1","objectName":"AlertsService","serviceType":"JSON-RPC","serviceURL":"http://localhost:8080/sample-feed-aggregator/services/AlertsServiceJSONRPC","methods":[{"name":"getAllNewAlerts","parameters":[{"name":"param0","type":"STRING"}]}]}

Propchange: incubator/tuscany/sandbox/slaws/httpserver.php/htdocs/service.smd
------------------------------------------------------------------------------
    svn:eol-style = native



---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org