Category Archives: software development

Developers dislike monochrome Visual Studio 11 beta

Microsoft is having trouble convincing developers that its new Metro-influenced Visual Studio user interface, in the forthcoming version now in beta, is a good idea.

To be more precise, it is not so much Metro, but the way Microsoft has chosen to use it, with toolbox icons now black and white. The change also affects menus such as IntelliSense in the code editor. Here is the new design:

image

or you can choose a “Dark” colour scheme:

image

and the old 2010 design for comparison:

image

Developers voting on this over at UserVoice, the official feedback site, have made this the single biggest issue, with 4707 votes.

image

They do not much like the All Caps in the toolbox names either.

Microsoft has marked this as “Under review” so maybe there could yet be a more colourful future for Visual Studio 11.

Adobe will charge a royalty for use of “Premium features” in Flash Player

Adobe has announced that from August 1 2012, developers who make use of hardware-accelerated Stage3D in Flash Player, in combination with Domain Memory, will pay a 9% net revenue share as royalty. Net revenue is what remains after taxes, payment processing fees and “social network platform fees” (sounds like Facebook) are deducted.

“Domain Memory” is a block of memory declared as a byte array that is used as memory by the Alchemy C/C++ to ActionScript compiler. Allocating some bytes from this byte array is much faster than asking the Flash Player to grab some real memory from the system for your new object or variable, and manipulating memory via this technique is quicker too. In other words, it is a hack to improve performance.

Adobe is aiming the new licensing arrangement at games developers. Most developers will not be affected because of the following:

  • A license is only needed if both Stage3D hardware acceleration and Domain Memory are used. Use just one of these and you are fine.
  • If the game or app is packaged using Adobe AIR for iOS, Android, Windows or Mac (in other words, anywhere) then no license is needed.
  • Applications that make less than $50,000 in revenues (not clear whether this is net or gross) will be royalty-free
  • Applications released before July 31 2012 will remain royalty-free

There may be a program fee however, which I imagine will apply whether or not you pay royalties.

Although the new royalty is not all that onerous, it is significant as a change of direction. Until now, the deal with all these runtimes – Flash Player, Silverlight, Java – is that you might pay for the tools, but the runtime is free.

If you are considering Flash versus other runtimes for your new project, Adobe has now informed you that future free use of the runtime is not a foregone conclusion. Who knows what Adobe will define as “premium features” that might require royalties in future?

According to the FAQ, further premium features are indeed planned:

We are already planning premium features that enable "instant play" gaming experiences for content that relies on large assets which will be able to cache data using a local storage API. For content publishers looking for better branding and user acquisition, another planned new feature would allow apps to request if the user would like to create a shortcut on the desktop, task bar or start menu pointing to the application.

Overall it seems a curious move, at a time when Adobe seems to be moving away from Flash and towards HTML5 as its long-term strategy. The company may profit a little from a few high-profile games, but the dampening effect on Flash usage in the long term will offset any advantage.

No developer likes to pay runtime royalties and I would guess that Adobe’s move will spark an immediate search for alternatives.

Update: there is a great discussion of the issue with participation from Adobe’s Thibault Imbert here. Why the change in direction, when Adobe has previously made money from its tools:

at some point you are capped. Ask any tooling company today, hence why you see companies going to consumers, services, because games could generate millions of revenue with maybe 200 copies of Flash Builder and Flash Pro sold. Is it a good business? Not really.

says Imbert. Another issue is that third-party tools for Flash have been taking market share away from Adobe, which must hurt:

The model where Adobe invests all of the resources in developing the Flash Player, and then projects such as Haxe and Unity pull developers away from Adobe tooling is one that was not sustainable under the old model. Under the new model, it doesnt matter which tools and technologies you are using to develop Flash content, since revenue is generated based on the runtime and not tooling.

says Adobe’s Mike Chambers.

Developers: will you do Metro?

It is fascinating to watch the Metro-fication of all things Microsoft, from the Xbox 360 user interface to Windows Phone to Windows 8 to forthcoming versions of Office and other applications.

Future versions of Dynamics products were previewed at the Convergence 2012 event (which included a session called CRM goes Metro) and there are a bunch of screenshots here.

image

