<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress.com" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>

<channel>
	<title>webservice &amp;laquo; WordPress.com Tag Feed</title>
	<link>http://en.wordpress.com/tag/webservice/</link>
	<description>Feed of posts on WordPress.com tagged "webservice"</description>
	<pubDate>Wed, 25 Nov 2009 12:43:36 +0000</pubDate>

	<generator>http://en.wordpress.com/tags/</generator>
	<language>en</language>

<item>
<title><![CDATA[Petals ESB v3.0 is out]]></title>
<link>http://chamerling.wordpress.com/2009/11/25/petals-esb-v3-0-is-out/</link>
<pubDate>Wed, 25 Nov 2009 10:18:51 +0000</pubDate>
<dc:creator>Kitov</dc:creator>
<guid>http://chamerling.wordpress.com/2009/11/25/petals-esb-v3-0-is-out/</guid>
<description><![CDATA[Petals ESB v3.0 is finally out (two years after the v2.0 release), there are many changes in this ve]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p><a href="http://petals.ow2.org">Petals ESB v3.0</a> is finally out (two years after the v2.0 release), there are many changes in this version but here are the main ones :</p>
<blockquote><p>Petals ESB 3.0, includes a lot of improvements for users, as well as optimisations, and nice new features :<br />
- Dynamic configuration, and hot-deployment of new nodes<br />
- Redesigned webconsole for administration, and deleted statistics monitoring (based on OW2-OpenSUIT)<br />
- SCA support: SCA engine (OW2-FraSCAti), and SCA designer (Eclipse)<br />
- BPEL support: BPEL engine, and BPEL designer (Eclipse), with validation (based on a new BPEL engine!)<br />
- WS Notification and WS-BorkeredNotification support (EDA)<br />
- more and more things&#8230;</p>
<p>Integration with new Petals Camelia softwares :<br />
- Petals Studio: Complete Eclipse development environment, for Petals ESB<br />
- Petals Master: SOA Governance (OW2-Dragon)<br />
- Petals View: Business flow monitoring based on Petals EDA feature (based on OW2-OpenSUIT)</p>
<p>We gave this release a name : Camelia.</p></blockquote>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Wohin verschwinden gelöschte Dateien?]]></title>
<link>http://itsicherheit.wordpress.com/2009/11/20/wohin-verschwinden-geloschte-dateien/</link>
<pubDate>Fri, 20 Nov 2009 17:57:38 +0000</pubDate>
<dc:creator>Guido Strunck</dc:creator>
<guid>http://itsicherheit.wordpress.com/2009/11/20/wohin-verschwinden-geloschte-dateien/</guid>
<description><![CDATA[Viele PC-Nutzer glauben, dass Dateien, die sie löschen dadurch tatsächlich vernichtet werden. Dem is]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Viele PC-Nutzer glauben, dass Dateien, die sie löschen dadurch tatsächlich vernichtet werden. Dem ist nicht so. Zum einen haben die meisten Betriebssysteme eine Sicherung gegen unabsichtliches Löschen eingebaut: Das Papierkorb-Verzeichnis, in das gelöschte  Dateien hinein verschoben werden. Und aus dem man sie – wie bei einem echten Mülleimer – wieder herausziehen kann. Aber auch das „Leeren“ des Papierkorbes führt nicht zur tatsächlichen Löschung der Dateien. Der Rechner markiert die durch die Dateien belegten Speicherbereiche seiner Festplatte lediglich als „frei verfügbar“. Früher oder später werden darauf neue Daten gespeichert, so dass dadurch die zuvor dort gespeicherten Daten überschrieben werden. Erst dann sind sie tatsächlich weg. Je nach Nutzungsintensität der Festplatte und der dort noch vorhandenen Speicherkapazität kann das Sekunden oder Monate bis Jahre dauern.</p>
<p>Wer wissen will, was sich auf seinem Rechner noch an bereits gelöschten aber wiederherstellbaren Daten befindet, kann mit Tools wie Piriform‘s kostenlosem <a href="http://www.piriform.com/recuva">Recuva</a> nachschauen. Und die Datenreste auf Wunsch auch gleich endgültig beseitigen oder aber wiederherstellen lassen.</p>
<p>Zumindest für Dateien gibt es durchaus ein „Leben nach dem Tod“. Es sei denn, sie werden gleich „<a href="http://www.heise.de/security/meldung/Sicheres-Loeschen-Einmal-ueberschreiben-genuegt-198816.html">sicher gelöscht</a>“, d.h. der von ihnen belegte Plattenplatz wird erst mit anderen Daten überschrieben und anschließend als „frei“ gekennzeichnet. Auch dafür gibt es Tools, wie z.B. das Programm <a href="http://www.piriform.com/ccleaner/">Crap Cleaner</a>. Es ist eine Art &#8220;Datenmüllabfuhr&#8221;, die den Rechner auf dem es installiert ist, von datentechnischen Gebrauchsspuren säubert und in der man auch sichere Löschverfahren einstellen kann.</p>
<p>Heute haben viele Nutzer aber Daten nicht nur auf ihrem eigenen Rechner sondern auch „in der Cloud“, d.h. bei Internetdiensten wie Facebook, XING oder Twitter. Und hier werden die Dinge jetzt kompliziert. <a href="http://itsicherheit.wordpress.com/2009/04/01/das-internet-vergisst-nichts/">Denn das Internet vergisst grundsätzlich erst mal nichts.</a> Fast alles wird irgendwo gespiegelt, zwischengespeichert oder in Archiven und Backup-Systemen vorgehalten. Je länger es im Netz steht, desto wahrscheinlicher ist das. So werden z.B. meine Artikel in diesem Blog oftmals bereits nach wenigen Stunden von Suchmaschinen erfasst, wodurch sie meist auch in deren Cache landen.</p>
<p>In den meisten sozialen Netzwerken kann man eigene Daten zwar löschen. Aber es ist dadurch nicht sichergestellt, dass sie tatsächlich weg sind. Hochverfügbar laufende IT-Systeme haben meist mehrere Backups und identisch konfigurierte und mit aktuellen Datenbeständen versehene Ersatzsysteme, um bei Sabotage oder Plattencrash zügig darauf umschalten und weiterlaufen zu können. Und oft genug enthält das <a href="http://www.sueddeutsche.de/computer/11/458660/text/">Kleingedruckte in den Nutzungsverträgen mit den Plattformbetreibern</a> Klauseln, wonach man ihnen Verwertungsrechte an den persönlichen Daten einräumt. Was sie dazu veranlassen kann, diese dafür vor endgültiger Löschung zu sichern.</p>
<p>So warf kürzlich der Security-Newsletter von TrendMicro die durchaus berechtigte Frage auf:  <a href="http://cdn.rsys1.net/ig.rsys1.net/responsysimages/tne/__RS_CP__/trendsetter_nov09_deleted.html">„When You Delete Your Social Media and Smartphone Files — Are They Really Deleted?“</a> Um im Weiteren auf die grundsätzliche Problematik der Kontrolle und Verfügung über Daten auf ausgelagerten IT-Systemen zu verweisen. Ein Thema, dass nicht nur Rechenzentren in Konzernen sondern zunehmend auch Privatnutzer mit ihren Mobilgeräten und Web 2.0-Accounts betrifft. So sieht z.B. der <a href="http://www.spiegel.de/netzwelt/gadgets/0,1518,662354,00.html">Prototyp von Googles Netbook-Betriebssystem Chrome OS </a>ein fast ausschließlich webbasiertes Arbeiten mit dem Rechner vor, so das praktische alles – Programme, Daten, Dienste – aus dem Internet bezogen wird.</p>
<blockquote><p>As more consumer data moves onto cloud computing platforms like Gmail and Facebook, and closed platforms like Kindle and iPhone, deleting your data—whether old email messages, college photos on Flickr or personal posts on Facebook—becomes more complicated. In fact, you have to trust that these companies will delete your data when you ask them to. Unfortunately, many of these sites are more likely to make your data inaccessible than actually delete it. And even if you do manage to delete your files, copies are almost certain to remain in the companies&#8217; backup systems.</p></blockquote>
<p>Als Lösung dafür wird auf die Idee von Dateien mit zeitlich begrenzter Lebensdauer und anschließender Selbstzerstörung hingewiesen. Eine Idee, die im Zuge des <a href="http://vanish.cs.washington.edu/">Vanish-Projektes</a> an der University of Washington entstand und bereits als quelloffene Referenzimplementierung vorliegt. <a href="http://itsicherheit.wordpress.com/2009/07/27/wenn-das-internet-vergesslich-wird/">Allerdings haben auch Konzepte wie „Vanish“ ihre Nachteile</a>, so dass eine endgültige Lösung für das Problem noch aussteht.</p>
<p>Während man das Dasein von gelöschten Dateien auf dem meisten Rechner also durchaus selbst endgültig beenden kann, erlangen ins Internet verlagerte Daten gewissermaßen eine Art „ewiges Leben“.</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[How to insert data into Database using Silverlight]]></title>
<link>http://lokeshbasana.wordpress.com/2009/11/10/how-to-insert-data-into-database-using-silverlight/</link>
<pubDate>Tue, 10 Nov 2009 09:23:27 +0000</pubDate>
<dc:creator>lokeshbasana</dc:creator>
<guid>http://lokeshbasana.wordpress.com/2009/11/10/how-to-insert-data-into-database-using-silverlight/</guid>
<description><![CDATA[First Create Silverlight application Start -&gt; Programs -&gt; VS2008 -&gt; File -&gt; New -&gt; Pr]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><h2>First Create Silverlight application</h2>
<p>Start -&#62; Programs -&#62; VS2008 -&#62; File -&#62; New -&#62; Project -&#62; SilverlightApplication -&#62; ByDefault application name is SilverlightApplication1 change name as <strong>SilverlightDB</strong></p>
<p>&#160;</p>
<p><span style="color:#ff6600;"><strong>Original article from</strong></span></p>
<p><a title="insert data into database using silverlight" href="http://www.codeforasp.net/how-to-insert-data-into-database-using-silverlight.html" target="_blank">http://www.codeforasp.net/how-to-insert-data-into-database-using-silverlight.html</a></p>
<p><strong> </strong></p>
<div>
<dl>
<dt><strong><strong><img title="Silverlight-solution-explorer" src="http://www.codeforasp.net/wp-content/uploads/2009/10/Silverlight-solution-explorer.JPG" alt="Silverlight-solution-explorer" width="206" height="449" /></strong></strong></dt>
<dd>Silverlight-solution-explorer</dd>
</dl>
</div>
<p><strong> </strong></p>
<h2>Step2: Design Registration form in Page.xaml</h2>
<p>Silverlight Grid with <strong>8 Rows</strong> and <strong>2 Columns</strong> using grid RowDefinition and ColumnDefinition</p>
<p>&#60;UserControl xmlns:controls=&#8221;clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Toolkit&#8221;  x:Class=&#8221;SilverlightDB.Page&#8221;</p>
<p>xmlns=&#8221;http://schemas.microsoft.com/winfx/2006/xaml/presentation&#8221;</p>
<p>xmlns:x=&#8221;http://schemas.microsoft.com/winfx/2006/xaml&#8221;</p>
<p><strong>Width</strong><strong>=&#8221;400&#8243; Height=&#8221;300&#8243;</strong>&#62;</p>
<p><strong> </strong><strong>&#60;</strong><strong>Border</strong><strong> BorderBrush</strong><strong>=&#8221;Black&#8221;</strong><strong> BorderThickness</strong><strong>=&#8221;1&#8243; &#62;</strong></p>
<p>&#60;Grid x:Name=&#8221;LayoutRoot&#8221; Background=&#8221;White&#8221; ShowGridLines=&#8221;False&#8221; &#62;</p>
<p>&#60;Grid.RowDefinitions&#62;</p>
<p>&#60;RowDefinition Height=&#8221;35&#8243;&#62;&#60;/RowDefinition&#62;</p>
<p>&#60;RowDefinition Height=&#8221;30&#8243;&#62;&#60;/RowDefinition&#62;</p>
<p>&#60;RowDefinition Height=&#8221;30&#8243;&#62;&#60;/RowDefinition&#62;</p>
<p>&#60;RowDefinition Height=&#8221;30&#8243;&#62;&#60;/RowDefinition&#62;</p>
<p>&#60;RowDefinition Height=&#8221;30&#8243;&#62;&#60;/RowDefinition&#62;</p>
<p>&#60;RowDefinition Height=&#8221;30&#8243;&#62;&#60;/RowDefinition&#62;</p>
<p>&#60;RowDefinition Height=&#8221;40&#8243;&#62;&#60;/RowDefinition&#62;</p>
<p>&#60;RowDefinition Height=&#8221;70&#8243;&#62;&#60;/RowDefinition&#62;</p>
<p>&#60;/Grid.RowDefinitions&#62;</p>
<p>&#60;Grid.ColumnDefinitions&#62;</p>
<p>&#60;ColumnDefinition Width=&#8221;130&#8243;&#62;&#60;/ColumnDefinition&#62;</p>
<p>&#60;ColumnDefinition Width=&#8221;270&#8243;&#62;&#60;/ColumnDefinition&#62;</p>
<p>&#60;/Grid.ColumnDefinitions&#62;</p>
<p>&#60;StackPanel <strong>Grid.Row=&#8221;0&#8243; Grid.Column=&#8221;0&#8243;</strong> <strong>Grid.ColumnSpan=&#8221;2&#8243;</strong> Width=&#8221;400&#8243; Background=&#8221;Gray&#8221; &#62;</p>
<p>&#60;controls:Label  FontSize=&#8221;14&#8243; FontWeight=&#8221;bold&#8221; HorizontalAlignment=&#8221;Center&#8221;</p>
<p><strong>Content</strong><strong>=&#8221;Registration Form&#8221;</strong> Margin=&#8221;6,5,-5,5&#8243;&#62;&#60;/controls:Label&#62;</p>
<p>&#60;/StackPanel&#62;</p>
<p>&#60;controls:Label <strong>Grid.Row=&#8221;1&#8243; Grid.Column=&#8221;0&#8243;</strong> <strong>Content</strong><strong>=&#8221;FirstName&#8221;</strong> Margin=&#8221;10,5,5,5&#8243; HorizontalAlignment=&#8221;Center&#8221;&#62;&#60;/controls:Label&#62;</p>
<p>&#60;TextBox <strong>Grid.Column=&#8221;1&#8243; Grid.Row=&#8221;1&#8243;</strong> Height=&#8221;25&#8243; Width=&#8221;150&#8243; HorizontalAlignment=&#8221;Left&#8221;&#62;&#60;/TextBox&#62;</p>
<p>&#60;controls:Label <strong>Grid.Row=&#8221;2&#8243; Grid.Column=&#8221;0&#8243;</strong> <strong>Content</strong><strong>=&#8221;EmailID&#8221;</strong> Margin=&#8221;10,5,5,5&#8243; HorizontalAlignment=&#8221;Center&#8221;&#62;&#60;/controls:Label&#62;</p>
<p>&#60;TextBox <strong>Grid.Row=&#8221;2&#8243; Grid.Column=&#8221;1&#8243;</strong> Height=&#8221;25&#8243; Width=&#8221;150&#8243; HorizontalAlignment=&#8221;Left&#8221;&#62;&#60;/TextBox&#62;</p>
<p>&#60;controls:Label <strong>Grid.Row=&#8221;3&#8243; Grid.Column=&#8221;0&#8243;</strong> <strong>Content</strong><strong>=&#8221;PhoneNo&#8221;</strong> Margin=&#8221;10,5,5,5&#8243; HorizontalAlignment=&#8221;Center&#8221;&#62;&#60;/controls:Label&#62;</p>
<p>&#60;TextBox <strong>Grid.Row=&#8221;3&#8243; Grid.Column=&#8221;1&#8243;</strong> Height=&#8221;25&#8243; Width=&#8221;150&#8243; HorizontalAlignment=&#8221;Left&#8221;&#62;&#60;/TextBox&#62;</p>
<p>&#60;controls:Label <strong>Grid.Row=&#8221;4&#8243; Grid.Column=&#8221;0&#8243;</strong> <strong>Content</strong><strong>=&#8221;LoginName&#8221;</strong> Margin=&#8221;10,5,5,5&#8243; HorizontalAlignment=&#8221;Center&#8221;&#62;&#60;/controls:Label&#62;</p>
<p>&#60;TextBox <strong>Grid.Row=&#8221;4&#8243; Grid.Column=&#8221;1&#8243; </strong>Height=&#8221;25&#8243; Width=&#8221;150&#8243; HorizontalAlignment=&#8221;Left&#8221;&#62;&#60;/TextBox&#62;</p>
<p>&#60;controls:Label <strong>Grid.Row=&#8221;5&#8243; Grid.Column=&#8221;0&#8243;</strong> <strong>Content</strong><strong>=&#8221;Password&#8221;</strong> Margin=&#8221;10,5,5,5&#8243; HorizontalAlignment=&#8221;Center&#8221;&#62;&#60;/controls:Label&#62;</p>
<p>&#60;TextBox <strong>Grid.Row=&#8221;5&#8243; Grid.Column=&#8221;1&#8243; </strong>Height=&#8221;25&#8243; Width=&#8221;150&#8243; HorizontalAlignment=&#8221;Left&#8221;&#62;&#60;/TextBox&#62;</p>
<p>&#60;Button <strong>Grid.Row=&#8221;6&#8243; Grid.Column=&#8221;1&#8243; </strong>Width=&#8221;100&#8243; Height=&#8221;25&#8243; HorizontalAlignment=&#8221;Left&#8221; <strong>Content</strong><strong>=&#8221;Register&#8221;</strong>&#62;&#60;/Button&#62;</p>
<p>&#60;/Grid&#62;</p>
<p><strong> </strong><strong>&#60;/</strong><strong>Border</strong><strong>&#62;</strong></p>
<p>&#60;/UserControl&#62;</p>
<p>Run the application</p>
<div>
<dl>
<dt><img title="Silverlight-Registration-form" src="http://www.codeforasp.net/wp-content/uploads/2009/10/Silverlight-Registration.JPG" alt="Silverlight-Registration-form" width="402" height="299" /></dt>
<dd>Silverlight-Registration-form</dd>
</dl>
</div>
<p>CREATE TABLE [dbo].[<strong>Registration</strong>](</p>
<p>[<strong>registerID</strong>] [int] IDENTITY(1,1) NOT NULL,</p>
<p>[<strong>FirstName</strong>] [varchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,</p>
<p>[<strong>EmailID</strong>] [varchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,</p>
<p>[<strong>PhoneNo</strong>] [varchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,</p>
<p>[<strong>LoginName</strong>] [varchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,</p>
<p>[Password] [varchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,</p>
<p>CONSTRAINT [PK_Registration] PRIMARY KEY CLUSTERED</p>
<p>(</p>
<p>[<strong>registerID</strong>] ASC</p>
<p>)WITH (IGNORE_DUP_KEY = OFF) ON [PRIMARY]</p>
<p>) ON [PRIMARY]</p>
<h2><strong>Create Linq to SQL Classes </strong></h2>
<p>Right click in <strong>SilverlightDB.Web</strong> (see above figure)</p>
<p>-&#62; Add -&#62; New Item -&#62; Linq to SQL classes -&#62;</p>
<p>By Default Linq to SQL Classes (<strong>DataClasses1.dbml</strong>) change its name into <strong>Silverlight.dbml </strong></p>
<p><strong> -&#62;</strong><strong> </strong>Add -&#62; Then it opens <strong>dbml Editor </strong>click ServerExplorer -&#62;</p>
<p>Then it display <strong>Silverlight</strong> (database name in list of Databases)</p>
<p>Choose Silverlight</p>
<p>-&#62; Right click choose Modify Connections (Modify ConnectionString by choosing <strong>ServerName </strong>: <strong>your server name</strong></p>
<p>UserName : <strong>your username</strong></p>
<p>Password : <strong>your password</strong></p>
<p>Select Database: <strong>Silverlight</strong></p>
<p>Then Expand Silvelright database to view tables in Server Explorer (View -&#62;ServerExplorer)</p>
<div>
<dl>
<dt><img title="silverlight-ServerExplorer" src="http://www.codeforasp.net/wp-content/uploads/2009/10/silverlight-ServerExplorer.JPG" alt="silverlight-ServerExplorer" width="198" height="181" /></dt>
<dd>silverlight-ServerExplorer</dd>
</dl>
</div>
<p>Drag Registration table into <strong>Silverlight.dbml</strong> Editor then see Solution Explorer it creates <strong>Silverlight.dbml</strong> with two files</p>
<p><strong>Silverlight.dbml.layou</strong>t file</p>
<p><strong>Silverlight.designer.cs</strong> file</p>
<div>
<dl>
<dt><img title="Silverlight-dbml" src="http://www.codeforasp.net/wp-content/uploads/2009/10/Silverlight-dbml.JPG" alt="Silverlight-dbml" width="202" height="181" /></dt>
<dd>Silverlight-dbml</dd>
</dl>
</div>
<h2><strong>Create WCF Service in Silverlight Project</strong></h2>
<p><strong> </strong></p>
<p>Right click in <strong>SilverlightDB.Web</strong> (see above figure)</p>
<p>-&#62; Add -&#62; New Item -&#62; choose Silverlight from Categories -&#62; right side choose</p>
<p><strong>Service-enabled WCF Service</strong></p>
<p><strong> </strong></p>
<div>
<dl>
<dt><strong><a href="http://www.codeforasp.net/wp-content/uploads/2009/10/silverlight-wcfService.JPG"><strong><img title="silverlight enabled WCF Service" src="http://www.codeforasp.net/wp-content/uploads/2009/10/silverlight-wcfService.JPG" alt="silverlight enabled WCF Service" width="597" height="412" /></strong></a></strong></dt>
<dd>silverlight enabled WCF Service</dd>
</dl>
</div>
<p><strong> </strong></p>
<p><strong>Change Name:</strong> Service1.svc into Register.svc then click <strong>Add</strong> Button it generates below code</p>
<p><strong>Register.svc.cs</strong></p>
<p><strong> </strong></p>
<p>using System.ServiceModel;</p>
<p>using System.ServiceModel.Activation;</p>
<p>using System.Collections.Generic;</p>
<p>using System.Text;</p>
<p>namespace <strong>SilverlightDB.Web</strong></p>
<p>{</p>
<p>[ServiceContract(Namespace = "")]</p>
<p>[AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Allowed)]</p>
<p>public class Register</p>
<p>{</p>
<p><strong>[OperationContract]</strong></p>
<p>public void <strong>DoWork</strong>()</p>
<p>{</p>
<p>// Add your operation implementation here</p>
<p>return;</p>
<p>}</p>
<p>// Add more operations here and mark them with [OperationContract]</p>
<p>}</p>
<p>}</p>
<h2>For inserting data using WCF and Silverlight</h2>
<p>namespace SilverlightDB.Web</p>
<p>{</p>
<p>[ServiceContract(Namespace = "")]</p>
<p>[AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Allowed)]</p>
<p>public class Register</p>
<p>{</p>
<p>[OperationContract]</p>
<p>public void <strong>DoWork</strong>()</p>
<p>{</p>
<p>// Add your operation implementation here</p>
<p>return;</p>
<p>}</p>
<p>// Add more operations here and mark them with [OperationContract]</p>
<p>[OperationContract]</p>
<p>public void <strong>InsertData</strong>(string firstname,string emailid,string phoneno,string loginuser,</p>
<p>string password)</p>
<p>{</p>
<p>//SilverlightDataContext is Dbml file Silverlight.dbml //(SilverlightDataContext)</p>
<p><strong>SilverlightDataContext </strong><strong>db = new SilverlightDataContext();</strong></p>
<p>//From Silverlight.dbml.cs file Registeration(sqlserver name table name row</p>
<p>//  [Table(Name="dbo.Registration")]</p>
<p>//public partial class Registration : INotifyPropertyChanging, INotifyPropertyChanged</p>
<p>//{</p>
<p>//    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);</p>
<p>//    private int _registerID;</p>
<p>//    private string _FirstName;</p>
<p>//    private string _EmailID;</p>
<p>//Registration from Silverlight.dbml table name</p>
<p><strong>Registration </strong><strong>row = new Registration()</strong></p>
<p>{</p>
<p>FirstName = firstname,</p>
<p>EmailID = emailid,</p>
<p>PhoneNo = phoneno,</p>
<p>LoginName = loginuser,</p>
<p>Password = password</p>
<p>};</p>
<p>// Add the new object to the collection.</p>
<p>db.Registrations.InsertOnSubmit(row);</p>
<p>// Submit the change to the database.</p>
<p>db.SubmitChanges();</p>
<p>}</p>
<p>}</p>
<p>}</p>
<h2><strong>Add Web Service Reference to Silverlight Application (Pages like Page.xaml…)</strong></h2>
<p>Goto SilverlightDB in Solution Explorer -&#62; choose Referenes -&#62; click Add Service Reference</p>
<div>
<dl>
<dt><img title="Add-Service-Reference" src="http://www.codeforasp.net/wp-content/uploads/2009/10/Add-Service-Reference.JPG" alt="Add-Service-Reference" width="209" height="123" /></dt>
<dd>Add-Service-Reference</dd>
</dl>
</div>
<p>Then the below DailogBox Opens</p>
<div>
<dl>
<dt><img title="Service-Reference-Discover" src="http://www.codeforasp.net/wp-content/uploads/2009/10/Service-Reference-Discover.JPG" alt="Service-Reference-Discover" width="530" height="442" /></dt>
<dd>Service-Reference-Discover</dd>
</dl>
</div>
<p>Click <strong>Discover </strong>-&#62; It display all WCF services which Created in Project we created only one WCF service i.e. <strong>Register.svc </strong>it displays all operations included in <strong>Register.svc</strong></p>
<p>First it display Register.svc with expand and Collapse + symbol click (+) symbol . Now it displays Register webservice with expand and collapse click (+) symbol</p>
<p>Now it displays Register in Services and right side it displays Operations.</p>
<p><strong>Operations</strong></p>
<ul>
<li>DO Work</li>
<li>Insert Data</li>
</ul>
<div>
<dl>
<dt><img title="Register-WCF-Operations" src="http://www.codeforasp.net/wp-content/uploads/2009/10/Register-WCF-Operations.JPG" alt="Register-WCF-Operations" width="535" height="445" /></dt>
<dd>Register-WCF-Operations</dd>
</dl>
</div>
<p>Click Ok then it creates Service Reference all Silverlight Pages (page.xaml…)</p>
<p>It creates ServiceReference to Silverlight Application see below figure.</p>
<div>
<dl>
<dt><img title="ServiceReferences" src="http://www.codeforasp.net/wp-content/uploads/2009/10/ServiceReferences.JPG" alt="ServiceReferences" width="233" height="492" /></dt>
<dd>ServiceReferences</dd>
</dl>
</div>
<h2>Insert Data into SqlServer using Silverlight Xaml file</h2>
<p>Now goto <strong>Page.xaml</strong> (Registration form)</p>
<p>click in Submit Button right click</p>
<p>Click Navigate to Event Handler</p>
<p>&#60;Button Grid.Row=&#8221;6&#8243; Grid.Column=&#8221;1&#8243; Width=&#8221;100&#8243; Height=&#8221;25&#8243; HorizontalAlignment=&#8221;Left&#8221; Content=&#8221;Register&#8221; <strong>Click</strong><strong>=&#8221;SubmitRegister_Click&#8221;</strong> &#62;&#60;/Button&#62;</p>
<p>using SilverlightDB.ServiceReference1;</p>
<p>private void SubmitRegister_Click(object sender, RoutedEventArgs e)</p>
<p>{</p>
<p><strong>RegisterClient </strong><strong>webservice = new RegisterClient();</strong></p>
<p>webservice.<strong>InsertData</strong>Async(txtFirstName.Text, txtEmailID.Text, txtPhoneno.Text, txtLoginName.Text, txtPassword.Text);</p>
<p>}</p>
<p><strong>Explaination:</strong></p>
<p><strong>RegisterClient webservice=new RegisterClient()</strong></p>
<p><strong>Register </strong>is WCF service name</p>
<p><strong>Client </strong>is ByDefault is Client Service</p>
<p>So Register+Client = <strong>RegisterClient</strong></p>
<p><strong>InsertDataAsync</strong></p>
<p><strong> </strong></p>
<p>InsertData = WCF service (Register.svc) Operation (Function) is assigned to insert data into database.</p>
<p>Async = ServiceReference to InsertData</p>
<p>So InsertData+Async = InsertDataAsync</p>
<p><strong>Hit F5 to run the application</strong></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[iSeminar Ventus Proxy For Webservices: Monitorización y Alertas avanzadas de VPFW v5.3]]></title>
<link>http://jordifigueras.wordpress.com/2009/11/06/iseminar-ventus-proxy-for-webservices-monitorizacion-y-alertas-avanzadas-de-vpfw-v5-3/</link>
<pubDate>Fri, 06 Nov 2009 09:10:55 +0000</pubDate>
<dc:creator>jordifigueras</dc:creator>
<guid>http://jordifigueras.wordpress.com/2009/11/06/iseminar-ventus-proxy-for-webservices-monitorizacion-y-alertas-avanzadas-de-vpfw-v5-3/</guid>
<description><![CDATA[Evento | Noviembre 2009 ¿Cuánto de su negocio se basa en webservices? La adopción de esta tecnología]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><table border="0" cellspacing="0" cellpadding="10" width="100%">
<tbody>
<tr>
<td>
<table style="height:25px;" border="0" cellspacing="0" cellpadding="0" width="520" align="center">
<tbody>
<tr>
<td colspan="5" height="5"><img src="http://www.ventusproxy.com/ev0911/img/sup_izq1.gif" alt="" width="25" height="5" /></td>
<td height="5"><img src="http://www.ventusproxy.com/ev0911/img/sombra_sup.gif" alt="" width="470" height="5" /></td>
<td colspan="5" height="5"><img src="http://www.ventusproxy.com/ev0911/img/sup_der1.gif" alt="" width="25" height="5" /></td>
</tr>
<tr>
<td colspan="5" height="69"><img src="http://www.ventusproxy.com/ev0911/img/sup_izq2.gif" alt="" width="25" height="69" /></td>
<td width="470" height="69" bgcolor="#f3f4f8">
<table style="height:60px;" border="0" cellspacing="0" cellpadding="0" width="470">
<tbody>
<tr>
<td width="185" bgcolor="#f3f4f8"><img src="http://www.ventusproxy.com/ev0911/img/logo.gif" alt="" width="157" height="35" /></td>
<td width="285" align="right" valign="bottom" bgcolor="#f3f4f8"><strong>Evento &#124;</strong> <strong>Noviembre 2009</strong></td>
</tr>
</tbody>
</table>
</td>
<td colspan="6" height="69"><img src="http://www.ventusproxy.com/ev0911/img/sup_der2.gif" alt="" width="25" height="69" /></td>
</tr>
<tr>
<td rowspan="4" width="3"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="3" height="1" /></td>
<td rowspan="4" width="1" bgcolor="aec7d9"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="1" height="1" /></td>
<td rowspan="4" width="1" bgcolor="a0b8c8"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="1" height="1" /></td>
<td rowspan="4" width="1" bgcolor="c4cfd6"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="1" height="1" /></td>
<td rowspan="4" width="19" bgcolor="#FFFFFF"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="19" height="1" /></td>
<td width="470" bgcolor="#FFFFFF"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="1" height="20" /></td>
<td rowspan="4" width="20" bgcolor="#FFFFFF"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="20" height="1" /></td>
<td rowspan="4" width="1" bgcolor="#98aebe"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="1" height="1" /><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="1" height="1" /></td>
<td rowspan="4" width="1" bgcolor="#a7bfd0"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="1" height="1" /></td>
<td rowspan="4" width="1" bgcolor="#b2ccde"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="1" height="1" /></td>
<td rowspan="4" width="2"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="2" height="1" /></td>
</tr>
<tr>
<td width="470" bgcolor="#FFFFFF">
<table border="0" cellspacing="0" cellpadding="0" width="470">
<tbody>
<tr>
<td><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="1" height="5" /></td>
<td valign="top">
<div>
<p><strong>¿Cuánto de su negocio se basa en webservices?</strong></p>
<p>La adopción de esta tecnología por parte de las grandes compañías del Sector Turismo está siendo cada vez más rápida. Si su negocio se basa en la utilización de los Web Services y/o SOA:</p>
<ul>
<li>¿Conoce el estado, disponibilidad, nivel de carga, histórico y estadística de sus peticiones y transacciones de sus clientes o con sus proveedores?</li>
<li>Sabía qué implementar mecanismos de aceleración de Web Services (caché, compresión) puede minimizar el impacto en cuanto a necesidad de servidores y ancho de banda.</li>
</ul>
<p><strong>MONITORIZACIÓN Y ALERTAS AVANZADA de webservices con VPFW</strong></p>
<p>La monitorización testea el correcto funcionamiento de los webservices y las alertas nos avisan de los sucesos que consideremos importantes con nuestros clientes y/o proveedores para poder corregirlas a tiempo y sin coste para el negocio.</p>
<table border="0" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td height="35"><strong>¿Cómo le afecta a su negocio …</strong></td>
</tr>
<tr>
<td>
<ul>
<li>una mala configuración del webservice por parte de su cliente.</li>
<li>demasiadas peticiones de consulta sin confirmaciones de reserva.</li>
<li>las peticiones erróneas, desconocer la causa y su consecuente desconexión del interface.</li>
<li>no poder comparar servicios equivalentes (disponibilidad, confirmaciones) entre distintos interfaces.</li>
</ul>
</td>
</tr>
<tr>
<td align="right"><strong>&#8230; que sus webservices dejen de funcionar?</strong></td>
</tr>
</tbody>
</table>
<p>Nuestra última versión de VPFW le ayudará en mejorar su rendimiento y conocimiento de su negocio basado en webservices.</p>
<p>Las alertas se configuran a nivel de interface o bien a nivel de llamada de cada interface. Funciona de la siguiente manera:</p>
<ul>
<li>Se introducen los datos generales de la alerta.</li>
<li>Se determina el motivo por el cual se disparará la alerta.</li>
<li>Se indican los errores por los cuales consideraremos que una petición no es correcta.</li>
<li>Y, en caso de alerta, se envía un email y/o sms al administrador del interface y, opcionalmente, tenemos la posibilidad de desconectar el interface durante un determinado periodo de tiempo, tras el cual VPFW intentará volver a reconectar.</li>
</ul>
<p>A partir de este análisis se generan estadísticas detalladas de toda la monitorización de webservices, donde podemos visualizar datos como el número de alertas provocados, tiempo que se han desconectado los interfaces, documentos que han provocado los errores, etc. Estas estadísticas derivan en informes en formato html que pueden ser generados diaria, semanal o mensualmente.<br />
Conozca <strong>Ventus Proxy For WebServices</strong> (<a href="http://www.ventusproxy.com/ev0911/ds_vpfw5.pdf" target="wPdf">datasheet</a>), asistiendo al seminario online que impartiremos el día 20 de Noviembre. Verá en funcionamiento toda la potencia de Ventus Proxy for WebServices, en el que ya han confiado empresas tan importantes como Grupo Serhs, Marsans ó Logitravel.</p>
<p>Si desea inscribirse en este evento, pulse <a href="http://www.ventusproxy.com/ev0911/inscripcion.html" target="wInscr"><strong>aquí</strong></a>.</p>
<p>Asimismo, le informamos que nos pondremos en contacto con Usted, para solicitarle una reunión y poder presentarle de forma personalizada VPFW.</p>
</div>
</td>
</tr>
<tr>
<td colspan="2" height="25" align="center"><img src="http://www.ventusproxy.com/ev0911/img/px000000.gif" alt="" width="295" height="1" /></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td height="70" align="center" bgcolor="#FFFFFF"><img src="http://www.ventusproxy.com/ev0911/img/logo_peq.gif" alt="" width="108" height="21" /><br />
Viladomat 106, 6º 1ª • 08015 Barcelona<br />
Tel.: +34 902 43 05 75 • Fax: +34 93 292 01 49<br />
<a href="mailto:info@ventusproxy.com">info@ventusproxy.com</a> • <a href="http://www.ventusproxy.com/" target="_blank">www.ventusproxy.com</a></td>
</tr>
<tr>
<td height="84" valign="bottom" bgcolor="#FFFFFF"><img src="http://www.ventusproxy.com/ev0911/img/edificios.gif" alt="" width="470" height="84" /></td>
</tr>
<tr>
<td colspan="11" height="5"><a href="http://www.ventusproxy.com/" target="_blank"><img src="http://www.ventusproxy.com/ev0911/img/inf.gif" border="0" alt="" width="520" height="35" /></a></td>
</tr>
<tr>
<td colspan="11" height="5"><img src="http://www.ventusproxy.com/ev0911/img/px.gif" alt="" width="1" height="5" /></td>
</tr>
<tr>
<td colspan="11" height="5">
<div>Si no desea recibir más información acerca de nuestra empresa, por favor reenvíe<br />
este mensaje con la palabra &#8216;remove&#8217; en el asunto a: <a href="mailto:info@ventusproxy.com">info@ventusproxy.com</a></div>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[PEtALS ESB Live Monitoring with WSDM and GWT]]></title>
<link>http://chamerling.wordpress.com/2009/11/04/petals-esb-live-monitoring-with-wsdm-and-gwt/</link>
<pubDate>Wed, 04 Nov 2009 16:29:28 +0000</pubDate>
<dc:creator>Kitov</dc:creator>
<guid>http://chamerling.wordpress.com/2009/11/04/petals-esb-live-monitoring-with-wsdm-and-gwt/</guid>
<description><![CDATA[In one of my previous posts (Adding Registry Listener in PEtALS), I spoke about adding a registry li]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>In one of my previous posts (<a href="http://chamerling.wordpress.com/2009/11/02/adding-registry-listener-in-petals/" target="_blank">Adding Registry Listener in PEtALS</a>), I spoke about adding a registry listener in <a href="http://petals.ow2.org" target="_blank">PEtALS ESB</a>. In the current article, I want to introduce how I used this feature to implement a live monitoring Web application.</p>
<p>Here are the different modules which are used in this Live Monitoring Tool :</p>
<ol>
<li>PEtALS ESB. The standard behaviour has been customized by adding a registry listener and a routing module (to be detailled below).</li>
<li>Monitoring layer. This layer is an independant process which embeds a WS-Notification engine.</li>
<li>A WS-notification subscriber. This is the module which will receive the notifications from the monitoring layer.</li>
<li>GWT based Web application used to display monitoring data.</li>
</ol>
<p><strong>PEtALS ESB Extensions</strong></p>
<p><em>Registry Listener</em><br />
The role of the registry listener is to register a new monitoring endpoint into the monitoring layer when a new endpoint is available within PEtALS.</p>
<p><em>Routing Module</em><br />
Since modules can be added dynamically inside the PEtALS message router, we have created a module which timestamp the messages. Once the message exchange is complete, a message exchange report is sent to the monitoring layer.</p>
<p><strong>Monitoring Layer</strong></p>
<p>The monitoring is in charge of creating monitoring endpoints through a management API. Once a monitoring endpoint is created, it is also exposed as a Web service. This newly created Web service exposes a WS-notification subscribe operation.<br />
Another role of the monitoring layer is to receive raw reports from the PEtALS ESB, to process the report in order to generate a WSDM payload which will be send to subscribers.</p>
<p><strong>WS-Notification subscriber</strong></p>
<p>The subscriber subscribes, receives and stores notifications from the Monitoring layer. That&#8217;s all for that module ;o)</p>
<p><strong>GWT Based Web application</strong></p>
<p>The GWT Web application uses comet in order to display live service response time. The data used to display response time is the one received and stored into the database and of course the server part of the Web application have access to this database.</p>
<p>As a result, we have a really nice live Web application (live means that the chart gives real time result and is updated automatically when messages are exchanged within PEtALS Service Bus). Here are some screenshots :</p>
<div id="attachment_235" class="wp-caption aligncenter" style="width: 490px"><a href="http://chamerling.wordpress.com/files/2009/11/response_time.jpg"><img class="size-full wp-image-235" title="response_time" src="http://chamerling.wordpress.com/files/2009/11/response_time.jpg" alt="Live Response Time" width="480" height="255" /></a><p class="wp-caption-text">Live Response Time</p></div>
<div id="attachment_237" class="wp-caption aligncenter" style="width: 490px"><a href="http://chamerling.wordpress.com/files/2009/11/sla.jpg"><img class="size-full wp-image-237" title="SLA" src="http://chamerling.wordpress.com/files/2009/11/sla.jpg" alt="SLA" width="480" height="254" /></a><p class="wp-caption-text">SLA Violation</p></div>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Testing WCF/Web services]]></title>
<link>http://rikardalard.wordpress.com/2009/10/29/testing-wcfweb-services/</link>
<pubDate>Thu, 29 Oct 2009 08:19:20 +0000</pubDate>
<dc:creator>rikardalard</dc:creator>
<guid>http://rikardalard.wordpress.com/2009/10/29/testing-wcfweb-services/</guid>
<description><![CDATA[Need utils for fast testing of WCF or webservices? SoapUI is a great tool for testing webservices (h]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Need utils for fast testing of WCF or webservices?</p>
<p>SoapUI is a great tool for testing webservices (<a href="http://www.soapui.org/" target="_blank">http://www.soapui.org/</a>).</p>
<p>The built in WcfTestClient for VS Studio is another which works for both webservices as well as WCF services! It could be found under C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\WcfTestClient.exe in VS Studio 2008.</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Llega el Proxy/Cache para Webservices, ¡¡ lo necesitaras !!]]></title>
<link>http://jordifigueras.wordpress.com/2009/10/22/llega-el-proxycache-para-webservices-%c2%a1%c2%a1-lo-necesitaras/</link>
<pubDate>Thu, 22 Oct 2009 08:56:09 +0000</pubDate>
<dc:creator>jordifigueras</dc:creator>
<guid>http://jordifigueras.wordpress.com/2009/10/22/llega-el-proxycache-para-webservices-%c2%a1%c2%a1-lo-necesitaras/</guid>
<description><![CDATA[VPFW es un servidor proxy de Webservices XML/SOAP con las siguientes características: - Validación d]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>VPFW es un servidor proxy de Webservices XML/SOAP con las siguientes características:<br />
- Validación de documentos XML / SOAP<br />
- Tratamiento de peticiones SSL<br />
- Compresión, Cache y balanceo de carga</p>
<p>.. mas info en http://www.ventusproxy.com/</p>
<p><!-- SlideShare error: doc is missing or has illegal characters /[^-_a-zA-Z0-9]/ --></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Magento Schnittstellen zu SAP Business One, Sage und Microsoft Dynamics]]></title>
<link>http://ringsdorff.net/2009/10/21/magento-schnittstellen-zu-sap-business-one-sage-und-microsoft-dynamics/</link>
<pubDate>Tue, 20 Oct 2009 22:01:10 +0000</pubDate>
<dc:creator>Alexander Ringsdorff</dc:creator>
<guid>http://ringsdorff.net/2009/10/21/magento-schnittstellen-zu-sap-business-one-sage-und-microsoft-dynamics/</guid>
<description><![CDATA[In den meisten mir bekannten Magento Enterprise Projekten erfolgt eine individuelle Integration von ]]></description>
<content:encoded><![CDATA[In den meisten mir bekannten Magento Enterprise Projekten erfolgt eine individuelle Integration von ]]></content:encoded>
</item>
<item>
<title><![CDATA[Web Service]]></title>
<link>http://ass06.wordpress.com/2009/10/16/web-service/</link>
<pubDate>Fri, 16 Oct 2009 15:15:31 +0000</pubDate>
<dc:creator>ass06</dc:creator>
<guid>http://ass06.wordpress.com/2009/10/16/web-service/</guid>
<description><![CDATA[Teman-teman, sekarang contoh project-nya uda bisa di download di sini Projectnya agak beda sedikit d]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Teman-teman, sekarang contoh <em>project</em>-nya uda bisa di download <a href="http://www.4shared.com/file/141312083/a18ef93a/Contoh_Project.html">di sini</a></p>
<p>Projectnya agak beda sedikit dengan modifikasi tampilan saja,,,untuk kodingnya masih sama&#8230;.</p>
<p>Untuk menjalankan project tersebut, gunakan <em>GlassFish versi 2</em> dan untuk <em>backup database</em>-nya dapat di download <a href="http://www.4shared.com/file/141312754/8f0b0451/backup_pws_ass_20091016_1442.html">di sini</a></p>
<p>Penjelasan bagaimana menambahkan fungsi sudah ada dalam MATERI WEB SERVICE LANJUTAN.pdf yang dapat di download <a href="http://www.4shared.com/file/141312912/89a496a/MATERI_WEB_SERVICE_LANJUTAN.html">di sini</a></p>
<p>Selamat mencoba! Semangat..</p>
<p>ingat besok senin TTS Web Service</p>
<p>GBU.  ^.^V</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Calling webservice asynchronously from client script]]></title>
<link>http://rikardalard.wordpress.com/2009/10/14/calling-webservice-asynchronously-from-client-script/</link>
<pubDate>Wed, 14 Oct 2009 08:57:17 +0000</pubDate>
<dc:creator>rikardalard</dc:creator>
<guid>http://rikardalard.wordpress.com/2009/10/14/calling-webservice-asynchronously-from-client-script/</guid>
<description><![CDATA[One problem I encountered in a project is to call several services (Webservice/SQL etc) via BizTalk ]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>One problem I encountered in a project is to call several services (Webservice/SQL etc) via BizTalk before delivering a result back to a web application. By calling the services synchronously and letting the user wait meanwhile is not a good solution, however calling the services asynchronously seems like a better choice.</p>
<p>By using AJAX and exposing the services as webservices from BizTalk a great solution could be made. I made a test webservice with the following code:</p>
<p>namespace WebApplication1<br />
{<br />
    /// &#60;summary&#62;<br />
    /// Summary description for WebService1<br />
    /// &#60;/summary&#62;<br />
    [WebService(Namespace = "<a href="http://tempuri.org/">http://tempuri.org/</a>")] //<br />
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]<br />
    [System.ComponentModel.ToolboxItem(false)]<br />
    // To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line.<br />
    [System.Web.Script.Services.ScriptService]<br />
    public class WebService1 : System.Web.Services.WebService<br />
    {</p>
<p>        [WebMethod]<br />
        public string HelloWorld()<br />
        {<br />
            return &#8220;Hello World&#8221;;<br />
        }</p>
<p>        [WebMethod]<br />
        public string HelloWorld2()<br />
        {<br />
            System.Threading.Thread.Sleep(5000);<br />
            return &#8220;Hello World2&#8243;;<br />
        }<br />
    }<br />
}</p>
<p>Note the 5 seconds sleep in the HelloWord2 method. Then I created and AJAX enabled web page, with the following code:</p>
<p>&#60;%@ Page Language=&#8221;C#&#8221; AutoEventWireup=&#8221;true&#8221; CodeBehind=&#8221;Default.aspx.cs&#8221; Inherits=&#8221;WebApplication1.Default1&#8243; %&#62;</p>
<p>&#60;!DOCTYPE html PUBLIC &#8220;-//W3C//DTD XHTML 1.0 Transitional//EN&#8221; &#8220;<a href="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd</a>&#8220;&#62;<br />
&#60;html xmlns=&#8221;<a href="http://www.w3.org/1999/xhtml">http://www.w3.org/1999/xhtml</a>&#8220;&#62;<br />
&#60;head runat=&#8221;server&#8221;&#62;<br />
    &#60;title&#62;&#60;/title&#62;</p>
<p>    &#60;script type=&#8221;text/javascript&#8221;&#62;</p>
<p>        function pageLoad() {<br />
        }</p>
<p>        function MyBtn_onclick() {<br />
            ret1 = WebApplication1.WebService1.HelloWorld2(OnComplete1, OnTimeout, OnError);<br />
            ret2 = WebApplication1.WebService1.HelloWorld(OnComplete2, OnTimeout, OnError);<br />
        }</p>
<p>        function OnTimeout() {<br />
            alert(&#8220;Timeout on webservice call&#8221;);<br />
        }</p>
<p>        function OnError() {<br />
            alert(&#8220;Error in webservice call&#8221;);<br />
        }</p>
<p>        function OnComplete1(arg) {<br />
            document.getElementById(&#8216;MySpan2&#8242;).innerHTML = arg;<br />
        }</p>
<p>        function OnComplete2(arg) {<br />
            document.getElementById(&#8216;MySpan1&#8242;).innerHTML = arg;<br />
        }<br />
    &#60;/script&#62;</p>
<p>&#60;/head&#62;<br />
&#60;body&#62;<br />
    &#60;form id=&#8221;form1&#8243; runat=&#8221;server&#8221;&#62;<br />
    &#60;div&#62;<br />
        &#60;asp:ScriptManager ID=&#8221;ScriptManager1&#8243; runat=&#8221;server&#8221;&#62;<br />
           &#60;!&#8211; Add a reference to the webservice, to be able to call it from javascript code above &#8211;&#62;<br />
            &#60;Services&#62;<br />
                &#60;asp:ServiceReference Path=&#8221;~/WebService1.asmx&#8221; /&#62;<br />
            &#60;/Services&#62;<br />
        &#60;/asp:ScriptManager&#62;<br />
        &#60;input id=&#8221;MyBtn&#8221; onclick=&#8221;return MyBtn_onclick()&#8221; type=&#8221;button&#8221; value=&#8221;Invoke&#8221; /&#62;<br />
        &#60;br /&#62;&#60;br /&#62;<br />
        &#60;span id=&#8221;MySpan1&#8243;&#62;&#60;/span&#62;<br />
        &#60;br /&#62;<br />
        &#60;span id=&#8221;MySpan2&#8243;&#62;&#60;/span&#62;<br />
    &#60;/div&#62;<br />
    &#60;/form&#62;<br />
&#60;/body&#62;<br />
&#60;/html&#62;</p>
<p>When a user clicks on the Invoke button, the code invokes the both methods asynchronously. This means that the HelloWorld method returns its value before the HelloWorld2, even thought the HelloWorld2 is called before HelloWorld.</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[SOAP - its Simple]]></title>
<link>http://knwrites.wordpress.com/2009/10/12/soap-its-simple/</link>
<pubDate>Mon, 12 Oct 2009 10:56:19 +0000</pubDate>
<dc:creator>knwrites</dc:creator>
<guid>http://knwrites.wordpress.com/2009/10/12/soap-its-simple/</guid>
<description><![CDATA[SOAP &#8211; Simple Object Access Protocol Definition:     SOAP is a simple XML based protocol used ]]></description>
<content:encoded><![CDATA[SOAP &#8211; Simple Object Access Protocol Definition:     SOAP is a simple XML based protocol used ]]></content:encoded>
</item>
<item>
<title><![CDATA[Webservice - A smal story]]></title>
<link>http://knwrites.wordpress.com/2009/10/08/webservice-a-smal-story/</link>
<pubDate>Thu, 08 Oct 2009 06:42:15 +0000</pubDate>
<dc:creator>knwrites</dc:creator>
<guid>http://knwrites.wordpress.com/2009/10/08/webservice-a-smal-story/</guid>
<description><![CDATA[Steps to expose a web service Create a well qualified WSDL Generate the Parameters &amp; return type]]></description>
<content:encoded><![CDATA[Steps to expose a web service Create a well qualified WSDL Generate the Parameters &amp; return type]]></content:encoded>
</item>
<item>
<title><![CDATA[Exposing Fractal Components as Webservices in PEtALS ESB]]></title>
<link>http://chamerling.wordpress.com/2009/10/07/exposing-fractal-components-as-webservices-in-petals-esb/</link>
<pubDate>Wed, 07 Oct 2009 10:23:42 +0000</pubDate>
<dc:creator>Kitov</dc:creator>
<guid>http://chamerling.wordpress.com/2009/10/07/exposing-fractal-components-as-webservices-in-petals-esb/</guid>
<description><![CDATA[I just added a new feature to PEtALS ESB kernel in order to expose Fractal Components as Webservices]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>I just added a new feature to PEtALS ESB kernel in order to expose Fractal Components as Webservices in the PEtALS ESB kernel. As an example, let&#8217;s expose some PEtALS runtime information as Web service.</p>
<p>Here are the steps to follow :</p>
<p><strong><em>1. Create your component interface and add JAXWS annotations</em></strong></p>
<pre class="brush: java;">
package org.ow2.petals.kernel.ws.api;

import java.util.Date;

import javax.jws.WebMethod;
import javax.jws.WebResult;
import javax.jws.WebService;

@WebService
public interface InformationService {

    /**
     * Get the container version
     *
     * @return
     * @throws PEtALSWebServiceException
     */
    @WebMethod()
    @WebResult(name = &#34;version&#34;)
    String getVersion() throws PEtALSWebServiceException;

    /**
     * Get the container type : standalone, platform, quickstart...
     *
     * @return
     * @throws PEtALSWebServiceException
     */
    @WebMethod()
    @WebResult(name = &#34;type&#34;)
    String getType() throws PEtALSWebServiceException;

    @WebMethod
    Date getLocalTime() throws PEtALSWebServiceException;

}
</pre>
<p><em><strong>2. Implement your Fractal component</strong></em><strong><br />
</strong></p>
<pre class="brush: java;">
package org.ow2.petals.ws;

import java.util.Date;

import org.objectweb.fractal.api.Component;
import org.objectweb.fractal.fraclet.annotation.annotations.FractalComponent;
import org.objectweb.fractal.fraclet.annotation.annotations.Interface;
import org.objectweb.fractal.fraclet.annotation.annotations.LifeCycle;
import org.objectweb.fractal.fraclet.annotation.annotations.Monolog;
import org.objectweb.fractal.fraclet.annotation.annotations.Provides;
import org.objectweb.fractal.fraclet.annotation.annotations.Requires;
import org.objectweb.fractal.fraclet.annotation.annotations.type.LifeCycleType;
import org.objectweb.util.monolog.api.Logger;
import org.ow2.petals.jbi.management.admin.AdminService;
import org.ow2.petals.kernel.ws.api.InformationService;
import org.ow2.petals.kernel.ws.api.PEtALSWebServiceException;
import org.ow2.petals.tools.ws.KernelWebService;
import org.ow2.petals.util.LoggingUtil;

@FractalComponent
@Provides(interfaces = { @Interface(name = &#34;webservice&#34;, signature = InformationService.class),
        @Interface(name = &#34;service&#34;, signature = KernelWebService.class) })
public class InformationServiceImpl implements KernelWebService, InformationService {

    @Monolog(name = &#34;logger&#34;)
    private Logger logger;

    private LoggingUtil log;

    @org.objectweb.fractal.fraclet.annotation.annotations.Service(name = &#34;component&#34;)
    private Component component;

    @Requires(name = &#34;adminService&#34;, signature = AdminService.class)
    private AdminService adminService;

    @LifeCycle(on = LifeCycleType.START)
    protected void start() {
        this.log = new LoggingUtil(this.logger);
        this.log.debug(&#34;Starting...&#34;);
    }

    @LifeCycle(on = LifeCycleType.STOP)
    protected void stop() {
        this.log.debug(&#34;Stopping...&#34;);
    }

    /**
     * {@inheritDoc}
     */
    public Component getComponent() {
        return this.component;
    }

    /**
     * {@inheritDoc}
     */
    public String getType() throws PEtALSWebServiceException {
        return &#34;Platform&#34;;
    }

    /**
     * {@inheritDoc}
     */
    public String getVersion() throws PEtALSWebServiceException {
        return this.adminService.getSystemInfo();
    }

    /**
     * {@inheritDoc}
     */
    public Date getLocalTime() throws PEtALSWebServiceException {
        return new Date();
    }

}
</pre>
<p>In the implementation, the important points are :</p>
<ol>
<li>The @Provides part. The KernelWebService.class interface MUST be named &#8220;service&#8221;. The &#8216;business&#8217; interface to be exposed (here InformationService.class MUST be named &#8220;webservice&#8221;)</li>
<li>The Component field is mandatory (used by the webservice manager). Its accessor is mandatory too!</li>
<li>The implementation MUST implement KernelWebService and the interface you want to expose</li>
</ol>
<p>The implementation will not be exposed as Web service if the previous points are not followed.</p>
<p><strong><em>3. Add the component to the WebServiceManager component with the help of Fractal descriptors</em></strong></p>
<p>For now, the Fractal composite used to expose Fractal components as Web services is defined in the Tools.fractal descriptor (located under your favorite petals distribution). Here are the important steps :</p>
<p><em>A. Instanciate the component<br />
</em> <span style="font-family:Monaco, 'Times New Roman', 'Bitstream Charter', Times, serif;line-height:normal;font-size:11px;">&#60;component definition=&#8221;org.ow2.petals.ws.InformationServiceImpl&#8221; name=&#8221;InformationWebServiceImpl&#8221;/&#62;</span></p>
<div><em>B. Bind component (dependencies to other components)</em></div>
<div><span style="font-family:Monaco, 'Times New Roman', 'Bitstream Charter', Times, serif;line-height:normal;font-size:11px;">&#60;binding client=&#8221;InformationWebServiceImpl.adminService&#8221; server=&#8221;this.adminService&#8221;/&#62;</span></div>
<div>
<div><span style="font-family:Monaco, 'Times New Roman', 'Bitstream Charter', Times, serif;font-size:small;"><span style="line-height:normal;"><br />
</span></span></div>
</div>
<div><em>C. Say to the Web service Manager to expose this component as Web service</em></div>
<div>
<p style="font:11px Monaco;margin:0;">&#60;binding client=&#8221;WebServiceManagerImpl.webservice-information&#8221; server=&#8221;InformationWebServiceImpl.service&#8221;/&#62;</p>
<div><span style="font-family:Monaco, 'Times New Roman', 'Bitstream Charter', Times, serif;"><span style="line-height:normal;font-size:small;"><br />
</span></span></div>
</div>
<div>Note that in the last point, you MUST always give &#8216;WebServiceManagerImpl-webservice-SOMETHING&#8217; as client and give the implementation service as server.</div>
<div>Done! Your component is now exposed as Web service and accessible at &#8216;http://HOST:7600/petals/ws/SERVICE&#8217; where HOST is the host on which you start petals and SERVICE depends on the JAXWS WebService annotation or class name.</div>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Mannar updates.]]></title>
<link>http://sjayapal.wordpress.com/2009/10/06/mannarupdates/</link>
<pubDate>Wed, 07 Oct 2009 03:18:52 +0000</pubDate>
<dc:creator>Sathish Jayapal</dc:creator>
<guid>http://sjayapal.wordpress.com/2009/10/06/mannarupdates/</guid>
<description><![CDATA[We were trying to use the google app engine for communicating with Weather web-service. there are so]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>We were trying to use the google app engine for communicating with Weather web-service. there are some special problems; when I run the jar file in the web app engine container. I&#8217;m running into sever CLASSPATH issues. It is taking forever to resolve this. For the sake of continuing the blog let us throw the errors running into. Again here are the configuration files</p>
<p>Struts-config.xml</p>
<div id="attachment_50" class="wp-caption alignleft" style="width: 160px"><a href="http://sjayapal.wordpress.com/files/2009/10/picture-2.png"><img class="size-thumbnail wp-image-50" title="struts-config" src="http://sjayapal.wordpress.com/files/2009/10/picture-2.png?w=150" alt="struts-config" width="150" height="141" /></a><p class="wp-caption-text">struts-config</p></div>
<div id="attachment_51" class="wp-caption alignleft" style="width: 160px"><a href="http://sjayapal.wordpress.com/files/2009/10/picture-3.png"><img class="size-thumbnail wp-image-51" title="Struts Forms" src="http://sjayapal.wordpress.com/files/2009/10/picture-3.png?w=150" alt="Struts Forms" width="150" height="19" /></a><p class="wp-caption-text">Struts Forms</p></div>
<div id="attachment_52" class="wp-caption alignleft" style="width: 160px"><a href="http://sjayapal.wordpress.com/files/2009/10/picture-4.png"><img class="size-thumbnail wp-image-52" title="Struts-Action" src="http://sjayapal.wordpress.com/files/2009/10/picture-4.png?w=150" alt="Struts-Action" width="150" height="38" /></a><p class="wp-caption-text">Struts-Action</p></div>
<p>The locationinput.do is a JSP file. YUI is being used for developing some drop downs and auto complete.  We will keep the YUI discussion for another day. But on a high level weatherstation.jsp</p>
<div id="attachment_54" class="wp-caption alignleft" style="width: 160px"><a href="http://sjayapal.wordpress.com/files/2009/10/picture-7.png"><img class="size-thumbnail wp-image-54" title="WeatherStation.jsp" src="http://sjayapal.wordpress.com/files/2009/10/picture-7.png?w=150" alt="WeatherStation.jsp" width="150" height="70" /></a><p class="wp-caption-text">WeatherStation.jsp</p></div>
<p>Upon submission of this page; the action class is invoked. Following screen print. Though I have not completed this action fully, it gives an overall idea.</p>
<div id="attachment_55" class="wp-caption alignleft" style="width: 160px"><a href="http://sjayapal.wordpress.com/files/2009/10/picture-9.png"><img class="size-thumbnail wp-image-55" title="WeatherStationInvokeAction" src="http://sjayapal.wordpress.com/files/2009/10/picture-9.png?w=150" alt="WeatherStationInvokeAction" width="150" height="96" /></a><p class="wp-caption-text">WeatherStationInvokeAction</p></div>
<div id="attachment_56" class="wp-caption alignleft" style="width: 160px"><a href="http://sjayapal.wordpress.com/files/2009/10/picture-10.png"><img class="size-thumbnail wp-image-56" title="Delegate" src="http://sjayapal.wordpress.com/files/2009/10/picture-10.png?w=150" alt="Delegate" width="150" height="80" /></a><p class="wp-caption-text">Delegate</p></div>
<p>The reason for using the JEE&#8217;s delegate pattern up here is; we are using the business objects that returns data/throws exception directly; isolation from action classes will give a cleaner separation.</p>
<p>Moving on, when running this application the error is</p>
<pre>
<div id="attachment_58" class="wp-caption alignleft" style="width: 160px"><a href="http://sjayapal.wordpress.com/files/2009/10/picture-11.png"><img class="size-thumbnail wp-image-58" title="Error" src="http://sjayapal.wordpress.com/files/2009/10/picture-11.png?w=150" alt="Error" width="150" height="40" /></a><p class="wp-caption-text">Error</p></div>
</pre>
<p>Looking from the error; looks like it is a perfect storm of classpath issues. Have the JAXB working for parsing  XML. Google app engine has a XML parser and on top of that; we are using JAX WS for webservices. All the culmination; yet to find a solution to resolve this and present a full sketch of an application. One quick update today is Ported everything to a JBOSS app server to see if that helps<br />
Bummer, JBOSS does a proxy delegate that is again posing some CLASSPATH issues.<br />
If there are any solutions to resolve this; please do put in your comments.</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Poll - android webservice lib]]></title>
<link>http://orgeltom.wordpress.com/2009/10/06/poll-android-webservice-lib/</link>
<pubDate>Tue, 06 Oct 2009 19:01:42 +0000</pubDate>
<dc:creator>orgeltom</dc:creator>
<guid>http://orgeltom.wordpress.com/2009/10/06/poll-android-webservice-lib/</guid>
<description><![CDATA[Is there a need for a android lib to handle webservice-calls? (polls) Here is a draft version of the]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p> <a href="http://answers.polldaddy.com/poll/2085431/">Is there a need for a android lib to handle webservice-calls?</a><br />
 <span style="font:9px;">(<a href="http://www.polldaddy.com">polls</a>)</span></p>
<p>Here is a draft version of the interface of the Connector to the webservice:<br />
<code><br />
public interface WebServiceConnectorI {</p>
<p>	public String getWSDL();</p>
<p>	public void setURL(String url);</p>
<p>	public String callMethod(String method);</p>
<p>	public String callMethod(String method, ArrayList params);<br />
}<br />
</code></p>
<p>And here the class for the method-parameters:<br />
<code><br />
public class MethodParameter {</p>
<p>	public MethodParameter(String parameter, String value) {<br />
		super();<br />
		this.parameter = parameter;<br />
		this.value = value;<br />
	}</p>
<p>	private String parameter;</p>
<p>	private String value;</p>
<p>	public String getParameter() {<br />
		return parameter;<br />
	}</p>
<p>	public void setParameter(String parameter) {<br />
		this.parameter = parameter;<br />
	}</p>
<p>	public String getValue() {<br />
		return value;<br />
	}</p>
<p>	public void setValue(String value) {<br />
		this.value = value;<br />
	}</p>
<p>}<br />
</code></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[PEtALS ESB over the internet]]></title>
<link>http://chamerling.wordpress.com/2009/10/05/petals-esb-over-the-internet/</link>
<pubDate>Mon, 05 Oct 2009 13:46:33 +0000</pubDate>
<dc:creator>Kitov</dc:creator>
<guid>http://chamerling.wordpress.com/2009/10/05/petals-esb-over-the-internet/</guid>
<description><![CDATA[I am finally back from the SOA4All project review @ Brussels where I showed a Distributed Service Bu]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>I am finally back from the SOA4All project review @ Brussels where I showed a Distributed Service Bus based on PEtALS ESB deployed over the internet.</p>
<p>The first prototype of the SOA4All Distributed Service Bus has been deployed on 4 nodes (three in France at Toulouse, Antibes, Paris and one in Austria at Innsbruck). Each node was providing SOAP access to all the platform services bound to the bus (most of them were SOAP based Web services). It is good to note that response time was quite good between service consumers and providers (some optimizations to be performed to avoid remote checking before sending messages).</p>
<blockquote><p>Note 1 : It is true that to allow the nodes communication, we opened all the required ports (actually 4 for SOAP/HTTP, JMX and raw TCP communication) but next step will be probably to just use the default HTTP port and this is a real challenge&#8230;</p></blockquote>
<blockquote><p>Note 2 : The new distributed technical registry (self developed) used to store service endpoints was used in the prototype. Good job <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p></blockquote>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Tribunal de Justiça de Santa Catarina recebe comitiva nacional da Empresa de Correios e Telégrafos (ECT) para apresentar o "V-Post"]]></title>
<link>http://mpscjoinville.wordpress.com/2009/10/02/tribunal-de-justica-de-santa-catarina-recebe-comitiva-nacional-da-empresa-de-correios-e-telegrafos-ect-para-apresentar-o-v-post/</link>
<pubDate>Fri, 02 Oct 2009 17:16:47 +0000</pubDate>
<dc:creator>Promotorias de Justiça da Comarca de Joinville</dc:creator>
<guid>http://mpscjoinville.wordpress.com/2009/10/02/tribunal-de-justica-de-santa-catarina-recebe-comitiva-nacional-da-empresa-de-correios-e-telegrafos-ect-para-apresentar-o-v-post/</guid>
<description><![CDATA[Após a solenidade dos 118 anos de instalação do Tribunal de Justiça, os desembargadores presentes as]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p style="text-align:justify;">Após a solenidade dos 118 anos de instalação do Tribunal de Justiça, os desembargadores presentes assistiram, reunidos com uma comitiva nacional da Empresa de Correios e Telégrafos (ECT), uma breve apresentação realizada pelo juiz João Alexandre Dobrowolski Neto, da CGInfo, e do servidor da Comarca de Lebon Régis, Márcio Vicente Cruz sobre A.R. Digital.</p>
<p style="text-align:justify;">A comitiva veio ao Estado para conhecer o projeto intitulado V-Post &#8211; responsável pela expedição de avisos de recebimentos digitais – e seu impacto no chamado processo eletrônico. A visita tem como objetivo conhecer detalhes de funcionamento do projeto, pioneiro no Brasil, e identificar a possibilidade de estendê-lo aos demais tribunais do país. O programa V-Post – Postagens Virtuais, parceria firmada entre ECT, Softplan e Poder Judiciário, visa agilizar, através da informatização, a expedição de documentos judiciais.</p>
<p style="text-align:justify;">O A.R. Digital Autoenvelopável é fruto de um WebService entre o Judiciário catarinense e os Correios. Através de um protocolo de integração, as duas instituições trocam dados pela WEB. Em outras palavras, os respectivos sistemas conversam entre si. Graças a este produto somente este ano já foram expedidos, enviados eletronicamente aos correios, e por este impressos e envelopados mecanicamente, e diligenciados pelos carteiros, mais de 20 mil ofícios de citação na Unidade de Execução Fiscal da Capital.</p>
<p style="text-align:justify;">O resultado dos esforços da ECT são cadastrados em sistema próprio e repassados ao Sistema de Automação do Judiciário (SAJ) através do WebService &#8211; inclusive com imagem digitalizada do A.R. que logrou sucesso. Todo este trabalho, que num processo comum consumiria exaustivos esforços de todo o Cartório, é realizado por apenas um servidor do Judiciário &#8211; e como atribuição residual, e não principal.</p>
<p style="text-align:justify;">Em janeiro deste ano, o Judiciário catarinense e a Empresa Brasileira de Correios e Telégrafos (ECT/SC) assinaram um contrato que possibilitou o funcionamento do A.R. Digital Autoenvelopável. Já em junho, um termo assinado entre o Supremo Tribunal Federal, Conselho Nacional de Justiça, Superior Tribunal de Justiça, Conselho da Justiça Federal, Tribunal Superior do Trabalho, Conselho Superior da Justiça do Trabalho e a Advocacia-Geral da União, pede a elaboração e implementação do padrão nacional de integração de sistemas de processo eletrônico, por meio da tecnologia &#8220;WebService&#8221;.</p>
<p style="text-align:right;"><em><a href="http://app.tjsc.jus.br/noticias/listanoticia!viewNoticia.action;jsessionid=7BC889134508B800BD64DC2829137031?cdnoticia=19475" target="_blank">Tribunal de Justiça de Santa Catarina »</a></em></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[How to Secure Java Webservice with encryption and signature]]></title>
<link>http://thetechtips.wordpress.com/2009/09/30/secure-java-webservice-with-encryption-and-signature/</link>
<pubDate>Wed, 30 Sep 2009 21:41:08 +0000</pubDate>
<dc:creator>thetechtips</dc:creator>
<guid>http://thetechtips.wordpress.com/2009/09/30/secure-java-webservice-with-encryption-and-signature/</guid>
<description><![CDATA[Introduction In the last post I had a short description on webservice security. In this post, we bui]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p style="text-align:left;"><strong>Introduction</strong></p>
<p style="text-align:left;">In the <a href="http://thetechtips.wordpress.com/2009/09/17/web-service-security/">last post </a>I had a short description on webservice security. In this post, we build a secure webservice and create a client to access it. For doing so, the same environment as in the <a href="http://thetechtips.wordpress.com/2009/08/27/how-to-create-a-metro-jax-ws-portable-webservice/">Simple Webservice example</a> is used. We will use Metro&#8217;s WSIT features to enable secrity for our webservice.<!--more--></p>
<p style="text-align:left;"><strong>Creating the webservice</strong></p>
<p style="text-align:left;">The steps for creating and deploying an unsecured webservice are described in <a href="http://thetechtips.wordpress.com/2009/08/27/how-to-create-a-metro-jax-ws-portable-webservice/">this post</a>. Follow these steps till Step 6 (we do not deploy the webservice yet). Now we need to make the webservice secure.</p>
<p style="text-align:left;"><strong>Generate Key Pair</strong></p>
<p style="text-align:left;">In order to perform encryption and signature, the webservice and the client need a public-private key pair. The public key is wrapped inside a X509 certificate. In this example we do not use mutual certificates. The private key (or identity key) is with the webservice only. The public key (X509 certificate) is distributed to clients. What is encrypted using the public certificate, can only be decrypted using the private key and vice-versa. In this example, the private key is part of a KeyStore configured on the webservice, and the public certificate is part of a TrustStore configured on the client side.</p>
<p style="text-align:left;">To create a key-pair for use with this example, create a directory to keep the KeyStore and TrustStore in (call it <code>&#60;KEY_DIR&#62;</code>). Browse to this dir on command prompt and run<br />
<code>keytool -genkey -alias serviceKey -keypass mykeypass -keystore wsKeyStore.jks -storepass changeit -keyalg RSA -dname "CN=Tech Tips, OU=Blog, O=The Tech tips, L=DFW, ST=TX, C=US"</code></p>
<p style="text-align:left;">This creates the keystore with the private key in it. Now export the public certificate:<br />
<code>keytool -export -alias serviceKey -keypass mykeypass -keystore wsKeyStore.jks -storepass changeit -file publicCert.cer</code></p>
<p style="text-align:left;">and import the public certificate into a truststore:<br />
<code>keytool -import -alias publicCert -keystore wsTrustStore.jks -storepass changeit -file publicCert.cer</code></p>
<p style="text-align:left;"><strong>Specify Security Requirements</strong></p>
<p style="text-align:left;">In order to convey their security constraints to clients, webservices can include their security specifications as part of the WSDL. This is done by making use of WS-Security Policy (WSSP) assertions. The clients who have access to the WSDL therefore know the security contract for accessing the webservice.</p>
<p style="text-align:left;">Instead of creating a custom way of specifying security requirements when creating a webservice, WSIT (part of metro stack) makes use of the already developed way (using WSSP assertions). In order to enable security for our webservice, all we need is a static WSDL-like definitions file which contains the desire WSSP assertions assigned to our endpoint. This file needs to have a special name &#8216;<code>wsit-&#60;fully qualified implementation class name&#62;.xml</code>&#8216;.</p>
<p style="text-align:left;">In MetroWebserviceSample eclipse project&#8217;s <code>WEB-INF</code> directory, create a file named &#8216;<code>wsit-test.metro.sample.TestService.xml</code>&#8216;. The contents of this file should be as follows:</p>
<pre class="brush: xml;">&#60;?xml version=&#34;1.0&#34; encoding=&#34;UTF-8&#34; standalone=&#34;yes&#34;?&#62;
&#60;!-- Generated by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.2-hudson-182-RC1. --&#62;
&#60;definitions targetNamespace=&#34;http://sample.metro.test/&#34;
 xmlns:tns=&#34;http://sample.metro.test/&#34;
 xmlns:xsd=&#34;http://www.w3.org/2001/XMLSchema&#34;
 xmlns=&#34;http://schemas.xmlsoap.org/wsdl/&#34;
 xmlns:soap=&#34;http://schemas.xmlsoap.org/wsdl/soap/&#34;
 xmlns:wsu=&#34;http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd&#34;
 xmlns:wsp=&#34;http://schemas.xmlsoap.org/ws/2004/09/policy&#34;
 xmlns:sp=&#34;http://schemas.xmlsoap.org/ws/2005/07/securitypolicy&#34;
 xmlns:wspp=&#34;http://java.sun.com/xml/ns/wsit/policy&#34;&#62;
 
   &#60;wsp:Policy wsu:Id=&#34;TestService_Security_Policy&#34;&#62;
  &#60;wsp:ExactlyOne&#62;
   &#60;wsp:All&#62;   
    &#60;sp:SymmetricBinding &#62;
     &#60;wsp:Policy&#62;
      &#60;sp:ProtectionToken&#62;
       &#60;wsp:Policy&#62;
        &#60;sp:X509Token sp:IncludeToken=&#34;http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never&#34;&#62;
         &#60;wsp:Policy&#62;
          &#60;sp:WssX509V3Token10/&#62;
          &#60;sp:RequireDerivedKeys/&#62;
          &#60;sp:RequireIssuerSerialReference/&#62;
         &#60;/wsp:Policy&#62;
        &#60;/sp:X509Token&#62;
       &#60;/wsp:Policy&#62;
      &#60;/sp:ProtectionToken&#62;
      
      &#60;sp:AlgorithmSuite&#62;      
       &#60;wsp:Policy&#62;
        &#60;sp:Basic128/&#62;
       &#60;/wsp:Policy&#62;       
      &#60;/sp:AlgorithmSuite&#62;
      
      &#60;sp:Layout&#62;      
       &#60;wsp:Policy&#62;
        &#60;sp:Strict/&#62;
       &#60;/wsp:Policy&#62;       
      &#60;/sp:Layout&#62; 
      &#60;sp:IncludeTimestamp/&#62;  
      &#60;sp:EncryptBeforeSigning/&#62;   
     &#60;/wsp:Policy&#62;
    &#60;/sp:SymmetricBinding&#62;
    &#60;sp:Wss11&#62;
            &#60;wsp:Policy&#62;
              &#60;sp:MustSupportRefIssuerSerial/&#62;
            &#60;/wsp:Policy&#62;
          &#60;/sp:Wss11&#62;
             &#60;sc:KeyStore wspp:visibility=&#34;private&#34;
              xmlns:wspp=&#34;http://java.sun.com/xml/ns/wsit/policy&#34;
              xmlns:sc=&#34;http://schemas.sun.com/2006/03/wss/server&#34;
              location=&#34;&#60;KEY_DIR&#62;\wsKeyStore.jks&#34;
              type=&#34;JKS&#34; keypass=&#34;mykeypass&#34;
              alias=&#34;serviceKey&#34;
              storepass=&#34;changeit&#34;&#62;
             &#60;/sc:KeyStore&#62;
   &#60;/wsp:All&#62;
  &#60;/wsp:ExactlyOne&#62;
 &#60;/wsp:Policy&#62;
 
 &#60;wsp:Policy wsu:Id=&#34;TestService_Encryption_policy&#34;&#62;
  &#60;wsp:ExactlyOne&#62;
   &#60;wsp:All&#62;    
    &#60;sp:EncryptedParts xmlns:sp=&#34;http://schemas.xmlsoap.org/ws/2005/07/securitypolicy&#34;&#62;
     &#60;sp:Body /&#62;
    &#60;/sp:EncryptedParts&#62;      
   &#60;/wsp:All&#62;
  &#60;/wsp:ExactlyOne&#62;
 &#60;/wsp:Policy&#62;
 &#60;wsp:Policy wsu:Id=&#34;TestService_Signature_policy&#34;&#62;
  &#60;wsp:ExactlyOne&#62;
   &#60;wsp:All&#62;
    &#60;sp:SignedParts xmlns:sp=&#34;http://schemas.xmlsoap.org/ws/2005/07/securitypolicy&#34;&#62;
     &#60;sp:Body /&#62;
    &#60;/sp:SignedParts&#62;
   &#60;/wsp:All&#62;
  &#60;/wsp:ExactlyOne&#62;
 &#60;/wsp:Policy&#62;
 
 
&#60;portType name=&#34;TestService&#34;&#62;
  &#60;/portType&#62;
 
  &#60;binding name=&#34;TestServicePortBinding&#34; type=&#34;tns:TestService&#34;&#62;
   &#60;wsp:PolicyReference URI=&#34;#TestService_Security_Policy&#34;&#62;&#60;/wsp:PolicyReference&#62;
   &#60;wsp:PolicyReference URI=&#34;#TestService_Encryption_policy&#34;&#62;&#60;/wsp:PolicyReference&#62;
   &#60;wsp:PolicyReference URI=&#34;#TestService_Signature_policy&#34;&#62;&#60;/wsp:PolicyReference&#62;
  &#60;/binding&#62;
 
  &#60;service name=&#34;TestServiceService&#34;&#62;
     &#60;!-- Uncomment this section if above configured security is to be enabled --&#62;
     &#60;!-- --&#62;
  
&#60;port name=&#34;TestServicePort&#34; binding=&#34;tns:TestServicePortBinding&#34;&#62;
   &#60;/port&#62;
  &#60;/service&#62;
&#60;/definitions&#62;
</pre>
<p style="text-align:left;">The above file has the minimum content required for this configuration (in other situations we can have the complete WSDL, plus the policy declarations and references). It enforces encryption of the SOAP body element followed by signing the encrypted body (<code>EncryptBeforeSigning</code>) for all messages (requests and responses). For the purpose of encryption and signing derived keys based on an X509 token are used. The location of the token is specified using Metro specific element.</p>
<p style="text-align:left;"><strong>Deploy the Webservice</strong></p>
<li style="text-align:left;">Right click the eclipse project MetroWebserviceSample and export to a .war  file (MetroWebserviceSample.war).</li>
<li style="text-align:left;">Copy MetroWebserviceSample.war to &#60;TOMCAT_HOME&#62;/webapps and start the Tomcat server.</li>
<li style="text-align:left;">The WSDL can be looked up at <a href="http://localhost:8080/MetroWebserviceSample/test?wsdl">http://localhost:8080/MetroWebserviceSample/test?wsdl</a>.</li>
<p style="text-align:left;">Note that the element describing the location of X509 token (keystore etc) is not visible in the online WSDL.</p>
<p style="text-align:left;"><strong>Create the Client</strong></p>
<p style="text-align:left;">In order to create a POJO client which does not run inside a container, the Metro libraries will be needed. As indicated in <a href="http://thetechtips.wordpress.com/2009/08/27/how-to-create-a-metro-jax-ws-portable-webservice/" target="_blank">this post</a>, download Metro and put the expand the contents (call this directory <code>&#60;METRO_HOME&#62;</code>).  For convinience the directory <code>&#60;METRO_HOME&#62;/bin</code> can be added to the environment variable <code>Path</code>, so that the tools <code>wsgen</code> and <code>wsimport</code> can be used without qualified location. For JDK 6 onwards, these tools are part of the jdk.</p>
<p style="text-align:left;">Create a directory for the client code <code>&#60;CLIENT_HOME&#62;</code>. This can as well be an eclipse Java project. However, the instructions here are for running the client without using eclipse.</p>
<p style="text-align:left;">While the webservice is running on Tomcat, on the command prompt run:<br />
<code>wsimport -d &#60;CLIENT_HOME&#62; -s &#60;CLIENT_HOME&#62; -p test.metro.sample.client http://localhost:8080/MetroWebserviceSample/test?wsdl</code><br />
This will create the classes needed by the client, under the package structure <code>test.metro.sample.client</code>. Note that the classes are already compiled, so we will not recompile them.</p>
<p style="text-align:left;">In the directory <code>&#60;CLIENT_HOME&#62;/test/metro</code>, create a directory named <code>client</code>. Create a file <code>TestServiceClient.java</code> in this directory (so the package for this class is <code>test.metro.client</code>). The contents of <code>TestServiceClient.java</code> should be:</p>
<pre class="brush: java;">package test.metro.client;

import test.metro.sample.client.TestService;
import test.metro.sample.client.TestServiceService;

public class TestServiceClient {

 private String defaultGreeter = &#34;TheTechTips&#34;;
 /**
  * @param args
  */
 public static void main(String[] args) {
  
  TestServiceClient client = new TestServiceClient();
  TestService service = new TestServiceService().getPort(TestService.class);
  System.out.println(&#34;Greeatings are...&#34;);
  if (args.length == 0) {
   System.out.println(service.greet(client.defaultGreeter));
  } else {
   for (String greeter : args) {
    System.out.println(service.greet(greeter));
   }
  }
 }

}
</pre>
<p style="text-align:left;">To compile the above class, browse to <code>&#60;CLIENT_HOME&#62;</code> directory on command prompt (for convinience) and run:<br />
<code>javac -cp %CLASSPATH%;.;&#60;METRO_HOME&#62;/lib/webservices-api.jar test/metro/client/TestServiceClient.java</code></p>
<p style="text-align:left;"><strong>Client Security Configuration</strong></p>
<p style="text-align:left;">Similar to the wsdl-like file we created for securing the webservice, we need to specify where the client can find the security certificate to send proper requests to the service. The client config file should be named <code>&#60;service&#62;Service.xml</code> and placed in the <code>META-INF</code> directory. In addition, another xml file called <code>wsit-client.xml</code> is to be pesent in <code>META-INF</code>. The latter file imports the former.</p>
<p style="text-align:left;">Create a <code>META-INF</code> directory under <code>&#60;CLIENT_HOME&#62;</code>. Put files <code>TestServiceService.xml</code> and <code>wsit-client.xml</code> in the <code>META-INF</code> directory with following contents.</p>
<p style="text-align:left;">TestServiceService.xml</p>
<pre class="brush: xml;">&#60;?xml version=&#34;1.0&#34; encoding=&#34;UTF-8&#34; standalone=&#34;yes&#34;?&#62;
&#60;!-- Generated by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.2-hudson-182-RC1. --&#62;
&#60;definitions targetNamespace=&#34;http://sample.metro.test/&#34;
 xmlns:tns=&#34;http://sample.metro.test/&#34;
 xmlns:xsd=&#34;http://www.w3.org/2001/XMLSchema&#34;
 xmlns=&#34;http://schemas.xmlsoap.org/wsdl/&#34;
 xmlns:soap=&#34;http://schemas.xmlsoap.org/wsdl/soap/&#34;
 xmlns:wsu=&#34;http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd&#34;
 xmlns:wsp=&#34;http://schemas.xmlsoap.org/ws/2004/09/policy&#34;
 xmlns:sp=&#34;http://schemas.xmlsoap.org/ws/2005/07/securitypolicy&#34;
 xmlns:wspp=&#34;http://java.sun.com/xml/ns/wsit/policy&#34;&#62;
 
 &#60;wsp:Policy xmlns:sc=&#34;http://schemas.sun.com/2006/03/wss/client&#34;
  xmlns:wspp=&#34;http://java.sun.com/xml/ns/wsit/policy&#34;
  wsu:Id=&#34;TestService_Security_Client_Policy&#34;&#62;
  &#60;wsp:ExactlyOne&#62;
   &#60;wsp:All&#62;
      &#60;sc:TrustStore wspp:visibility=&#34;private&#34; location=
        &#34;&#60;KEY_DIR&#62;\wsTrustStore.jks&#34;
        storepass=&#34;changeit&#34;
        peeralias=&#34;publicCert&#34;/&#62;

   &#60;/wsp:All&#62;
  &#60;/wsp:ExactlyOne&#62;
 &#60;/wsp:Policy&#62;

 
&#60;portType name=&#34;TestService&#34;&#62;
  &#60;/portType&#62;
 
  &#60;binding name=&#34;TestServicePortBinding&#34; type=&#34;tns:TestService&#34;&#62;
   &#60;wsp:PolicyReference URI=&#34;#TestService_Security_Client_Policy&#34;&#62;&#60;/wsp:PolicyReference&#62;
  &#60;/binding&#62;
 
  &#60;service name=&#34;TestServiceService&#34;&#62;
     &#60;!-- Uncomment this section if above configured security is to be enabled --&#62;
     &#60;!-- --&#62;
  
&#60;port name=&#34;TestServicePort&#34; binding=&#34;tns:TestServicePortBinding&#34;&#62;
   &#60;/port&#62;
  &#60;/service&#62;
&#60;/definitions&#62;
</pre>
<p style="text-align:left;">wsit-client.xml</p>
<pre class="brush: xml;">&#60;?xml version=&#34;1.0&#34; encoding=&#34;UTF-8&#34;?&#62;
 &#60;definitions
 xmlns=&#34;http://schemas.xmlsoap.org/wsdl/&#34;
 xmlns:wsdl=&#34;http://schemas.xmlsoap.org/wsdl/&#34;
 xmlns:xsd=&#34;http://www.w3.org/2001/XMLSchema&#34;
 xmlns:soap=&#34;http://schemas.xmlsoap.org/wsdl/soap/&#34;
name=&#34;mainclientconfig&#34;&#62;
    &#60;import location=&#34;TestServiceService.xml&#34; namespace=&#34;http://sample.metro.test/&#34;/&#62;
&#60;/definitions&#62;
</pre>
<p style="text-align:left;"><strong>Run client</strong></p>
<p style="text-align:left;">To run the client, execute (while command prompt is in &#60;CLIENT_HOME&#62; directory)<br />
<code>java -cp %CLASSPATH%;.;&#60;METRO_HOME&#62;/lib/webservices-api.jar;&#60;METRO_HOME&#62;/lib/webservices-rt.jar test.metro.client.TestServiceClient</code></p>
<p style="text-align:left;">The output will be something like<br />
<code>Oct 2, 2009 11:14:43 AM [com.sun.xml.ws.policy.jaxws.PolicyConfigParser] parseModel<br />
INFO: WSP1049: Loaded WSIT configuration from file: file:&#60;CLIENT_HOME&#62;/META-INF/wsit-client.xml<br />
Greeatings are...<br />
Hello TheTechTips!</code></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Ajax Currency on e-commerce portal]]></title>
<link>http://calverstine.wordpress.com/2009/09/28/ajax-currency-on-e-commerce-portal/</link>
<pubDate>Mon, 28 Sep 2009 14:02:52 +0000</pubDate>
<dc:creator>calverstine</dc:creator>
<guid>http://calverstine.wordpress.com/2009/09/28/ajax-currency-on-e-commerce-portal/</guid>
<description><![CDATA[It&#8217;s long since I last wrote about technology use. I am not a geek on myself but would like to]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>It&#8217;s long since I last wrote about technology use.</p>
<p>I am not a geek on myself but would like to share about my little idea to retreat currency rate from different country via web service using PHP and plug to javascript compiling with the helping hand of mighty j-Query.</p>
<p><strong>Pre-requisites:</strong><br />
1.) I assumed you mater PHP, I assume you master below all.<br />
2.) I have some syntax error and my code are unstructured, if you&#8217;re curiosity could kill a cat, try explore more yourself, ya; I learned that well and until today too.</p>
<p><strong>What you need doing above</strong>:<br />
1.) Internet connection of course.<br />
2.) Apache, php with nusoap.dll enabled if I not mistaken the dll name <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> .<br />
3.) javascript jQuery copy no matter what version.<br />
4.) Price list covered by div / span or any wrapper.<br />
5.) a url http://www.webservicex.net/CurrencyConvertor.asmx?wsdl</p>
<p><strong>Steps:</strong><br />
1.) Do your PHP nusoap to post variable to the 5.) url. Or you can just copy my code below:</p>
<p><strong><span style="color:#339966;">#name this code get-currency.php<br />
</span></strong><strong><span style="color:#339966;">#for a list of currency code refer to this url: </span></strong><a href="http://www.webservicex.net/WCF/ServiceDetails.aspx?SID=18"><strong><span style="color:#339966;">http://www.webservicex.net/WCF/ServiceDetails.aspx?SID=18<br />
</span></strong></a><span style="color:#339966;"><strong>#thanks to W.Lai for this code contributions</strong></span><br />
<span style="color:#339966;">$from = &#8216;MYR&#8217;;$to = &#8216;USD&#8217;;$sUrl = &#8216;http://www.webservicex.net/CurrencyConvertor.asmx?WSDL&#8217;;$client = new SoapClient($sUrl, array(&#8216;trace&#8217; =&#62; 1));$a = $client-&#62;ConversionRate(array(&#8220;FromCurrency&#8221; =&#62; $from, &#8220;ToCurrency&#8221; =&#62; $to));$johnny = $a-&#62;ConversionRateResult;print $johnny;</span></p>
<p><span style="color:#000000;"> 2.) for example now you can retreat this USD currency rate,  you can write a sample html to retreat like below:<br />
<span style="color:#339966;"><strong>/*partial of your html code like below*/</strong></span><br />
<span style="color:#339966;">&#60;div id=&#8221;Price1&#8243; rel=&#8221;230.00&#8243;&#62;230.00&#60;/div&#62;&#60;div id=&#8221;Price3&#8243; rel=&#8221;4500.00&#8243;&#62;4500.00&#60;/div&#62;&#60;select id=&#8221;currencyBox&#8221;&#62;&#60;option value=&#8221;"&#62;Select your currency&#60;/option&#62;&#60;option value=&#8221;USD&#8221;/&#62;US Dollar&#60;option value=&#8221;CNY&#8221;/&#62;Chinese Yuen&#60;/select&#62;<strong>&#60;/html&#62;</strong></span></span></p>
<p><span style="color:#339966;"><span style="color:#000000;"><br />
3.) in your javascript of course you first call jQuery  file, then you configure jQuery  regular expression selector to convert their currency using jQuery base AJAX $.get like below:<br />
<span style="color:#339966;"> &#60;script type=&#8221;text/javascript&#8221;&#62;<br />
$(document).ready(function(){<br />
$(&#8216;#currencBx&#8217;).change(function(){<br />
var val = $this.value;<br />
$(&#8220;div[id^=Prce]&#8220;).each(function(i){$(this).html(&#8216;&#60;i&#62;Loading &#8216;+val+&#8217; currency rate..&#60;/i&#62;&#8217;;});<br />
$.get(&#8216;get-currency.php?from=MYR&#38;to=&#8217;+val,{}, function(data, textStatus){if(textStatus==&#8217;success&#8217;){$(&#8220;div[id^=Prce]&#8220;).each(function(i){$(this).html(parseFloat(data) * parseFloat($(this).attr(&#8216;rel&#8217;)); });}});});});&#60;/script&#62;</p>
<p><span style="color:#000000;"> 4.) Done, then when you use the select box and change the value, it will grab the currency from webservicex and compile the new exchange rate to the screen without refershing, just by this simple code.</span></span></span></span></p>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:81px;width:1px;height:1px;"><span style="white-space:pre;"> </span>$sUrl = &#8216;http://www.webservicex.net/CurrencyConvertor.asmx?WSDL&#8217;;</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:81px;width:1px;height:1px;"><span style="white-space:pre;"> </span>$client = new SoapClient($sUrl, array(&#8216;trace&#8217; =&#62; 1));</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:81px;width:1px;height:1px;"><span style="white-space:pre;"> </span>$a = $client-&#62;ConversionRate(array(&#8220;FromCurrency&#8221; =&#62; $from, &#8220;ToCurrency&#8221; =&#62; $to));</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:81px;width:1px;height:1px;"><span style="white-space:pre;"> </span>$_SESSION['D_CURRENCY'] = $to;</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:81px;width:1px;height:1px;"><span style="white-space:pre;"> </span>$_SESSION['rate'] = $a-&#62;ConversionRateResult;</div>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[思考停止・・・確かに]]></title>
<link>http://kubochin.wordpress.com/2009/09/28/%e6%80%9d%e8%80%83%e5%81%9c%e6%ad%a2%e3%83%bb%e3%83%bb%e3%83%bb%e7%a2%ba%e3%81%8b%e3%81%ab/</link>
<pubDate>Mon, 28 Sep 2009 13:22:00 +0000</pubDate>
<dc:creator>kubochin</dc:creator>
<guid>http://kubochin.wordpress.com/2009/09/28/%e6%80%9d%e8%80%83%e5%81%9c%e6%ad%a2%e3%83%bb%e3%83%bb%e3%83%bb%e7%a2%ba%e3%81%8b%e3%81%ab/</guid>
<description><![CDATA[今日、TwitterのTLを眺めていたら、Mac界の大御所？nobiさんが、日本企業の思考停止具合とともに、その企業環境と社員モチベーションの荒廃具合について言及されていました。まさにその通りですよね]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>今日、TwitterのTLを眺めていたら、Mac界の大御所？nobiさんが、日本企業の思考停止具合とともに、その企業環境と社員モチベーションの荒廃具合について言及されていました。まさにその通りですよね。しかして、その文末に、（以下、引用です）<br />
「前略・・・日本人で活躍してるのは建築家、デザイナー、芸術家、スポーツ選手など組織属さぬマエストロが多・・・」</p>
<p>・・・うぐぐ。い、痛い。<br />
建築家は確かに組織に属してないよな、一般社会的理解では。<br />
マエストロとして？、がんばるにはそうしたそもそもの立ち位置もあるよね、と思った次第。<br />
改めて色々考えさせられました。うんうん。</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[How should you make a Currency Convertor?]]></title>
<link>http://madicemickael.wordpress.com/2009/09/26/how-should-you-make-a-currency-convertor/</link>
<pubDate>Sat, 26 Sep 2009 13:11:35 +0000</pubDate>
<dc:creator>madicemickael</dc:creator>
<guid>http://madicemickael.wordpress.com/2009/09/26/how-should-you-make-a-currency-convertor/</guid>
<description><![CDATA[A smart guy made a very good web service that gives you all the values you need from the BNR (Nation]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>A smart guy made a very good web service that gives you all the values you need from the BNR (National Bank of Romania) , you can use it like I did.<br />
Include e web service reference in your Visual Studio project , then you use a code like this to get all the info you need ,for your project.`<br />
Link to your web service <a href="http://www.infovalutar.ro/curs.asmx?wsdl"> here</a><br />
The code to get the currency is down here:<br />
<a href="http://www.infovalutar.ro/curs.asmx?wsdl">Curs c = new Curs();<br />
double d=c.getlatestvalue(&#8220;eur&#8221;);<br />
Console.WriteLine(d);</a></p>
<p>Have fun using it</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Setting timeout on generated JAXWS CXF Clients]]></title>
<link>http://chamerling.wordpress.com/2009/09/23/setting-timeout-on-generated-jaxws-cxf-clients/</link>
<pubDate>Wed, 23 Sep 2009 14:26:25 +0000</pubDate>
<dc:creator>Kitov</dc:creator>
<guid>http://chamerling.wordpress.com/2009/09/23/setting-timeout-on-generated-jaxws-cxf-clients/</guid>
<description><![CDATA[When generating client with the CXF (2.2.2 in this case, should apply to all&#8230;) Java API withou]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>When generating client with the CXF (2.2.2 in this case, should apply to all&#8230;) Java API without any configuration file, here is the way to set the client timeout :</p>
<pre class="brush: java;">
package org.ow2.petals.kernel.ws.client;

import org.apache.cxf.endpoint.Client;
import org.apache.cxf.frontend.ClientProxy;
import org.apache.cxf.jaxws.JaxWsProxyFactoryBean;
import org.apache.cxf.transport.http.HTTPConduit;
import org.apache.cxf.transports.http.configuration.HTTPClientPolicy;
import org.ow2.petals.kernel.ws.api.RuntimeService;

public class Main {

    private void createService() {
        long timeout = 10000L;
        JaxWsProxyFactoryBean factory = new JaxWsProxyFactoryBean();
        factory.setServiceClass(RuntimeService.class);
        factory.setAddress(&#34;http://localhost:9999/service/Runtime&#34;);
        RuntimeService runtimeService = (RuntimeService) factory.create();

        Client client = ClientProxy.getClient(runtimeService);
        if (client != null) {
            HTTPConduit conduit = (HTTPConduit) client.getConduit();
            HTTPClientPolicy policy = new HTTPClientPolicy();
            policy.setConnectionTimeout(timeout);
            policy.setReceiveTimeout(timeout);
            conduit.setClient(policy);
        }
    }
}
</pre>
<p><em>Note that here the RuntimeService class is my JAXWS annotated class.</em></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Web Service Security]]></title>
<link>http://thetechtips.wordpress.com/2009/09/17/web-service-security/</link>
<pubDate>Thu, 17 Sep 2009 15:33:42 +0000</pubDate>
<dc:creator>thetechtips</dc:creator>
<guid>http://thetechtips.wordpress.com/2009/09/17/web-service-security/</guid>
<description><![CDATA[When considering securing web-service invocations, there are many levels of security that cane be ap]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p style="text-align:left;">When considering securing web-service invocations, there are many levels of security that cane be applied. The outermost levels can be viwed as</p>
<ol style="text-align:left;">
<li>Protocol level security: The security mechanisms used for regular request/response for the particular protocol. For example, Basic Authentication and SSL certificates for HTTP. These mechanisms only ensure that the messages are secured till they reach the protocol (say HTTP) destination. After that, when the actual SOAP message is un secured till it reaches the actual Web service endpoint.<!--more--></li>
<li>SOAP message security: In this case the messages are to be secured all the way to the endpoint beyond the protocol level. This is specified by the WS-Security specifications.</li>
</ol>
<p style="text-align:left;"><strong>WS-Security Specification</strong></p>
<p style="text-align:left;"> </p>
<p style="text-align:left;">The WS-Security specification 1.0 was released in 2002. The next version 1.1 was released in 2006. It specifies how to enhance SOAP messages to secure the information exchange.</p>
<p style="text-align:left;">From the WS-Security specification (http<a href="http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=wss#overview">://www.oasis-open.org/committees/tc_home.php?wg_abbrev=wss#overview</a>):</p>
<p style="text-align:left;">&#8220;WS-Security describes enhancements to SOAP messaging to provide quality of protection through message integrity, message confidentiality, and single message authentication. These mechanisms can be used to accommodate a wide variety of security models and encryption technologies.”</p>
<p style="text-align:left;">The WS-Security spec provides SOAP extensions that can be used when building secure web-services. There are three main aspects of security:</p>
<ol style="text-align:left;">
<li><em>Message Authentication</em>WS-Security provides a way of associating <em>security tokens</em> with SOAP messages. These tokens (like Basic Authentication or SSL certificates for HTTP) can be used to identify the sender of the message. The specification does not require use of any particular token. Two commonly used tokens are <em>Username </em>tokens and <em>X509</em> tokens. Other tokens like <em>Kerberos</em> tokens can also be used. These tokens can be included directly in the <em>SOAP message header</em>, or an indirect reference to the token can be sent using digital signature or encryption.</li>
<li><em>Message Integrity </em>Message integrity ensures that the message was not tampered with on its way from the sender to the receiver. WS-Security provides a way to include <em>XML digital signatures</em> in the <em>SOAP</em> message <em>header</em> to help verify integrity. Exactly what parts of the message are signed or what digest/algorithms are used is left to be decided by the web-service provider.</li>
<li><em>Message Confidentiality</em>Message confidentiality means that on the wire, the message should not be readable. WS-Security specifies how the full message or parts of the message can be encrypted and sent so that they are unreadable to attackers. This will use <em>XML encryption</em> and the encryption related information is exchanged in the <em>SOAP</em> <em>header</em>. Either the whole message can be encrypted (like <em>HTTPS</em> transport encryption), or <em>parts</em> of the message are encrypted. Again, the encryption algorithms to be used, the way of exchanging keys (or tokens) is to be decided by the web-service provider.<span id="_marker"> </span></li>
</ol>
<p style="text-align:left;">In the next post, I am going to create a secure web services using JAXWS implementation Metro and create client for the service. Explaining the various types of security in more detail.</p>
</div>]]></content:encoded>
</item>

</channel>
</rss>
