There's a brouhaha over the way in which ext4 and applications work together. It was first noticed on Ubuntu and has a bug report. Ted Ts'o has written up an explanation of what is happening on his blog and the the bug report has a similar explanation.
Later in the bug report, he explains how applications should be written to ensure the data is written to the disk. He illustrates how Emacs and Vi ensure that the data gets written. It was an eye opener. I always wondered why they write the files that they do and now I know.
The problem is that writing applications that ensure data is correctly written to the disk is hard. I used to follow the PostgreSQL mailing list so I know how difficult it is to get data to the disk reliably. The presentation Eat My Data by Stewart Smith gives you an idea of how hard it is.
Most databases have been written to ensure that data gets written to the disk. In the above posts, Ted Ts'o makes the assertion that if want your data to get to disk use a database. Everybody hates the windows registry, so that didn't go over well. If you don't want to worry about making sure that data gets to the disk, you're best bet is to use a database. It will take away some of drudgery of verifying data written.