October 2004 - Posts - Ernst Kuschke

   Ernst Kuschke

     Arbitrary thoughts and musings on life, the universe and everything else

Syndication

News

    ernst kuschke (v1.0)

    My Photos

    Microsoft Most Valuable Professional

    Member in good standing

    View Ernst Kuschke's profile on LinkedIn

    Add to Technorati Favorites

Blogs I read

Books I recommend

General Links

October 2004 - Posts

I uploaded the ones I could :P
I had to mention this piece of brilliant T-SQL code I came across tonight - it creates a PDF document with absolutely no external libraries / tools required.
Posted by Ernst Kuschke | with no comments
Filed under:

One of the Tech Ed sessions were on enhancements in ADO.NET 2.0. (Armand will remember this session vividly). The cooler ones of the lot are:

  • The DataSet can now be serialized to a binary format (This will be disabled by default, so as not to break any existing code).
  • The DataTable now implements ISerializable, in other words you can remote DataTable objects, which are much more lightweight than a full-blown DataTable.
  • The DataTable also supports the common DataSet operations like WriteXml, WriteXmlSchema, etc.
  • RowState can be changed - it is no longer read-only. (DataRow.SetAdded() / DataRow.SetModified())
  • SqlDependancy will enable you to catch events raised from SQL Server 2005 when certain data undergoes changes. (Especially usefull to refresh cached data).
  • Multiple Active Result Sets (MARS). *While* using a connection to read from, you can use the same connection to read different data, or save data to a store.
  • A Database discovery API is available.

Sounds good.

Posted by Ernst Kuschke | 2 comment(s)
Filed under:

I always knew Tech Ed is a big event, but it's quite bigger than what I imagined.

I found the MVP-led Chalk & Talk sessions really insightful - mostly because of the informal atmosphere around these sessions. Attendees contributed to the discusssion with their ideas, and we got into some good-spirited arguing around various topics. I highly recommend these sessions - next year we'll try to have them closer to the main session halls.

Between all the sessions & learning we found time to go on the Segway Safari around the golf course and the Waterworld, and let me tell you: try it if you can, it ROCKS.

Have to run, keynote will start soon.

Posted by Ernst Kuschke | 3 comment(s)
Filed under:

SADeveloper.net has been redeisigned and migrated successfully - swing past and become part of the most awesome developer community you can imagine. If you're a member, see you at the SADev party on the beach at Tech Ed on monday night!!!

(Thanks Arno!!!)

Posted by Ernst Kuschke | with no comments
Filed under:
Bill Evjen has a nice list of things to pack before hopping on the plane to Sun City on Sunday!!!
Posted by Ernst Kuschke | 2 comment(s)
Filed under:

My talk at Tech Ed is titled “Asynchronous API Design”, and will show the basics in designing an asynchronous API for your business layer, to be called from the UI layer. The need for the UI developer to concentrate on any complicated asynchronous coding should be *minimal*.

The sessions are scheduled as follows:

  • Monday,  25th October: 16:15 - 17:15
  • Tuesday, 26th October: 14:45 - 15:45

The sessions will be in the form of open chalkboard discussions, so bring all your questions and ideas - this will be an excellent opportunity to discuss asynchronous business object design.

Posted by Ernst Kuschke | 2 comment(s)
Filed under: ,
A free version of Newsgator is now available, with limited functionality.
Posted by Ernst Kuschke | with no comments
Filed under:

When creating our NAnt scripts one of the first issues I ran into was sending a copy of the buildlog to certain email addresses. What I innitially did was to create a NAnt target called sendmail that would attach the buildlog file and mail it to a list of interested parties. After building my assemblies, I would call this target, which looked like this:

<target name="sendmail">
    <mail
        from=“NAnt@myCompany.com“

        tolist=“${distribution_list}“
        subject="${mailsubject}" 
        mailhost
="${smtpServer}"
        message
="${mailbody}"
        verbose
="true"
     
>
        <attachments
>
            <include name="${buildroot}/build.log"
/>
        </attachments
>
    </mail
