Building SL4 + RIAServices app takes too long on VS2010 - silverlight

Got a Win7 box with VS2010 Premium installed on it.
Building desktop apps works just fine.
But we got this solution with 15 SL4 and 21 desktop projects... Building the SL part of it takes too long. This is very irritating and encourages to drop TDD since every time I run a test it takes ~3 seconds for msbuild to find out that nothing changed and the project should be skipped. The projects are very small and there's nothing fancy in them and we hadn't any problems before we switched from VS2008+SL3.
I've heard people complaining abound VS2010 speed in general, but nothing about SL4 build time.
Is anyone experiencing same problems and is there any workaround for this?

Do you need that many projects? As a rule of thumb, less is better. You say that the projects are very small, that would be an indication to me that you probably don't need that many.
Don't use it for managing dependencies (cycle avoidance). If you're trying to manage 'units of development' or logical groupings, use namespaces instead.
Physical/project separation is good for keeping test code out of production code, and managing units of deployment, but don't separate it until you're getting something out of it.
Patricks Smaccia wrote a good article on when and when not to create assemblies.
Another way to tackle the problem is to break your solution up into multiple solutions, and
use references to the dlls produced by the other solutions. That way, you only build part of it at a time. If you need to work across many dlls at the same time, this is inconvenient, but it's a sign that something is likely to be wrong with the design of your code.
This post on speeding vs.net up with many projects may also help.

Related

How to create a setup of an Windows application using PowerBuilder

I am a newbie for PowerBuilder and for Windows application. I have few projects which consists corresponding code in it and after merging all that I get the final product. The problem I am facing right now is that I don't know how to make a setup of my Windows app using PowerBuilder. If I can get step by step procedure with tiny explanation, I will be able to achieve it already. Have tried Google but ended up with complex confusion. I have created the .exe, but that .exe does not work on any other computer. So please guys help me out.
Thanks
There are two parts to creating a setup program for your application: defining the files and other resources that need to deployed, and building those resources into a setup executable package.
For defining files and resources, you've made it impossible for anyone to even take a shot by referring to two very different (but similar origins) versions of the product in your tags: PowerBuilder (aka PowerBuilder Classic) and PowerBuilder.NET. The deployment requirements for apps built from each of these is very different. However, even if we knew, the best advice is to go through the manuals and review what is required of the features of your specific application. (e.g. if you don't use rich text, deploying the files required to support it would be a waste). A generic list is, IMHO, just bad advice.
As far as building a setup package goes, the first decision is which package building software to pick (none comes with PowerBuilder). Any Windows setup package builder should do. I've used InstallShield and Inno, vastly preferring the latter (after many years of using the former). I know you want steps to walk you through, but a walk through is impossible before picking the software, and frankly, walk throughs of these setup building software has been done elsewhere much better than I'd do.
The bottom line is that the answer isn't as simple as you seem to have been hoping, but it is attainable.
Good luck,
Terry.

How to improve Silverlight development process productivity of UI & MVVM in particular

I am currently developing for Silverlight 4.0 and after mostly creating class libraries with TDD in usual C# (before SL) I can say that my current process is way slower than I am used to. (I think this can be said about any UI code compared to library classes, but here I think its really serious issue for me.)
I am wondering what techniques can be recommended to increase SL development performance.
I am mainly concerned about hard to test code (from my POV) - MVVM & UI - what can be done to improve performance here, I am thinking maybe theres a way to use a smaller sandbox somehow and test/debug control behaviour outside of scope of whole application, its pretty clear to me that me running whole application to test whether a new dialog box works correctly isnt fastest way and I could improve performance if I had a way to test this dialog alone for example, and there are probably other ways I cannot think of that can be a solution too.
EDIT: 1)here is something that I found useful , for TDD there is now a project that allows console runner to run tests so you dont have to run silverlight tests in browser & can integrate in your build process LightHouse
2) found following page, it provides some idea about a possible approach one could use to test view:
http://fohjin.blogspot.com/2008/09/how-to-test-your-xaml-behavior-using.html
there is no magic beautiful way and this one can be utilized but having to name all controls for example is a must to get this to work which isnt very good often
Statlight for the build server.
AgUnit to allow resharper to run silverlight tests.
WebAii for automation testing.
I'm not a fan of SLUT, as to run an individual test you have to cut and paste its name, and it doesnt remember it until you let it run all the way through, which I rarely do if I'm debugging.
Have you tried to use slut?
http://archive.msdn.microsoft.com/silverlightut
she will do what you want and pretend she enjoys it

Dxscene and VGscene with Delphi