Microsoft calls Metro a design language and you can see its guiding principles here. Calling it a language does not seem quite right; the word “style” is more accurate, but it does have building block elements (and yes it is blocky) which I guess make it more than just a style.

A safe prediction at this point is that all Microsoft’s products will be touched by Metro influence, even though not all will become full Metro apps running on the Windows Runtime (WinRT).

In the past the style adopted by Microsoft for its own applications have strongly influenced third-party applications as well. Once Windows, Office, Dynamics and other apps have a Metro look, other apps that do not may begin to look dated or out of place.

Metro is controversial though, perhaps even more so than the Office Ribbon which replaced menus in Office 2007 and 2012. There is some connection: members of the Office team who worked with Steven Sinofsky on the design of Office 2007, including Julie Larson-Green and Jensen Harris, are now working with him on Windows 8. Harris has written extensively about the work on Office 2007 on his Office User Interface Blog, though the last substantial post was in 2008.

What’s not to like about Metro? Here’s a few arguments against:

  • Beauty is in the eye of etc; but the blockiness of the Metro style does give it a utilitarian appearance. In Windows Phone 7 it is nice to use, but not so great to look at.
  • The Live Tile concept, where shortcut blocks can be populated with current information, adds a random element to Metro start screens which does not always look good.
  • The emphasis on simplicity and immersion makes Metro vulnerable to the accusation that it wastes too much precious screen space.
  • Metro tends to be a horizontally scrolling style, though I am not sure if this is baked into the guidelines. This takes some adjustment since most of us are more used to vertical scrolling to see more content.
  • Metro seems to be optimized for a touch UI, and while its advocates insist that it is just as good with keyboard and mouse, that is a stretch. Metro seems to be a big bet on touch as the future of human-computer interaction.

On the other hand, the usability of Windows Phone 7 is a point in its favour, and some are convinced. Paul Greenberg, in a positive take on Microsoft’s strategy based on his trip to Convergence 2012, says:

They have nailed UX (a.k.a user experience). Nailed it. Their combination of the extremely well done Metro interface and their work on natural user interfaces involving voice and touch is the new gold standard – and I’m someone who loves Apple products. (please, Mac fanboys, spare my life.)

I would be interested to hear from developers whether you expect to embrace the Metro style in your apps, wither in WinRT or elsewhere.

What’s new in SQL Server 2012?

Microsoft’s SQL Server 2012 is released next month and available to download now (I am not sure what the distinction is). I have a high regard for Microsoft’s database server; it seems to me that the team mostly gets it right. The product has become somewhat diffuse though, especially as the Business Intelligence aspect has grown, and this may account for what to me is a rather unfocused launch for SQL Server 2012, even though its name suggests that it is the most significant release since SQL Server 2008.

The following slide summarises the new features, presumably with the type size suggesting the importance of each one.

image

But is the ODBC Driver for Linux really more important than the SQL Server Data Tools, for example? Not in my view; but that reflects how SQL Server represents different things to different people.

So what are the key new feature? Here’s my quick take.

Always On

A new feature called Availability Groups that is an improved version of database mirroring

Improved failover clustering which supports multi-site clustering across subnets – above to failover across datacentres.

ColumnStore Index

A new type of index for data warehouses. This is actually pretty simple: the name says it all. Here is Microsoft’s illustration:

image

and explanation:

A columnstore index stores each column in a separate set of disk pages, rather than storing multiple rows per page as data traditionally has been stored.

Why do this? Because it is more efficient when the query only requests a a few columns from the table. Microsoft claims performance improvements from 6X to 100X in cases where the the data can be cached in RAM, and thousand-fold improvements where the working set does not fit in RAM.

SQL Server Data Tools

This is my favourite feature, probably because it is developer-focused. These are the tools that were code-named “Juneau” and which install into Visual Studio 2010. There are some visual tools, but this is essentially a code-centric approach to database design, where you design your database with all its tables, queries, triggers, stored procedures and so on. You can then build it and test it against a private “localdb” instance of SQL Server. What I like is that the database project includes the entire design of your database in a form that can be checked into source control and compared against other schema versions. Here is the Add New Item dialog for a database project:

image

Data Quality Services

Data Quality Services (DQS) lets you check your data against a Data Quality Knowledge Base (DQKB), the contents of which are specific to the type of data in the database and may be created and maintained by your business or obtained from a third-party. If your data includes addresses, for example, the DQKB might have all valid city names to prevent errors. Features of DQS include data cleansing, de-duplication through data matching, profiling a database for quality, and monitoring data quality.

