Oren Eini

CEO of RavenDB

a NoSQL Open Source Document Database

Get in touch with me:

oren@ravendb.net +972 52-548-6969

Posts: 7,640
|
Comments: 51,263
Privacy Policy · Terms
filter by tags archive

Rant

time to read 7 min | 1246 words

Note: This post started as a comment on the post just below, but it developed into a full blown rant along the way. I'm detailing many of my frustrations with the tools.

Scott Bellware has posted Mort or Elvis? A Question for a Bygone Era, which is a great post (as usual), but it also hit many of the pain points that I feel in working with VS 2005 recently. In fact, Scott does a great job of expressing those pain points than I could.

Microsoft's tools are getting progressively worse rather than better.  Microsoft development tools are showing the unmistakable signs of entropy and neglect that comes as a result of the parasitic infestation of product development groups by the cowardly side of the software business.... 

In the comments he talks about Microsoft's tools and then subtle product placement that I didn't recognize but drive me constantly crazy. I use VS.Net 2005 for the simple reason that it is the only one out there for .Net 2.0 development. ReSharper makes the job bearable, but it says quite a bit if I need an alpha quality tool just to feel good again.

Beyond VS.Net, my most common tools are not Microsoft ones (NAnt, NUnit, TestDriven.Net, etc). Scott comments on this:

And indeed, these folks [thinking developers] will bring an arsenal of better tools to the table.  Few of them will have been created by Microsoft, and most of them will be free, and open-source. 

Finally, there is this sentiment that I agree with wholeheartedly:

I would pay right out of my own pocket for a .NET IDE built by JetBrains. They could change me $1000 and I'd be delighted to fork over the cash if they could give me an IDE that was file-system and project-system compatible with Visual Studio with none of the bloat and none of the endless, insulting product placement clutter that has gained influence over the design of Visual Studio to the detriment of good, clean, usable product.

I wanted this for a long time. I hope that once they release ReSharper, they will rev up the work on .Net IDE. I know that I would buy Intelli.Net IDEA in a heart beat, and push it out as far as I can.

And now to my own ranting:

And my own note about the personas. They don't work anymore. I get questions from VB.Net developers that want to know how to use Rhino Mocks, there have been questions about VB.Net development with Castle, etc.(Not to go down on VB.Net programmers, but this is the language that is portrayed as Mort's favoriate). I has to do some UI work right now, and I tried hard to do this with VS.Net's Automatic UI & Coffee System(TM), but I couldn't make it do what I wanted, and I ended up doing most of it manually.

Simple UI should be the part where the tooling is excellent, but in order to use them, you need to know quite a bit about the tools, and that is not something that I see as highly productive. I know the WinForms (and Win32) API well enough to produce a working UI for most of everything, but I don't see investing time in learning the exact incantations that I need to do this or that (nothing highly complicated, by the way) for non standard scenario (binding Business Objects to a form).

By concentrating so hard on the tools, only the supposedly core scnerios are taken care of, leaving everyone that does something different high & dry. And the problem seems to be that there isn't any improvement along the way in the tools.

We have the Web Application Project, to get back the stuff they took away from VS 2003, but that is about it. Where is the promised Service Pack for Visual Studio 2005? I haven't even heard a whisper about it since it was announced, and it is not like there aren't bugs that need fixing in there.

Posts like this one, talking about how features are planned for VS, just scares me. It looks very much like the merit of a feature is its demo-ability. This produce software that demos great, but that just doesn't stand on its own when you need to develop a real scenario. Combine the non-tirivial time that you need to invest to learn how to work with the tool with the even more significant time to learn how to by-pass the tool, and you get a net loss situation. Non-demoable features end up being more important in the long run.

How many demos has seen the demo about File.ReadAllText() method? Yet it ends up saving me 5 lines of code every time that I need to read a file. Or the GC improvements? Or ASP.Net Build Providers? Linq will be cool if I could get a compiler support and intellisense alone. No need to build any UI on it, it is cool because of what it is, not because of what kind of UI I can show in a keynote.

I really like the framework, from ASP.Net to WinForms to Theards to ADO.Net. I just dislike the tool that I have to interact with it. It is nice and shiny from the outside, but don't take a too close look at the support beams. The IDE shouldn't try to help me. I know what I'm doing, thank you very much. I want to be able to work with code in my IDE, intelligence on the part of the IDE is required, otherwise I can just work in Notepad. I don't want to work like Microsoft thinks I should (TDD or DataBinding, for instance), I want to have the functionality in the class library, and the IDE should support it.

