[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: svn:original-date

From: Branko Čibej <brane_at_xbc.nu>
Date: 2003-03-18 20:44:29 CET

cmpilato@collab.net wrote:

>=?UTF-8?B?QnJhbmtvIMSMaWJlag==?= <brane@xbc.nu> writes:
>
>
>>I'd rather introduce this index and lift the restriction on svn:date
>>than add another date property.
>>
>>
>
>+1, almost. Would rather do DATE->TXN_ID (that way we can get both
>committed and uncommitted transactions).
>
>We can do so in a backwards-compatible fashion, too.
>svn_fs_create_berkeley will create and populate this table.
>svn_fs_open_berkeley will not. Then, we make a new public FS call,
>
> svn_error_t *svn_fs_dated_revision (svn_revnum_t *rev,
> svn_fs_t *fs,
> apr_time_t tm,
> int direction,
> apr_pool_t *pool);
>
>(where direction is used to determine which way to search for a
>revision when TM falls between two of them.)
>

Or when several txns have the same time. That can happen.

>This function can use cursors to find the closest transaction in the
>transaction table that is of type "committed". Later, if we need
>svn_fs_dated_transaction, it does the same thing, but looks for
>"transaction"-typed transaction instead. The function also returns
>SVN_ERR_UNSUPPORTED_FEATURE if the new table doesn't exist.
>
>svn_repos_dated_revision() can try svn_fs_dated_revision, and then
>fall back to its current brute-force method if
>SVN_ERR_UNSUPPORTED_FEATURE is returned.
>
Sounds like a plan.

>NOTE: If, however, we don't think we'll ever need the perfect sorting
>of all transactions (including committed ones), ignore some of this
>and just do DATE->REVNUM -- that'd be more efficient.
>
>

I don't think this would be a real efficiency problem, and I like the
flexibility of the date->txn index better (think about new txn types for
distributed repository synchronization, microbranches for changesets and
similar esoteric stuff that'll hopefully become quite mundane by 2.0).

-- 
Brane Čibej   <brane_at_xbc.nu>   http://www.xbc.nu/brane/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Mar 18 20:47:27 2003

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.