image

Illustration and more details are here.

Updated SQL Server Management Studio

SQL Server Management Studio now runs in the Visual Studio 2010 shell.

LocalDB

LocalDB is a local instance of SQL Server aimed at developers and for use as an embedded database in single-user applications. It is a variant of SQL Server Express, but different in that it does not run as a service. Rather, the LocalDB process is started on demand by the SQL native client and closed down when there are no more connections. You can attach database files at runtime by using AttachDBFileName in the connection string. LocalDB is intended to replace user instances which are now deprecated.

FileTables

This is the most intriguing feature in SQL Server 2012. It is described here:

The FileTable feature brings support for the Windows file namespace and compatibility with Windows applications to the file data stored in SQL Server … In other words, you can store files and documents in special tables in SQL Server called FileTables, but access them from Windows applications as if they were stored in the file system, without making any changes to your client applications.

and the purpose:

Enterprises can move this data from file servers into FileTables to take advantage of integrated administration and services provided by SQL Server. At the same time, they can maintain Windows application compatibility for their existing Windows applications that see this data as files in the file system.

Integration of the file system and the database is not a new idea, and Microsoft has tried variants before, such as the “M” drive that was once part of Exchange, the aborted WinFS feature planned for Windows Longhorn (Vista), and SharePoint, which can store documents in SQL Server while presenting them as Windows file shares through WebDAV.

That said, FileTables in SQL Server 2012 are not an attempt to reinvent the file system, but presented more as a way of supporting legacy applications while managing data in SQL Server. It is an interesting feature though, and it would not surprise me if users find some unexpected ways to exploit it.

Power View

Codenamed “Project Crescent”, this is a web-based reporting client for businesses that have embraced Microsoft’s platform, because it has several key dependencies:

  • SharePoint Server Enterprise Edition
  • SQL Server Reporting Services
  • Silverlight on the client

In fact, Power View is described as:

a feature of SQL Server 2012 Reporting Services Add-in for Microsoft SharePoint Server 2010 Enterprise Edition

Power View reports that I have seen do look good, and have an Office ribbon style designer for designing customising the report. That said, I would guess that Microsoft now wishes it had used HTML 5 rather than Silverlight for this – there are those Apple iPad and Windows 8 Metro users to think of, after all.

Microsoft emphasises that Power View is not a replacement for Report Designer or Report Builder, but an ad-hoc reporting tool.

Closing thoughts

There is more in SQL Server 2012, as a glance back at the initial slide will tell you, but the above is a starting point if you are wondering what it is all about. It is also worth noting that Microsoft still gives away SQL Server Express which supports up to 10GB per database and includes many of same features as the paid-for versions; it is the same product at heart.

Someone who finds that SQL Server Express actually meets all their needs asked me why Microsoft gives it away. My guess is that this is a consequence of all the other free database engines available such as MySQL, PostgreSQL, interesting  newer NoSQL options like mongoDB, and of course equivalent free versions of Oracle and IBM DB2. A proportion of customers who start with SQL Server Express will grow into the paid-for editions.

This does make SQL Server Express an excellent choice for smaller scale applications and small businesses, particularly since it integrates smoothly into Microsoft’s developer stack. Having said which, I am becoming something of an Entity Framework sceptic, but that is a story for another day – and fortunately you do not have to use EF if you do not want to.

PhoneGap is Adobe, Cordova is Apache

The hot cross-platform mobile toolkit PhoneGap was created by Nitobi, a company acquired by Adobe last year. Almost at the same time, the project was submitted to Apache as an open source project. However, the Apache project is not called PhoneGap; it was briefly known as Callback and is now called Cordova (the name of the street in Vancouver where Nitobi was based).

A new official log post explains why PhoneGap was renamed at Apache, but also makes the point that the PhoneGap brand will continue.

PhoneGap is a distribution of Apache Cordova. You can think of Apache Cordova as the engine that powers PhoneGap, similar to how WebKit is the engine that powers Chrome or Safari. (Browser geeks, please allow me the affordance of this analogy and I’ll buy you a beer later.)