>
</
target>

This should work, right? Nope... The build.log file can't be attached to the email, since it is still being accessed by NAnt (it is still being written to). You will get an error that stipulates that access to the file was denied. 

I then added a line that would make a copy of the build.log file before sending the email, and then attach this copy to the mail. The copy gets attached to the mail allright, but there is a new problem introduced: the log isn't complete. The buffer containing the build log hasn't completely been written to file at the time the mail is sent, with the result of only about half of the build.log being emailed out! I tried letting NAnt sleep before sending the email, but that also causes the writing of the log to sleep.

I finally found the solution, and it's simple. Forget about the sendmail target alltogether. NAnt has the MailLogger assembly which sends email out for you - you just need to set its properties, like so (set these right in the beginning of your script):

<property name="MailLogger.mailhost" value="${smtpServer}" />
<
property name="MailLogger.from" value="NAnt@myCompany.com" />
<
property name="MailLogger.failure.notify" value="true" />
<
property name="MailLogger.success.notify" value="true" />
<
property name="MailLogger.failure.to" value="${failure_email_list}" />
<
property name="MailLogger.success.to" value="${success_email_list}" />

To tell NAnt to use the MailLogger when logging, specify it on the commandline using the -logger parameter when running NAnt (I also specify a logfile here with the -l parameter):

    nant -buildfile:my_buildfile.build -logger:NAnt.Core.MailLogger -l:my_build_log.log

This will send the log in an email as inline text.

There are ups and downs to developing web applications with VS2003, as Visual Studio 'web projects'. It's nice to step through your ASP.NET code, add watches, and drag webcontrols onto webforms. However, once you try doing continuous integration and unit testing you'll start speaking in languages apart from the .NET ones! It doesn't work.

[ASP.NET Tip] - Fritz Onion shows you how to develop ASP.NET applications with VS2003, without all the pains associated with web-projects: develop them as class libraries without the loss of functionality gained from using web-projects.

Fellow Durbanite Mark Nilsen has finally decided to jump in. Subscribed!
Posted by Ernst Kuschke | 1 comment(s)
Filed under:
Tech Ed is around the corner. The MVP's will be running sessions with delegates on topics. A few interesting topics (they're a surprise!) will already be covered, but more suggestions are more than welcome!!! I'd like to invite *everyone* to post some suggestions in the comments - you don't necessarily have to be going to Tech Ed to make a suggestion.

I just got an email from a bank in Illinois, USA, telling me that they know how I should handle my property best. They then go ahead and give an address where my parents lived when I was about 12 years old - how on earth do the harvest their data?! What will the stance of things be in the future?

I make a habit of never clicking any link in spam. I immediately block the address and ignore it, but I wonder if this has even had the slightest effect on the number of spammed mails I received daily. Ugh, something needs to be done.

Posted by Ernst Kuschke | with no comments
Filed under:

Just briefly looking at Yukon is, well, quite mindblowing. Here's a few of the major improvements in ADO.NET v2, which ties up with Yukon's new features to give developers more functionality:

  • MARS. The team has added what has apparently been the biggest request in many years for SQL Server: Multiple Active Result Sets per single connection can now be active at the same time.
  • ObjectSpaces. That's right! It's possible to map relational data to objects without the need of writing any code. A query may thus returns objects, and not rows.
  • Query notifications. This seems to be mostly aimed at cache invalidation - your caching subsystem can react upon notification if data that it is caching has been changed. Just imagine how you can utilize the IIS caches without becoming stale, without writing much code!
  • XML Datatype. This new datatype has been added.

The big thing on everyone's minds is of course the CLR hosted in Yukon. This enables Yukon, amongst others, to return user-defined types directly to the business tier, which gives a smart developer with enough time the opportunity to turn his Yukon instance into an object database. I'd love writing more, but I need to go and get some sleep. (I'm a mere mortal, Ruari!)

[UPDATE] As pointed out in the comments, ObjectSpaces is out for next year's release. Andrew Conrad explains *why* it's compelling to ship this with WinFS. *When* remains unanswered...