I get a far better value from TestDriven.Net than I do from VS' Test Tools, and TestDriven.Net has a far more primitive interface, with far less functionality, probably. But this is a zero friction tool, I don't need to adhere to Jamie's design philosophy if I want to use it.

Okay, that is enough ranting for now, I think

time to read 2 min | 230 words

Because I wrote it, of course J

Beside this, there is the nice part about smart collection and references that can save me quite a bit of code. Take this example:

 

RuleBase rule = RulesTree.SelectedNode.Tag as RuleBase;

if(RulesTree.SelectedNode.Parent==null)//top Rule

{

    customer.Rules.Remove(rule);

}

else

{

    ContainerRule parent = RulesTree.SelectedNode.Parent.Tag as ContainerRule;

    parent.Children.Remove(rule);

}

 

I started to write this code, but soon realized that because I used NHibernate Generics’ smart collection, I could do this instead:

 

RuleBase rule = RulesTree.SelectedNode.Tag as RuleBase;

rule.Customer = null;

rule.Parent = null;

 

This is much simpler, in my opinion, and it has the same affect.

time to read 2 min | 353 words

Why I don't like data binding:

  • You can't work with interfaces. If my object has a property with a type IList<T>, it wouldn't work. That is even if the collection implements IBindingList.
  • An error in the data bound grid cannot be exited short of killing the process.
  • You can't bind to non-IList data.
  • It looks like some weird stuff is going on behind the scenes, I get index not found exception when using the data grids, and I'm pretty sure that I am handling everything just fine.
  • I can't make deleting works, no matter what I do, it looks like the instances that it uses are different than the ones that I'm passing it, but I don't have the time to find out right now.  I can get it done more easily if I will simply do it by hand, I am afraid.

 

I started to add Support for Data Binding to NHibernate Generics:

  • Added IBindingList, IRaiseItemChangedEvents, ICancelAddNew support for EntityList<T>.
  • It will automatically subscribe to any inserted item when it implements INotifyPropertyChanged
  • Support searching out of the box.

 

Unfortunately, it looks like my implementation is flawed, so I'm not going to commit the changes (maybe to a branch), unless there is anyone out there who know more than I do about data binding and can help me get it to work.

time to read 3 min | 500 words


Data Binding with Windows Forms 2.0 : Programming Smart Client Data Applications with .NET (Microsoft Net Development Series)

 

Here is the rest of my review of this book.

Chapter 6 has a fairly complete introduction to the DataGridView control, which actually made sense to me. I'm still not certain how I'm going to go implement my UI, but this is mainly because I want hirerchial display of some sort, and apperantly the DataGridView doesn't support this. Since it is should be a two level hirerchy only, it shouldn't be a problem to display on the side, rather than on the grid itself, but I'm wonderring if I should take the time to investigate Infragistics' controls and see how easy it would be to this versus displaying it on a seperate grid.

 

Chapter 7: Right now I'm in the middle of it, and it is very boring. It covers all the essenstials interfaces for data binding, and I know I need those, it is just that some of this I know and most of this I will need to know, but I am slightly sick and it is a dry read.

So far it has only served to convince me that this stuff is not trivial.  Chapter 9 is supposed to show how I can implement it over normal business objects without too much trouble. I'm waiting expectantly, I really hope to avoid having to handle all the gotchas there myself.

I don't believe that I didn't know anything about TypeDescriptor and friends up until now, I kept doing it all by hand.

 

Chapter 8: Skipped this one right now, it talks about implementing data bound controls, which I have zero intention to do (ever!) . I'll probably be back later to check on it anyway, since it has cool stuff like "Autocompleting Input in a TextBox Control"

 

Chapter 9: Finally, I get to the real thing. "Implementing Custom Data-Bound Business Objects and Collections" is the whole reason I'm reading this book. So far it looks liket the author has as strong a bias toward DataSets as I have against them :-) I ended up implementing the functionality that I need right now by myself.  Since the bulitin support isn't enough. There are a lot of ideas about how to implement the interfaces correctly.

 

Chapter 10: Talks about validations and error handling, I'm skipping it right now.

 

Overall, this is a really good book, I don’t have time to play with everything that the author shows, but it looks very interesting.

time to read 1 min | 168 words

I was asked a question today, and I'm not sure what the answer is. The issue is with optimistic concurrency on the web. I got an edit page that allows a user to edit a page. I want to throw a concurrency exception if a second user has changed the object while the first user was editing it.

The issue is that when I get the values of the form back when the user is finished editing, I no longer know what version of the object the user has edited. It looks like I would need to store the version of the object (most likely a SQL Server Row Version) in the form as well, and then get the object from NHibernate, set the version property of the object (and all the rest of the fields), and then try to save, to see if there was a concurrency violation.