Over time, the PhoneGap distribution may contain additional tools that tie into other Adobe services, which would not be appropriate for an Apache project. For example, PhoneGap Build and Adobe Shadow together make a whole lot of strategic sense. PhoneGap will always remain free, open source software and will always be a free distribution of Apache Cordova.

Read it carefully, because it is still potentially confusing. Note that PhoneGap “will always remain free, open source software” though it may gain hooks into commercial Adobe tools. At least, that is how I read it.

I would also expect that Adobe will come up with design and development tools for which PhoneGap (or Cordova) is invisible to the user. You will just be able to build for multiple platforms.

The post adds:

Currently, the only difference is in the name of the download package and will remain so for some time.

I will add that there is great brand-awareness of PhoneGap and what it is, and little for Cordova, so if you want to be understood talk about PhoneGap.

Microsoft’s platform nearly invisible at QCon London 2012

QCon London ended yesterday. It was the biggest London QCon yet, with around 1200 developers and a certain amount of room chaos, but still a friendly atmosphere and a great opportunity to catch up with developers, vendors, and industry trends.

Microsoft was near-invisible at QCon. There was a sparsely attended Azure session, mainly I would guess because QCon attendees do not see that Azure has any relevance to them. What does it offer that they cannot get from Amazon EC2, Google App Engine, Joyent or another niche provider, or from their own private clouds?

Mark Rendle at the Azure session did state that Node.js runs better on Windows (and Azure) than on Linux. However he did not have performance figure to hand. A quick search throws up these figures from Node.js inventor Ryan Dahl: 

  v 0.6.0 (Linux) v 0.6.0 (Windows)
http_simple.js /bytes/1024 6263 r/s 5823 r/s
io.js read 26.63 mB/s 26.51 mB/s
io.js write 17.40 mB/s 33.58 mB/s
startup.js 49.6 ms 52.04 ms

These figures are more “nothing to choose between them” than evidence for better performance, but since 0.6.0 was the first Windows release it is possible that it has swung in its favour since. It is a decent showing for sure, but there are other more important factors when choosing a cloud platform: cost, resiliency, services available and so on. Amazon is charging ahead; why choose Azure?

My sense is that developers presume that Azure is mainly relevant to Microsoft platform businesses hosting Microsoft platform applications; and I suspect that a detailed analysis would bear out that presumption despite the encouraging figures above. That said, Azure seems to me a solid though somewhat expensive offering and one that the company has undersold.

I have focused on Azure because QCon tends to be more about the server than the client (though there was  a good deal of mobile this year), and at enterprise scale. It beats me why Microsoft was not exhibiting there, as the attendees are an influential lot and exactly the target audience, if the company wants to move beyond its home crowd.

I heard little talk of Windows 8 and little talk of Windows Phone 7,  though Nokia sponsored some of the catering and ran a hospitality suite which unfortunately I was not able to attend.

Nor did I get to Tomas Petricek’s talk on asynchronous programming in F#, though functional programming was hot at QCon last year and I would guess he drew a bigger audience than Azure managed.

Microsoft is coming from behind in cloud -  Infrastructure as a Service and/or Platform as a Service – as well as in mobile.

I should add the company is, from what I hear, doing better with its Software as a Service cloud, Office 365; and of course I realise that there are plenty of Microsoft-platform folk who attend other events such as the company’s own BUILD, Tech Ed and so on.

Update:

This is the basis for the claim that node.js runs better on Windows:

IOCP supports Sockets, Pipes, and Regular Files.
That is, Windows has true async kernel file I/O.
(In Unix we have to fake it with a userspace thread pool.)

from Dahl’s presentation on the Node roadmap at NodeConf May 2011.

The most enduring software development techniques revealed at QCon London

I am in London for the QCon event, a vendor-neutral development conference which I have been fortunate to attend regularly over the last few years.

image

These events tend to have an underlying theme, which reflects the current thinking of developers and software architects. Each year I hear cogent and thoughtful explanations of why this or that approach will enable us to code better and please users more. Each year I also hear cogent and thoughtful explanations of why the fix proposed last year or the year before is actually a prime reason why projects fail.

Way back when it was SOA (Service Oriented Architecture) that was sweeping away the mistakes of the past. Next SOA itself was the mistake of the past and we got REST (Representational State Transfer). This year I am hearing how RPC is making a comeback, or at least not going away, for example because it can be more efficient when you want to transfer as little data as possible across the WAN.

