tag:blogger.com,1999:blog-14324579796641594292024-03-10T20:13:12.455+01:00MSE-iT - Software DevelopmentObject oriented application development on top of the Microsoft .NET 3.5 Framework. With a special focus on object persistence and ORMThomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.comBlogger13125tag:blogger.com,1999:blog-1432457979664159429.post-25060049394101424612009-08-24T16:40:00.003+02:002009-08-24T16:52:24.209+02:00lc.exe exited with code -1 and how to fix itLC.EXE is the Visual Studio license compiler. It compiles licenses and includes them in the assembly resources. The license compiler returns -1 when a licensed component is removed.<br /><br />Fix:<br />Under the <span style="font-style: italic;">Properties</span> Folder in the Project folder you find the file <span style="font-style: italic;">licenses.licx</span>. You must open this file and remove the reference to the component. And you must remove the Reference in the assembly references as well. After that the project will compile without an error.Thomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.com14tag:blogger.com,1999:blog-1432457979664159429.post-58991781799354614572009-02-22T13:06:00.003+01:002009-02-22T13:17:36.442+01:00Spell checking and Hypenation- the .NET way of HunspellOn our homepage i use a .NET based CMS which is able to hyphenate the text with soft hyphens (SHY). I've used a large dictionary for this, but i want to improve this a little. If you google spell checking and hyphenation you fill find sooner or later Hunspell. Hunspell is the spell checker used in <a href="http://www.openoffice.org/">OpenOffice </a>and <a href="http://www.mozilla.com/">Mozilla Firefox 3 & Thunderbird</a>.Unfortunally this is C and C++ code and not .NET. So i looked at the library and see it is only x86 and ugly to marshall. The simple PInvoke way was obstructed.<br /><br />I decided to use managed C++ to port this code to .NET and implement a proxy patetrn to use the original code wih only little modifications. I've hosted this project on Sourceforge and gave it the name NHunspell for .NET Hunspell. This is the project URL:<br /><a href="http://nhunspell.sourceforge.net">http://nhunspell.sourceforge.net</a><br /><br />Hunspell is tri licenced under GPL/LGPL/MPL, and NHunspell follows this. If you nedd a spell checker for the :NET plattform you can give it a try.Thomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.com16tag:blogger.com,1999:blog-1432457979664159429.post-52862164069201454572009-01-22T00:26:00.004+01:002009-01-22T10:48:42.234+01:00Web Application Stress TestOk, sometimes i regret having windows vista 64Bit on my development machine. An today was such a day. I tried to set up a web stress environment for our new web portal. <br /><br />I tried several great tools like OpenSTA and WebLoad to run on my Windows Vista, but nothing worked. The i downloaded quite angry the good old Web Application Stress tool from Microsoft and run it as admin. And it works. <br /><br />Our new Portal has its business logic on a .NET based windows service, so i want to test interprocess communication via WCF and a named pipes channel. The WAS tool works great for this and i could tune my IPC to get a throughput of about 80 pages per second. I think this isn't so bad for WCF. But i try to become better.<br /><br />Addition: <br />I've used a channel pool for my wcf channels ad come now to 1000 / pages per second. A roundtrip of a simple function ( bool Test(bool foo ); ) need about 50uS on a named pipes channel. The processing of the on the IIS takes much longer. For now the things have become right. I can place the business logic on the app server and get a killer throughput because of efficient caching. This is the way i like web applications.Thomas Maierhoferhttp://www.blogger.com/profile/02100476670558752733noreply@blogger.com24tag:blogger.com,1999:blog-1432457979664159429.post-54994221460768355852009-01-18T01:07:00.004+01:002009-01-18T01:16:04.505+01:00Launch of new Web portal: Urlaub und Reisen Profis.deWe have launched the development of a new web portal for travel agencies. It is hosted on origo a the ETH Zurich in Swizzerland. This project is the first big test for our new web technologies. It is programmed in C# with the .NET 3.5 Framework.<br /><br />Project URL:<br /><a href="http://urlaub-und-reisen-profis.origo.ethz.ch/">http://urlaub-und-reisen-profis.origo.ethz.ch/ </a><br /><br />Origo is a great hosting site for open and closed source projects.<br /><br /><br /><br /><div id="seolinx-tooltip" style="border: 1px solid rgb(0, 0, 0); margin: 0pt; padding: 0pt; display: none; opacity: 0.9; position: absolute; width: auto; z-index: 99999;"><table style="border: 0pt none ; margin: 0pt; padding: 0pt; border-collapse: separate; width: auto;"><tbody><tr><td id="seolinx-table" style="border: 0pt none ; margin: 1px; padding: 0pt; font-family: Tahoma; font-size: 11px; font-weight: bold;"><div style="margin: 0pt; padding: 0pt; overflow: auto; width: auto;"><table id="seolinx-paramtable" style="border: 1px solid gray; margin: 0pt; border-collapse: separate;"><tbody><tr><td style="border: 1px solid gray; padding: 2px; background: rgb(240, 240, 240) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; color: darkgreen; font-family: Tahoma; font-size: 7pt; font-weight: bold; white-space: nowrap;"><img src="http://toolbarqueries.google.com/favicon.ico" style="vertical-align: middle;" width="12" height="12" /> PR: <a style="color: blue; font-family: Tahoma; font-size: 7pt; font-weight: bold; text-decoration: underline;" index="0" type="param" title="Google pagerank" href="javascript:{}">wait...</a></td><td style="border: 1px solid gray; padding: 2px; background: rgb(240, 240, 240) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; color: darkgreen; font-family: Tahoma; font-size: 7pt; font-weight: bold; white-space: nowrap;"><img src="http://www.google.com/favicon.ico" style="vertical-align: middle;" width="12" height="12" /> I: <a style="color: blue; font-family: Tahoma; font-size: 7pt; font-weight: bold; text-decoration: underline;" index="1" type="param" title="Google index" href="javascript:{}">wait...</a></td><td style="border: 1px solid gray; padding: 2px; background: rgb(240, 240, 240) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; color: darkgreen; font-family: Tahoma; font-size: 7pt; font-weight: bold; white-space: nowrap;"><img src="http://www.google.com/favicon.ico" style="vertical-align: middle;" width="12" height="12" /> L: <a style="color: blue; font-family: Tahoma; font-size: 7pt; font-weight: bold; text-decoration: underline;" index="2" type="param" title="Google links" href="javascript:{}">wait...</a></td><td style="border: 1px solid gray; padding: 2px; background: rgb(240, 240, 240) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; color: darkgreen; font-family: Tahoma; font-size: 7pt; font-weight: bold; white-space: nowrap;"><img src="http://siteexplorer.search.yahoo.com/favicon.ico" style="vertical-align: middle;" width="12" height="12" /> LD: <a style="color: blue; font-family: Tahoma; font-size: 7pt; font-weight: bold; text-decoration: underline;" index="12" type="param" title="Yahoo linkdomain" href="javascript:{}">wait...</a></td><td style="border: 1px solid gray; padding: 2px; background: rgb(240, 240, 240) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; color: darkgreen; font-family: Tahoma; font-size: 7pt; font-weight: bold; white-space: nowrap;"><img src="http://search.msn.com/favicon.ico" style="vertical-align: middle;" width="12" height="12" /> I: <a style="color: blue; font-family: Tahoma; font-size: 7pt; font-weight: bold; text-decoration: underline;" index="20" type="param" title="MSN index" href="javascript:{}">wait...</a></td><td style="border: 1px solid gray; padding: 2px; background: rgb(240, 240, 240) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; color: darkgreen; font-family: Tahoma; font-size: 7pt; font-weight: bold; white-space: nowrap;"><a style="color: blue; font-family: Tahoma; font-size: 7pt; font-weight: bold; text-decoration: underline;" index="40" type="param" title="Sitemap.xml" href="javascript:{}">wait...</a></td><td style="border: 1px solid gray; padding: 2px; background: rgb(240, 240, 240) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; color: darkgreen; font-family: Tahoma; font-size: 7pt; font-weight: bold; white-space: nowrap;"><img src="http://siteanalytics.compete.com/favicon.ico" style="vertical-align: middle;" width="12" height="12" /> C: <a style="color: blue; font-family: Tahoma; font-size: 7pt; font-weight: bold; text-decoration: underline;" index="108" type="param" title="Compete Rank" href="javascript:{}">wait...</a></td><td style="border: 1px solid gray; padding: 2px; background: rgb(240, 240, 240) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; color: darkgreen; font-family: Tahoma; font-size: 7pt; font-weight: bold; white-space: nowrap;"><img src="http://seodigger.com/favicon.ico" style="vertical-align: middle;" width="12" height="12" /> SD: <a style="color: blue; font-family: Tahoma; font-size: 7pt; font-weight: bold; text-decoration: underline;" index="112" type="param" title="Seodigger" href="javascript:{}">wait...</a></td></tr></tbody></table></div></td><td style="border: 0pt none ; margin: 0pt; padding: 1px; cursor: pointer; vertical-align: middle; width: auto;" id="seolinx-tooltip-close" title="close"><img src="chrome://seoquake/content/skin/close.gif" /></td></tr></tbody></table></div>Thomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.com98tag:blogger.com,1999:blog-1432457979664159429.post-9823853103126681992008-12-10T14:03:00.003+01:002008-12-10T14:14:11.800+01:00UPS Update killed our web serverOur web hoster (big German hosting company) has updated his UPS today and killed our web servers. Therefore our servers are down. They (hopefully) fix this today. This is quite annoying, because we had a DDos Attack last month. That shows again the vulnerability of Internet based systems.Thomas Maierhoferhttp://www.blogger.com/profile/02100476670558752733noreply@blogger.com121tag:blogger.com,1999:blog-1432457979664159429.post-53174217272080516792008-12-04T23:21:00.003+01:002008-12-04T23:34:26.734+01:00MSE-iT Setup Bootstrapper first DemoI've just released a small demo, with only two pages. The background and the software box are merged together with the new support of 32bit bitmaps with alpha channel.<br /><br />The background drawing consists of four overlapped bitmaps:<br /><ol><li>dialog background bitmap<br />It displays the general background and the logo. Alle background elments who are immutable.</li><li>page background bitmap<br />It displays the background for a page. It is alpha blended over the dialog background, and contains only the additional elements for the page background</li><li>dialog background localized bitmap<br />It displays text and other things, which are different for every language, but immutable for the dialog.<br /></li><li>page background localized background<br />It displays text and other things, which are different for every language and page.</li></ol>You can download and test the bootstrapper here: <br /><a href="http://www.codeplex.com/MseItSetupBootstrap">MSE-iT Setup Bootstrapper</a>Thomas Maierhoferhttp://www.blogger.com/profile/02100476670558752733noreply@blogger.com4tag:blogger.com,1999:blog-1432457979664159429.post-83169795427660018812008-11-29T00:39:00.006+01:002008-11-29T00:48:57.364+01:00MSE-iT Setup Bootstrapper is now open sourceEver installed a .NET application? Windows Installer XML (WiX) is really great to develop your MSI packages. But what if the user hasn't installed the .NET Framework oder some other prerequisites? Then you need a bootstrapper! A bootstrapper is a program, mostly SETUP.EXE that does the dirty job for you. But you can't develop a bootstrapper in C#, because of the missing .NET Framework. MSE-iT has a nice bootstrapper written in C++ with a very small footprint. We will use this for our brand new accounting software for travel agencies. And i will provide it to the community:<br /><br />Project on CodePlex:<br /><a href="http://www.codeplex.com/MseItSetupBootstrap">MSE-iT Setup Bootstrapper</a><br /><br />The project is in Setup stage, it will be available in a view days.Thomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.com6tag:blogger.com,1999:blog-1432457979664159429.post-53126942424513809792008-11-25T13:52:00.003+01:002008-11-25T14:17:07.459+01:00Project MSE-iT Upgrade Framework startsAs mentioned in previous posts, i want to have a declarative way to tag upgrades in code. After some research i came to conclusion that this can be separated in a own library or framework. It should bring a generalized form to tag upgrades to a object model. Any object persistence implementation can use this framework to generate upgrades and downgrades of persistent data.<br /><br />To put it simply: The framework expresses an upgrade and an downgrade path for a type:<br />Upgrade("TypeName") -> List<actionstoupgrade><br />Downgrade("TypeName") -> List<actionstodowngrade><br /><br />The backup and sync provider can use this list to perform the real actions on the datastore. Of course this methods don't exist because real world upgrade scenarios are more complex. I will publish the real API on first release. <br /><br />The project will be hosted on CodePlex, open source, GPL licensed and is currently in setup state. Hiere is the Project: <a href="http://www.codeplex.com/MseItUpgrade/">MSE-iT Upgrade Framework on CodePlex</a> But for the moment, it is not published. I will post when i check in the initial development.Thomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.com7tag:blogger.com,1999:blog-1432457979664159429.post-72804386705246506392008-11-21T16:37:00.002+01:002008-11-21T16:48:10.333+01:00DDoS Attac on InterNetX nameserversOur servers and this blog was down because of a DDoS attack on our domain registrar InterNetX. That shows again the vulnerability of Internet based applications and the importance of a distributed infrastructure. I'll continue working on synchronization issues, to protect systems against this.Thomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.com18tag:blogger.com,1999:blog-1432457979664159429.post-20021216678136247112008-11-16T21:41:00.004+01:002008-11-16T22:30:44.149+01:00jQuery backgroundCanvas updateDo you know jQuery? It is a famous JavaScript framework for DOM manipulation.<br /><br />It was turn of the year 2007/2008, i asked about design possibilities for our new homepage. Because our new software has a "Office 2007 Ribbon", i want to have round corners, gradients and a fluent layout. Staff members told me, this is impossible because you cannot have scaling background gradient images in CSS. And if we will clutter the html markup with layouting DIVs, we will be ranked badly by Google. I thought: Search engine optimization is important, this argument strikes. But i don't want to give up, therefore i looked in my spare time after other solutions. I was new in web developement and everybody told me, that i wouldn't find something. Ok, the web pros know what they talk about? Or not:<br /><br />I found an interesting HTML element, which brings the solution: The canvas. Inserting a canvas object in the web page and drawing on it gives all the possibilities i want to have. I've developed a jQuery plugin for this in my spare time and it is great. Look at my private homepage: <br /><a href="http://www.maierhofer.de/BackgroundCanvas.htm">jQuery backgroundCanvas plugin</a><br /><br />I've just moved the source to Goggle Code and updated it. It is licensed under LGPL and easy to use.Thomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.com7tag:blogger.com,1999:blog-1432457979664159429.post-47650846044468232712008-11-11T10:48:00.004+01:002008-11-11T13:54:51.242+01:00Upgrade path declaration for automatic upgrade and downgrade of persistent dataIn persistence frameworks peer synchronization and restore of backups requires knowledge about older versions. To follow the SCSE pattern from x-tensive upgrade paths should be declared in the object model.<br /><br />If the domain-model changes, it is in general necessary to upgrade the clients too. In windows installer terms, these kind of upgrades are called "major upgrade", because the change of the model will almost always break the interoperability to related assemblies. <br /><br />Important: The term "major upgrade" has nothing to do with the version numbering schema of assemblies which has a major version and minor version. But a major upgrade should have at least a minor version number upgrade.<br /><br />An upgrade path is a linear path along major upgrades (releases):<br /><pre>V1.1.x -> V1.2.x -> V2.0.x -> V2.1.x -> V2.2.x</pre>There are at least six primitive upgrade operations:<br /><ul><li>persistent class added</li><li>persistent class renamed</li><li>persistent class removed</li><li>persistent field added</li><li>persistent field renamed</li><li>persistent field removed</li></ul>To declare this, three attributes are announced:<br /><ul><li>RelAdded for adding a class or a field<br /></li><li>RelRenamed for renaming a class or a field</li><li>RelDeleted for deleting a class or a field</li></ul><br /><br />This is an example of a class with release attributes: <br /><pre name="code" class="C#"><br />[assembly: RelGroup("MseIt.Persistency.UnitTests")]<br />[assembly: RelDeleted("MseIt.Persistency.UnusedClass", Release.B_0_2)]<br /><br />namespace MseIt.Persistency<br />{<br /> static public class Release<br /> {<br /> public const int B_0_1 = 1;<br /> public const int B_0_2 = 2;<br /> }<br /><br /> [Sync]<br /> [RelAdded(Release.B_0_1)]<br /> [RelRenamed("MseIt.Persistency.UpdatedClass",Release.B_0_2)]<br /> [RelDeleted("Payload",Release.B_0_2)]<br /> class UpdatedEntity : SyncEntity<br /> {<br /> [Field]<br /> [RelAdded(Release.B_0_1)]<br /> public string Payload1 { get; set; }<br /><br /> [Field]<br /> [RelAdded(Release.B_0_2)]<br /> public string Payload2 { get; set; }<br /> }<br />}<br /></pre><br /><br />A upgrade path is extractable from this declarations. So a automatic upgrade can be performed on restoring old data or synchronizing with peers having previous versions.<br /><br />Additionaly it is a nice documentation which modifications are done on a specific release. External tools could check this update information for consistency.Thomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.com2tag:blogger.com,1999:blog-1432457979664159429.post-81463626505101496512008-11-07T17:03:00.005+01:002008-11-07T18:39:11.604+01:00The need for a unique Syncronsation, Update and Backup in Persistence FrameworksLong time ago I've head the idea of combining the synchronization issues, backups and the update process together. Our application for travel agency accounting is based on a SQL Server and installed in hundreds of travel agencies in Germany. About one third uses SQL replications to synchronize data with their branch offices or for telework.<br /><br />Now we need solutions for the following problems:<br /><ul><li>The sql servers connected via replications must be updated together</li><li>Software upgrades requires downtime of the application<br /></li><li>Restoring an old backup of the data requires an upgrade of the SQL database<br /></li><li>Crash of the consolidated database requires a complete regeneration of the replication from one of the remote databases</li><li>Crash of the remote database requires generating a new database from the consolidated database</li><li>And so on...</li></ul>With the new system we want:<br /><ul><li>Upgrade our product with no downtime</li><li>Upgrade branch offices and teleworkers step by step with no downtime</li><li>Restore backups of old versions with automatic upgrade</li><li>Restore a backup in a branch office and synchronize it to the head office</li><li>synchronize between branch offices if the head office becomes unavailable (peer sync)</li></ul>This could only be reached, if we put the upgrade and synchronization layer in the business logic. This is the goal for the synchronization, backup and upgrade framework on top of the famous DataObject.NET 4.0 from x-tensive.Thomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.com2tag:blogger.com,1999:blog-1432457979664159429.post-58713848190131985362008-11-06T14:50:00.006+01:002008-11-06T17:31:57.782+01:00Switch to the persistency framework Data Objects.NET 4.0Long time ago I've decided to use <a href="http://www.x-tensive.com/">DataObjects.NET</a> as ORM framework. The content management of our company homepage <a href="http://www.mse-it.de/">www.mse-it.de</a> relies soley on it. It also uses some JQuery plugins for layouting. You can find them on my private homepage under <a href="http://www.maierhofer.de/JQueryProjects.htm">JQuery Projects</a>.<br /><br />A view months ago they announced the new 4.0 version. It is licenced under GPL and comes along with some propertiary licence models. It is a awesome framework, with goundbreaking changes to any ORM i know.<br /><br />But i miss some important things:<br /><ul><li>Syncronsiation or replication like SQL - but on the level of business objects</li><li>Update and upgrade support</li><li>Backup and resorte support </li></ul>So i've decided to use syncronsation and distribution knowledge from our software for travel agencies (comes with replication, backup update and so on) and build a framework for it that is able to:<br /><ul><li>Syncronize</li><li>Backup</li><li>Deploy</li></ul>In the moment i am working on syncronisation and update issues. Because x-tensive follows the "sorce code is source of everything" (SCSE) pattern, i will do too.<br /><br />Here is a sample class form my NUnit tests:<br /><br /><pre name="code" class="C#"><br />[Sync]<br />class TestEntity : SyncEntity<br />{<br /> [Field]<br /> [RevAdd(Rev.B_0_1)]<br /> public string Payload { get; set; }<br /><br /> [Field]<br /> [RevAdd(Rev.B_0_1)]<br /> [RevRenamed("FieldNoSync",Rev.B_0_1)]<br /> [SyncVersionNoUpdate]<br /> public string FieldWithSyncVersionNoUpdate { get; set; }<br /><br /> public string NoFieldProperty<br /> {<br /> get { return ""; }<br /> set {}<br /> }<br />}</pre><br />The RevXXX (Revision) attributes will tell the framework when a property is introduced, deleted or the name changed. So the backup and synchronization layer can automatically do the necessary transformations between the versions.Thomas Maierhofer - MSE-iThttp://www.blogger.com/profile/02456253906194393812noreply@blogger.com13