Archive for category Quaility

The LinqDataSource and the Hidden Viewstate

Yesterday I thought I’d learn about the LinqDataSource in ASP.Net 3.5, and got an interesting surprise.

The new LinqDataSource can also be used with a LINQ-to-SQL model to perform updates. You simply add the DataSource to your page, set the table name, and set EnableUpdate to true. Then, using a standard DataControl, you can make updates to your data entities.

The question is, how does this work? It appears to be a bit magical. Read the rest of this entry »

, , ,

2 Comments

Efficient Software Development with Visual Studio Team System 2008

I was recently asked to do some research and give a presentation about using Visual Studio Team System 2008. I thought I’d experiment with Slideshare.net and post it here.

[slideshare id 225505&doc=efficient-software-development-with-visual-studio-team-system-1200133974226602-2&w=400]

The presentation was for a large corporation, and will possibly not come across as being very useful for an online presentation. I have been working on it for a while though, and I think it’s worth publishing, if only as an introduction.

I’ve used competitive products to Team System for a long time, mainly open source:

  • SubVersion for source version control
  • CruiseControl.Net as a build server
  • NAnt for build scripts
  • MbUnit for testing
  • NCover for seeing my testing code coverage
  • VersionOne for project planning, task management, tracking and reporting
  • BugTracker for bug tracking
  • A Wiki for project documentation and guidelines

I wasn’t all-too impressed with the standard of Visual Studio Team Suite 2005, but I am a little bit happier with the 2008 version. It took a while to get it installed so that I could test it, and there were lots of seemingly undocumented points which hindered my progress, but once I’d got it up-and-running, I didn’t find it that bad. (I did have to install it on  virtual machine, and run it on my laptop.)

I think the best thing about Team System is that all the things I need to do are now integrated into one place. I didn’t have to go make changes to a dozen XML files in order to get a build server working. I didn’t have to install a Wiki for the project documentation. Using Team System would also avoid resistance to using the products, as I’ve faced before trying to get other team members to use such tools. Everything would just be there, out-of-the-box, and no one would argue about using them.

What I didn’t like about Team System are some of the subtle details which don’t work as they should do. I did a basic test of multiple check-outs, using the new features, but it didn’t work. The Unit Tests that I generated were confusing and were buggy.

The biggest problem though is the price. It’s darn expensive. I wouldn’t be able to afford Team System if I was just a small development shop. However, for a large corporation, it really could make sense.

I actually wonder if there’s room for a better competitor (Rational is possibly the only serious contender, and I find their software pretty naff). It actually wouldn’t to be too hard for some Python hackers somewhere. 🙂

1 Comment

Are you keeping up with software development?

DotNetRocks, the internet talkshow for .Net developers, has a great show about development changes over the past 20 years. Carl Franklin interviews Kathleen Dollard, who has put a list of changes together, and is publishing them online.

If you want to know where you currently stand in your software development, you want to listen to this show. You might even want to take notes.

If you are recruiting developers, you also should listen to this show. You could use very effectively it to find out what kind of people you are interviewing.

The first 10 of 60 items on Kathleen’s list of changes are:

  1. Parallel entities
  2. N-Tier
  3. Sheer magnitude
  4. Application code generation
  5. SOA (Service Oriented Architecture)
  6. Semantics and canonical messages
  7. Workflow
  8. Rules engines
  9. Aspect oriented programming
  10. Impact of libraries

Every software developer or architect should know at least a little about each item on this list. If you don’t, maybe you could use this to pull your career up a level.

No Comments

Qualities of a .Net Application Design

I’m often asked to produce design documents for new applications. I can’t do this without discussing the advantages and disadvantages to each part of the design. A great way to do this is to focus on the desired qualities of the system you’re trying to build. Define the qualities you are trying to achieve, and design each part of the system to match those qualities as best as possible.

It helps to have a list of things to consider. Here’s a list of some of the qualities you need to address for a .typical Net application:

