Difference between revisions of "Features/Plain Query Format"
Line 41: | Line 41: | ||
* ''timestamp'' supports ranges | * ''timestamp'' supports ranges | ||
* ''keep'' | * ''keep'' | ||
+ | * ''filesize'' supports ranges (TODO: propose adding this field) | ||
==== Users predefined terms ==== | ==== Users predefined terms ==== |
Revision as of 12:41, 17 July 2009
Summary
Provide simple string query format for Datastore find() method to cover all kinds of requests.
Owner
- Name: Aleksey Lim
- Email: send an email
Current status
- Targeted release: 0.86
- Last updated: Fri Jul 17 06:34:13 UTC 2009
- Percentage of completion: 0%
Detailed Description
Instead of having complicated query format for org.laptop.sugar.DataStore::find(), use plane string full featured query format i.e. use all system query parameters(like timestamp, mime_type etc.) with user query string(from former find()'s 'query' argument).
All system, users predefined and some(its up to user) of users query terms will use prefixes like mime_type:"text/plain" or ctime:<date1>..<date2>
System terms
- tree_id
- version_id
- parent_id
- ctime supports ranges
- bundle_id
- entry_type
- creator
- mime_type
- title
- activity_id
- timestamp supports ranges
- keep
- filesize supports ranges (TODO: propose adding this field)
Users predefined terms
- artist
- album
- author and also composer
- date
- genre
- track_number
- track_count
- disc_number
- disc_count
- copyright
Benefit to Sugar
- simple(plane string in comparing with existed API with dictionary find()'s argument) query format for dbus find() method
- simple and new-feature-proof way to implement find method for example in CLI tools(because this tool needs only to pass plane string to Datastore service)
- let experienced users make complicated search in Journal etc.
- existed implementation has hard-coded logic for example in case of having several mime_types in query(all mime_types will be ORed despite what user wants).
Scope
Datastore implementation and new API.
How To Test
This does not need to be a full-fledged document. Describe the dimensions of tests that this feature is expected to pass when it is done. If it needs to be tested with different hardware or software configurations, indicate them. The more specific you can be, the better the community testing can be.
Remember that you are writing this how to for interested testers to use to check out your feature - documenting what you do for testing is OK, but it's much better to document what *I* can do to test your feature.
A good "how to test" should answer these four questions:
- What special hardware / data / etc. is needed (if any)?
- How do I prepare my system to test this feature? What packages need to be installed, config files edited, etc.?
- What specific actions do I perform to check that the feature is working like it's supposed to?
- What are the expected results of those actions?
User Experience
If this feature is noticeable by its target audience, how will their experiences change as a result? Describe what they will see or notice.
Dependencies
What other packages (RPMs) depend on this package? Are there changes outside the developers' control on which completion of this feature depends? In other words, completion of another feature owned by someone else and might cause you to not be able to finish on time or that you would need to coordinate? Other upstream projects like python?
Contingency Plan
None necessary, revert to previous release behaviour.
Documentation
Release Notes
The Sugar Release Notes inform end-users about what is new in the release. An Example is 0.84/Notes. The release notes also help users know how to deal with platform changes such as ABIs/APIs, configuration or data file formats, or upgrade concerns. If there are any such changes involved in this feature, indicate them here. You can also link to upstream documentation if it satisfies this need. This information forms the basis of the release notes edited by the release team and shipped with the release.