Another example is enterprise Java. Enterprise Java Beans and J2EE were the fix, and then the problem, for scalable distributed applications. Rod Johnson came up with Spring, the lightweight alternative. Now I am hearing how Spring has become bloated and complicated and developers are looking for lightweight alternatives.

Test-driven development (TDD) brings fantastic benefits to software development, making it possible to change and improve your code while defending against the introduction of bugs. Yesterday though Dan North observed that TDD also has a cost, in that you write much more code. It is not uncommon for projects to have more test code than code that is active in production. If you did not write that code, you could be doing other productive work in the time made available. 

Agile methodologies like Scrum were devised to promote or even create communication and agility in software teams. Now every big enterprise vendor says it does Scrum and runs courses, but the result is a long way from the agile (with a small a) original concept.

This year I have heard a lot about over-optimisation, or creating code for situations that in fact never arise. This is the problem to which the solution is YAGNI (You Ain’t Gonna Need It). Since they apply across all the methodologies, I suggest that YAGNI, and its cousin DRY (Don’t Repeat Yourself), and the even older KISS (Keep It Simple Stupid) are the most enduring software methodologies.

That said, even DRY took a beating yesterday. Greg Young in his evening keynote said that rigorous DRY advocates can end up creating single blocks of code where really the procedure was only nearly the same. If your DRY functions are full of edge cases and special conditions, then maybe DRY has been taken to excess.

In the light of the above, I would therefore like to propose the first draft of my first theorem of software development:

There is no development methodology which will not become a burden when embraced rigidly

The other lesson I have learned from multiple QCons is that effective teams and smart developers count for much, much more than any specific tool or language or approach. There is no substitute.

How Amazon Web Services dominate infrastructure as a service

During Mobile World Congress I met with some folk from Twilio, the cloud telephony company, who said something that interested me. Twilio uses Amazon Web Service (AWS) for its infrastructure and told me that essentially there is no choice, AWS is the only cloud provider which can scale on demand quickly and smoothly as required.

Today at QCon London I met a guy from another major cloud-based company, which is also built on Amazon, and I put the same point to him. Not only did he agree, he said that Amazon is increasing its lead over the competition. Amazon is less visible than some, he said, because of its approach to PR. It concentrates on marketing directly to developers rather than chasing press stories or running big advertising campaigns.

Amazon has also just reduced its prices.

This is mixed news for the industry. In general developers I speak to like working with AWS, and its scalability is a huge benefit when, for example, you are entering a new market. You can do so without having to invest in IT infrastructure.

On the other hand, stronger competition would be healthy. My contact said that he reckoned his company could move away from Amazon in 12 weeks or so if necessary, so it is not an absolute lock-in.

Sold out QCon kicks off in London: big data, mobile, cloud, HTML 5

QCon London has just started in London, and I’m interested to see that it is both bigger than last year and also sold out. I should not be surprised, because it is usually the best conference I attend all year, being vendor-neutral (though with an Agile bias), wide-ranging and always thought-provoking.

image

A few more observations. One reason I attend is to watch industry trends, which are meaningful here because the agenda is driven by what currently concerns developers and software architects. Interesting then to see an entire track on cross-platform mobile, though one that is largely focused on HTML 5. In fact, mobile and cloud between them dominate here, with other tracks covering cloud architecture, big data, highly available systems, platform as a service, HTML 5 and JavaScript and more.

I also noticed that Abobe’s Christophe Coenraets is here this year as he was in 2011 – only this year he is talking not about Flex or AIR, but HTML, JavaScript and PhoneGap.

Embarcadero updates Delphi XE2, full reinstall required

Embarcadero has released Delphi XE2 Update 4. The depressing news is that you have to uninstall RAD Studio completely before installing the update. The reward is a large number of bug fixes, listed here, as well as new features:

  • Printing support in FireMonkey OS X
  • Support for Free Pascal 2.6 in FireMonkey iOS
  • New FireMonkey types and methods
  • New VCL styles
  • 64-bit type library import, for using COM libraries in Delphi

Delphi XE2 was somewhat rough on first release, so upgrading is advisable. Maybe it is now sufficiently robust to attract those more cautious developers who do not like to use new products in their first incarnation.