Development-Time Qualities

  • Modifiability – (Often called “flexibility“, and especially important for agile development.) How easily can the software be modified to additional requirements and changes? Can changes be localized to as little code as possible? Do public interfaces have to change? How are the parts of the application dependent on one another? Are the most-likely-to-change areas of the application depended upon to be stable? To what extent are concerns separated?
  • Reusability – Can units of the application be reused elsewhere? Does the code fit the “DRY” principle (Don’t Repeat Yourself)? Does the system make good use of existing standards? Reusing code from other frameworks and systems can help keep testing and maintenance down, but reduce modifiability.
  • Portability – Could the system be easily ported to other platforms? This is often not an issue for most enterprise applications, as business requirements typically change more frequently than the technical platforms, and the .Net framework takes care of most of the issues. For a web application, portability could also include browser compatibility. What happens if the users suddenly receive an upgrade to their browsers?
  • Testability – How easy is it to prove that the application functions correctly, and that the various parts of the application do what they are supposed to do in isolation of one another? Can the application be tested automatically? Can the application eventually be tested easily end-to-end as part of an integration test? Can the application be load-tested?
  • Buildability – Can the application be built on systems other than those in the development environment? How often can it be built? The more often it can be built, the better. What tools can be used to do the builds? Can they implement continuous integration by building at every check-in? Which third-party controls or components are used? What part do licenses for third-party products play in the ability to build centrally?
  • Maintainability – How easy is it to understand the software for people other than the original developers? How easy is it to correct defects? Is the system documented enough to make it understandable?
  • Debugability – How easy is it to find out where and why there is an error in the system? How easy is it to find what is going wrong in a live, productive system?
  • Extensibility – How easy is it to extend the functionality of the system beyond its original specification?

Runtime Qualities

  • Functionality – How well does the software help the users to do their work? Are there missing features which make the software useless? Does the software provide end-to-end support for a particular process?
  • Usability – How easy is it for users to understand and learn to use the software?  Is the interface intuitive? Is there a supportive help system? Does the user interface match the users’ needs? Are basic usability standards and conventions adhered to?
  • Performance – Does the system perform fast enough? How does it perform when multiple users are active? Where are the bottlenecks and latency in the system?
  • Concurrency – Is it possible for more than one user to use the system at a time? What is the performance impact of multiple sessions? Is state shared across the application, making the system unreliable?
  • Security – Does the system prevent unauthorized access or misuse? What happens if access is wrongly denied to a user? How easy can security be administrated? Does the STRIDE threat model show up any weaknesses? What is the potential outcome of a successful attack? 
  • Integrity – This can be related to security, but it also refers to the data integrity of the system. Is the data always kept in a consistent state, or is it sometimes possible to infer different states of the system because of inconsistencies in the system? Do transactions pass the ACID test?
  • Reliability – Can the users rely on the software? Will it always perform correctly? Is it still usable at peak usage periods?
  • Availability – How often and for how long is the system available for use? How do upgrades affect its availability? Is the system meant to be used across time-zones?
  • Scalability – How does the software cope with adding more users over time? Can the system cope with an increase in the volume of data? What happens if the users start to use the system more often? Must the software scale up or can it scale out?
  • Deployability – How easy is it to deploy the initial release of the software? How easy is it to release future releases? Does software need to be replaced, or just patched? How does the deployment affect scalability?
  • Ugradability – Can a new version be deployed without stopping the normal operation of the system? What must be changed or upgraded when a new version is released? What third-party software may be upgraded which would affect the software?
  • Correctness – Does the software do exactly what was specified?
  • Conceptual Integrity – How balanced, simple, elegant, and practical is the whole system? Is there a clear vision as to what the software should do? Is the design consistent?
  • User Responsiveness – Related to performance and usability; how does the user perceive the application to be responding? Does the system stop responding for long periods of time, especially when retrieving data? Does the latency of parts of the system lead to decreased usability? Does the software use multiple threads to improve responsiveness?
  • Interoperability – How easily can the system be used with other systems?
  • Robustness – How does the system react to abnormal conditions? Does it crash, or recover gracefully? Do error messages baffle users and decrease usability?

Priorities

Software qualities must always be balanced against one another. There’s no point in having performance good enough for MySpace.com if it’s not needed, for example, especially if it makes maintenance harder. Each quality has a particular importance for the system being developed.

In general the highest priority qualities are:

  • Maintainability
  • Correctness
  • Reliability

Also important for .Net Object-Oriented design are:

  • Reusability
  • Extensibility

Most of what I focus on in my day-to-day work is focused on good maintainability and modifiability. Changes come along all the time, and the people paying for the software want them done fast. The faster you can adapt to their needs, the more they trust you, and the better your business relationship.

2 Comments