I am using delphi as my primary development tool.
and recently I found these 2 libraries in KSDEV.com
and i found they are similar to WPF . So i just downloaded them and stated to playing with them until the time to end comes ( i have not checked its license policies yet). I am not a good WPF knowledge person but i found was WPF hard to develop.
But my doubt is , are these 2 libraries can replace WPF in delphi . what are the drawbacks Dxscene and VGscene have or what are the drawbacks WPF have ,
There are only a little articles about them in internet (google gave me millions of results but most of them repeated 2 articles which was published in KSDEV)
VGScene and DXScene can be compaired to WPF for the rendering result.
I think VG/DXScene are less resource consuming, and what I like against WPF, is that they are not XML-based.
You use regular Delphi components to define your UI.
But the learning curve and the documentation is still a bit lacking for VX/DXScene.
I found out to be a bit difficult to create forms with DXScene. VXScene is perhaps a bit easier to create your UI with the mouse.
I think the full power of these libraries will be obtained using code-generated UI.
I don't like the XML root of WPF. It's verbose, and difficult to work with, with real application with a lot of forms. For some projects, the external WPF designer could be necessary.
But don't ask Microsoft why they don't publish WPF-based applications... and they still use unmanaged code...
VgScene and DxScene are really cool libraries! You can make fast and nice looking GUI's with all kind of effects. It also has a grid component now!
But when I tried using them, I encountered some "drawbacks": there is little documentation how to make and what to use for a complex GUI (there are some nice demo's for simple GUI's though). So it has a relative high learning curve (when you only have VCL knowlegde because it is very different).
But besides these things, I think it is worth trying (only if you know how to do it and/or spend some time learning). It has good platform support (via FPC and OpenGL) so you can run it also on MacOs, Linux and iPhone/iPad!
Since they do not depend on WPF, they can be used for cross platform development in Lazarus/CodeTyphon. That is the main advantage for me. Drawback is documentation.

How to write a Large WinForms application?

I'm going to write a rather big/complex WinForm application such as Paint.NET, SharpDevelop, etc. I think one of the most important things to build such an application is to structure the project properly to increase maintainability and control the complexity.
So what kind of patterns or practices show I use? Any blog posts, papers, open source projects are welcomed. I'm trying to learn something from SharpDevelop but it's rather huge for me to step into.
PS: I'm an experienced programmer formerly targeting to web developement(asp.net, rails, etc.). So I know some design principles and how to use them when implement business logics. Maybe I really need now is a sample to get started with a WinForm application so that I can realize how to handle the menus, controls and others. I've learnt something about the MVP pattern but still unconfident to start a large/complex application.
For big projects the methodology and the tools you are using are equally as important as the architectural design. You need to set up a source control system (like SVN) from day one. Also, it is very good to have a standard build procedure and perform builds in a daily basis. The build procedure should include running all tests, which you should also put some effort in implementing from the start.
Regarding the structure, I believe the single most important thing is to divide your project into building blocks with mimimal dependecies on each other. This way you will be able to think about one small part of the system at the same time and not have to face the full complexity of it. It will also help delegate some work to a fellow programmer, if you have this chance.
In order to get started, I recommend that you implement first something minimal as quick as possible. Then work to make it better and add functionality. This will keep you motivated as you will have something concrete to work with. It will also help you identify major design flaws and important issues early enough to correct them.
This is a good beginners guide from Microsoft itself:
http://msdn.microsoft.com/en-us/beginner/default.aspx
check the Windows track there.
After mastering basics - and since you are an experienced developer - you can check this book "patterns & practices Application Architecture Guide 2.0" from Microsoft also.
I would imagine that many of the techniques that make for successful web projects will translate to Winforms projects. Start small and grow the application incrementally. Try to keep the entire application building/working while you add features one at a time.

Interface Architecture for Silverlight App

I'm getting ready to develop my first Silverlight app. It is going to be primarily used by my church for data input but also will need to generate at least one report, ideally in Excel but XML/XSLT is not outside the realm...
It will be Internet facing and will talk to a SQL Server 2008 db for which I will be creating a web service hosted at the ISP (db is also hosted at the ISP). The clients will be a mix of Windows and Mac.
My question specifically relates to the interface architecture. I know MVVM is big for this right now and I'm comfortable with that. I want to get this up fairly quickly (ie- next 3-4 weeks). I've also seen mention of Prism (Composite Application Guidance) and Caliburn. What are anyone's thoughts on these two? The initial version of the app is not going to be huge so I don't imagine it would be overly difficult to refactor a framework into it at a later date.
You are right, if it's your first development on SL, adding the complexity of MVVM won't help you much.
I think a good approach could be to go for something simple (e.g.: the good old Document/View could be just a good start http://msdn.microsoft.com/en-us/library/4x1xy43a(VS.80).aspx, or just breaking in standard layers, UI / BS / DL).
After that development you will have learnt a lot of good stuff, and then you will be able to throw your app and start new bigger challenges using more advanced architectures (about MVVM, a very good web cast: http://blog.lab49.com/archives/2650 it's WPF based most of the concepts can be ported to SL).
Good luck and enjoy for SL development.
Cheers
Braulio
Start with something you are very comfortable with especially if you need to get this up quickly. Follow good coding standards and should not be a problem to refactor later into other frameworks if you get a bigger team.
This is a useful pdf.
I haven't read it in detail yet myself, but this article looks rather useful:
RIA Architecture with Silverlight in mind

Resources