Any other ideas that I have not thought of?

time to read 1 min | 180 words

I just did a little test with NHibernate's Schema Generation capabilities, and I'm very impressed. The schema is very much like I thought it would be, and it makes sense.

So far I've been avoiding it, thinking that I can do much better and that it is something that I have to do by hand. This caused quite a bit of pain when I needed to make a change in the object model that required a DB change. I'm thinking that I'll be able to just use it to easily and painlessly re-create the schema every time I'm starting.

It looks much simpler this way. Of course, this means that I'll need to put more information into the mapping than I currently do (for instance, I don't always bother to specify not-null constraints, etc). I don't know how to handle column orderring, but I have a suspicition that it matches the orderring inside the mapping (which may bring interesting questions when I will try to apply it using Active Record).

time to read 4 min | 601 words


Data Binding with Windows Forms 2.0 : Programming Smart Client Data Applications with .NET (Microsoft Net Development Series)

12:57: I got this book from a friend, and I'm going through it in a speedy pace. I'm only finsihed chapter 2 right now, but I think that I can tell that this is going to be a good book. The datasets chapter was very good, without being condensingly simple, like most of the datasets tutorial that I encountered. As someone who can honestly claim to have never used a data set in a real app (not that I didn't try, I just couldn't make it do what I wanted), I appriciate the kind of treatment of the subject the book has.

I still have to go through more than just the "magic" demos, so I will update this post as I go along.

13:22: I finished chapter 3, which had me buliding a Master - Details relation with grids that is very close to what I need. I'm not sure that I understand how to get this to work with Active Record objects, though. I think that I can make it work. I'll need to see the chapter about binding to custom objects and playing with that a bit to get it to do something useful and pretty. I really like the binding navigator, though, it looks like it can be highly useful.

13:28: Just starting to read chapter 4, and it has a statement there that makes me want to jump up and cry "Halleluja"

This can all be set up in the constructor, and is typically done by dragging and dropping both the grid and the binding source onto the form and setting the appropriate properties in the designer. However, for now, let's focus on how to do things without the magic of the designer.

Now that is my kind of sentiment. Also check the "Code First Versus Design Features First" section in the beginning of the book.

14:21: Found that text boxes in Win Forms 2.0 has auto complete features. I did not know that. This is really cool.

14:36: Chapter 4 done, it was very interesting, and included examples of several interesting scenarios. Formatting / Parsing were interesting, as well as the more detailed explanations of how databinding works.

14:58: Chapter 5 is done. Lots of ways of using the designer. It included some stuff that I think are cool, since I have seen what kind of code I would need to write in order to make the databinding happen (and I know what kind of a pain it is to write this manually).

15:12: Tried to used what I learned so far, but it looks like interfaces & data binding aren't going well. At least with regard to the designer. I tried to bind to ICollection<T> and to IList<T>, and it fails. It works just find on List<T>.  I guess that I have a lot more reading to do.

I need to go ponder the meaning of matrix multiplication in the general scheme of the universe, so I'll post this now, and post the rest of the review when I return to it.

time to read 2 min | 241 words

I'm not a UI guy, not even close. Nevertheless, I need to work with it often enough. Right now I got to write a WinForms UI that involves displaying and organizing data from several sources, Database (via Active Record), Reflection, etc.

I want to use data binding for the whole thing, since the data is basically text and some combo boxes, nothing special. The problem is that while I can find a wealth of information on data binding in ASP.Net via declarative markup, and some information about binding and manipulating datasets in WinForms, I can't find any good explanations on how to do it with business objects (in this case, Active Record objects).

I thought about getting a book, but it is unlikely that I would read it, to tell you the truth, I just don't have the time, and I need the information as soon as possible. An added complexity is that while I have a fairly good understanding on the Win32 controls, (Textbox, ComboBox, ListBox, etc), I know practically nothing about DataGrid, and that is probably what will make the best control for the job.

I got some hierarchy that I want to display (one level only), and I am so not feeling like doing it all by hand.

Any good tutorials on the subjet? I'm pretty clueless about databinding and data grids.p

FUTURE POSTS

No future posts left, oh my!

RECENT SERIES

  1. API Design (10):
    29 Jan 2026 - Don't try to guess
  2. Recording (20):
    05 Dec 2025 - Build AI that understands your business
  3. Webinar (8):
    16 Sep 2025 - Building AI Agents in RavenDB
  4. RavenDB 7.1 (7):
    11 Jul 2025 - The Gen AI release
  5. Production postmorterm (2):
    11 Jun 2025 - The rookie server's untimely promotion
View all series

Syndication

Main feed ... ...
Comments feed   ... ...