.NET Tips and Tricks

Blog archive

Looking at Local Databases: Scenario I

We picked out two databases for review in our July issue assessment of "local storage" tools: VistaDB (my choice) and db4o (on the recommendation of one of our readers). While the review of db4o regrettably didn't make it into print, you can expect to see my hands-on take appear on this site in the next week or so.

Regardless of which products appear in print, the next step in my review process was to define what functionality I'm supposed to be assessing. Or, to put it another way, what do I mean by a "local database"?

My assumption is that, by and large, developers create applications (Web or desktop) that update some remote data store. In that scenario, the developer might still want some place to store data on the local computer: the local storage. The data could range from user preferences, to sets of "working data," to downloaded data to be used for offline analysis.

The first scenario for using local storage is to improve performance by eliminating the round trip to the server. The alternative to using local storage is to load data into memory (and there are a bunch of in-memory databases that support that scenario). However, I'm assuming here that the developer wants some form of long-term persistence: the developer wants the data to stick around. In some cases, especially where the developer is going to be analyzing the data offline, the amount of data may be too large to hold in memory or the user is expected to add to the local data store over time. A related scenario is where the developer has data that doesn't need to be in the central store (e.g. the user preferences mentioned earlier) and decides to keep it locally.

I'm keenly interested in this topic because I've written a client-side, multi-threaded Windows service that is busy receiving data from a variety of sensor devices (the service spawns a client app for each sensor). As the client apps gather this data, they upload the data through a Web service to our server-side application, which parses the data and stores it.

My client would also like to extend the functionality of the Windows service to provide some near-realtime services at the client. To support that, in addition to parsing the data on the server, we'd also like to parse the data at the service to provide faster access to the embedded data. Since the parsing process is table-driven, this is going to involve keeping copies of some server-side data at the client.

Posted by Peter Vogel on 06/09/2010 at 1:16 PM


comments powered by Disqus

Featured

  • Color Shards

    Sharing Data and Splitting Components in Blazor

    ASP.NET Core Version 3.1 has at least two major changes that you'll want to take advantage of. Well, Peter thinks you will. Depending on your background, your response to one of them may be a resounding “meh.”

  • How to Create a Machine Learning Decision Tree Classifier Using C#

    After earlier explaining how to compute disorder and split data in his exploration of machine learning decision tree classifiers, resident data scientist Dr. James McCaffrey of Microsoft Research now shows how to use the splitting and disorder code to create a working decision tree classifier.

  • Microsoft: Move from Traditional ASP.NET to 'Core' Requires 'Heavy Lifting'

    There are plenty of reasons to move traditional ASP.NET web apps -- part of the old .NET Framework -- to the new cross-platform direction, ASP.NET Core, but beware it will require some "heavy lifting," Microsoft says.

  • Purple Blue Nebula Graphic

    How to Compute Disorder for Machine Learning Decision Trees Using C#

    Using a decision tree classifier from a machine learning library is often awkward because it usually must be customized and library decision trees have many complex supporting functions, says resident data scientist Dr. James McCaffrey, so when he needs a decision tree classifier, he always creates one from scratch. Here's how.

  • Blazor's Future: gRPC Is Key

    Blazor guru Steve Sanderson detailed what Microsoft is thinking about the future of the revolutionary project that enables .NET-based web development using C# instead of JavaScript, explaining how gRPC is key, along with a new way of testing and a scheme for installable desktop apps.

.NET Insight

Sign up for our newsletter.

Terms and Privacy Policy consent

I agree to this site's Privacy Policy.

Upcoming Events