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

Re: ATTENTION: Working Copy format bump (was: svn commit: r36264 ...)

From: Hyrum K. Wright <hyrum_wright_at_mail.utexas.edu>
Date: Mon, 2 Mar 2009 15:49:35 -0600

On Mar 2, 2009, at 3:45 PM, Greg Stein wrote:

> Attention everybody:
>
> If you're building clients from /trunk/, then this will bump the
> working copy format from 10 to 11. This will cause 1.6 clients to
> *not* be able to read the working copy.
>
> The format will be silently upgraded as soon as you do a "write"
> operation, such as an update or commit. Operations like "svn status"
> will not update the format.

It should also be noted that in 1.7-final, we won't be silently
upgrading working copies. The code to detect and warn about this
condition just hasn't been written yet.

> There is no "real" format change, but trunk no longer manages some of
> the fields in 'entries' like it used to. Yet 1.6 expects those fields
> to have proper values. Thus... the bump.
>
> Cheers,
> -g
>
> On Mon, Mar 2, 2009 at 22:36, Greg Stein <gstein_at_gmail.com> wrote:
>> Author: gstein
>> Date: Mon Mar 2 13:36:46 2009
>> New Revision: 36264
>>
>> Log:
>> Bump the working copy format from 10 to 11.
>>
>> Clients expect the 'entries' file to have properly managed
>> 'has_props'
>> and 'has_prop_mods' fields. These are no longer set by trunk-based
>> clients, so we need a bump to prevent older clients from reading
>> 'entries'
>> and assuming its values are proper.
>>
>> Note that trunk does not maintain 'cachable_props' and
>> 'present_props' in
>> the entries file. However, the values (now) placed into those
>> fields ("")
>> should be usable by older clients. But it is moot with the format
>> bump.
>>
>> As of this bump, 1.6 clients will produce an error when attempting to
>> access trunk-created working copies. When a trunk client opens a .svn
>> subdirectory for *writing*, then it will silently bump the version.
>>
>> * subversion/libsvn_wc/wc.h:
>> (SVN_WC__VERSION): bump the value. add comments.
>> (SVN_WC__VERSION_EXPERIMENTAL): bump up to 12.
>> (SVN_WC__WC_NG_VERSION): bump to 12.
>>
>> * subversion/libsvn_wc/entries.c:
>> (upgrade_sql): insert another NULL placeholder for format=11
>>
>> * subversion/libsvn_wc/wc_db.c:
>> (upgrade_sql): insert another NULL placeholder for format=11
>>
>> * subversion/tests/libsvn_wc/db-test.c:
>> (data_loading_sql): insert another NULL placeholder for format=11
>>
>> Modified:
>> trunk/subversion/libsvn_wc/entries.c
>> trunk/subversion/libsvn_wc/wc.h
>> trunk/subversion/libsvn_wc/wc_db.c
>> trunk/subversion/tests/libsvn_wc/db-test.c
>>
>> Modified: trunk/subversion/libsvn_wc/entries.c
>> URL: http://svn.collab.net/viewvc/svn/trunk/subversion/libsvn_wc/entries.c?pathrev=36264&r1=36263&r2=36264
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =====================================================================
>> --- trunk/subversion/libsvn_wc/entries.c Mon Mar 2 13:12:49
>> 2009 (r36263)
>> +++ trunk/subversion/libsvn_wc/entries.c Mon Mar 2 13:36:46
>> 2009 (r36264)
>> @@ -48,8 +48,12 @@
>>
>> #define MAYBE_ALLOC(x,p) ((x) ? (x) : apr_pcalloc((p),
>> sizeof(*(x))))
>>
>> -static const char * const upgrade_sql[] = { NULL, NULL, NULL,
>> NULL, NULL,
>> - NULL, NULL, NULL, NULL, NULL, NULL, WC_METADATA_SQL };
>> +static const char * const upgrade_sql[] = {
>> + NULL, NULL, NULL, NULL, NULL,
>> + NULL, NULL, NULL, NULL, NULL,
>> + NULL, NULL,
>> + WC_METADATA_SQL
>> +};
>>
>> /* This values map to the members of STATEMENTS below, and should
>> be added
>> and removed at the same time. */
>>
>> Modified: trunk/subversion/libsvn_wc/wc.h
>> URL: http://svn.collab.net/viewvc/svn/trunk/subversion/libsvn_wc/wc.h?pathrev=36264&r1=36263&r2=36264
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =====================================================================
>> --- trunk/subversion/libsvn_wc/wc.h Mon Mar 2 13:12:49
>> 2009 (r36263)
>> +++ trunk/subversion/libsvn_wc/wc.h Mon Mar 2 13:36:46
>> 2009 (r36264)
>> @@ -70,19 +70,24 @@ extern "C" {
>> * and sticky depth (for selective/sparse checkouts).
>> *
>> * The change from 9 to 10 was the addition of tree-conflicts, file
>> - * externals and a different canonicalization of urls.
>> + * externals and a different canonicalization of urls. Shipped in
>> 1.6.
>> *
>> - * The change from 10 to 11 was a complete rewrite of the wc
>> datastore,
>> + * The change from 10 to 11 was clearing the has_props,
>> has_prop_mods,
>> + * cachable_props, and present_props values in the entries file.
>> Older
>> + * client expect proper values for these fields. Note: this change
>> + * occurred during 1.7 development, and is not expected to be
>> released.
>> + *
>> + * The change from 11 to 12 was a complete rewrite of the wc
>> datastore,
>> * which resulted in centralization and migration of data to an
>> sqlite
>> - * datebase.
>> + * datebase. Shipped in 1.7.
>> *
>> * Please document any further format changes here.
>> */
>>
>> -#define SVN_WC__VERSION 10
>> +#define SVN_WC__VERSION 11
>>
>> /* ### only used by devs temporarily during 1.7 development. */
>> -#define SVN_WC__VERSION_EXPERIMENTAL 11
>> +#define SVN_WC__VERSION_EXPERIMENTAL 12
>>
>>
>> /* A version <= this doesn't have property caching in the entries
>> file. */
>> @@ -99,7 +104,7 @@ extern "C" {
>> #define SVN_WC__CHANGED_CANONICAL_URLS 10
>>
>> /* A version < this is pre-wc-ng. */
>> -#define SVN_WC__WC_NG_VERSION 11
>> +#define SVN_WC__WC_NG_VERSION 12
>>
>> /*** Update traversals. ***/
>>
>>
>> Modified: trunk/subversion/libsvn_wc/wc_db.c
>> URL: http://svn.collab.net/viewvc/svn/trunk/subversion/libsvn_wc/wc_db.c?pathrev=36264&r1=36263&r2=36264
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =====================================================================
>> --- trunk/subversion/libsvn_wc/wc_db.c Mon Mar 2 13:12:49
>> 2009 (r36263)
>> +++ trunk/subversion/libsvn_wc/wc_db.c Mon Mar 2 13:36:46
>> 2009 (r36264)
>> @@ -137,8 +137,12 @@ struct svn_wc__db_pdh_t {
>> #define SVN__SKIP_SUBDIR
>>
>> /* ### duplicates entries.c */
>> -static const char * const upgrade_sql[] = { NULL, NULL, NULL,
>> NULL, NULL,
>> - NULL, NULL, NULL, NULL, NULL, NULL, WC_METADATA_SQL };
>> +static const char * const upgrade_sql[] = {
>> + NULL, NULL, NULL, NULL, NULL,
>> + NULL, NULL, NULL, NULL, NULL,
>> + NULL, NULL,
>> + WC_METADATA_SQL
>> +};
>>
>> /* These values map to the members of STATEMENTS below, and should
>> be added
>> and removed at the same time. */
>>
>> Modified: trunk/subversion/tests/libsvn_wc/db-test.c
>> URL: http://svn.collab.net/viewvc/svn/trunk/subversion/tests/libsvn_wc/db-test.c?pathrev=36264&r1=36263&r2=36264
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =====================================================================
>> --- trunk/subversion/tests/libsvn_wc/db-test.c Mon Mar 2 13:12:49
>> 2009 (r36263)
>> +++ trunk/subversion/tests/libsvn_wc/db-test.c Mon Mar 2 13:36:46
>> 2009 (r36264)
>> @@ -58,7 +58,7 @@
>> #define SHA1_1 "aaf4c61ddcc5e8a2dabede0f3b482cd9aea9434d"
>>
>> static const char * const data_loading_sql[] = {
>> - NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
>> + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
>> NULL, NULL,
>> (
>> /* Load the table and index definitions. */
>> WC_METADATA_SQL
>>
>> ------------------------------------------------------
>> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=495&dsMessageId=1258377
>>
>
> ------------------------------------------------------
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=495&dsMessageId=1258398

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1258414
Received on 2009-03-02 22:50:19 CET

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.