-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better data model and optimized indexing #218
Conversation
I would have used http://www.nuget.org/packages/RavenDB.Tests.Helpers but nuget is misbehaving
Critical/Processing/Delivery times were stored by strings. This commit stores them as numerics by using Ticks. Also using the null-value pattern for when there's no data to store instead of using 0's.
This affects QueryableExtensions.Sort being used from GetMessagesByQuery. Need to figure out if this is a wanted effect; also, no secondary sorts are supported.
Removing a recursive call in on of the maps
Changed PR title. This is still WIP but now directed more towards data model and indexing best-practices and optimizations |
@johnsimons this PR seems to get bloated and go sideways. Can we merge it in before it becomes stale and then work off it to get more refactoring done (I'll discuss some of them with you tomorrow)? |
Yep, I can bring it in today On Thursday, 13 February 2014, Itamar Syn-Hershko notifications@github.com
|
{ | ||
return negotiator | ||
.WithHeader("QueryTimeMs", stats.DurationMilliseconds.ToString(CultureInfo.InvariantCulture)) | ||
.WithHeader("IsStale", stats.IsStale.ToString()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are these just for diagnostics?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, maybe staleness can be reflected in the UIs as well
Time counters and datestamps are not properly indexed and hence can't be properly queried (using ranges etc). Sorting on times did work because it was stored as strings that were lexicographically ordered, but there wasn't much that could have been done with it.
What I do here is move to using RavenDB best practices as well as fix bugs that weren't yet discovered as querying isn't fully implemented. I may even write some more tests if I'll be in the mood. I have more details in the individual commits.
This is still WIP as I work my way around the data that is being indexed for messages and fix the indexing and querying as I go along.
Comments welcome.