[prev in list] [next in list] [prev in thread] [next in thread] 

List:       subversion-users
Subject:    Re: Svnadmin dump with include will lost the svn:log in sometime
From:       Daniel Shahaf <d.s () daniel ! shahaf ! name>
Date:       2020-03-23 6:25:00
Message-ID: 20200323062500.3755e06f () tarpaulin ! shahaf ! local2
[Download RAW message or body]

钱海远(Nathan) wrote on Mon, 23 Mar 2020 05:56 +0000:
> The version is 1.10.6 , I was try to reproduce this issue.
> 
> You can make a commit like this :
> Revision 1
> A /test
> A /Test/a.c
> A /another
> A /another/b.c
> 
> Revision 2
> M /test/a.c
> M /another/b.c
> 
> Then run command : svnadmin dump svnroot include "/test"
> 
> Then it will happen.

Thanks, I can reproduce this with current trunk:

[[[
% svnadmin create r
% svnmucc -U file://$PWD/r mkdir foo mkdir bar put =(:) foo/iota put =(:) bar/kappa \
-mm % svnadmin dump r --include=/foo | grep -B1 -A2 svn:log
* Dumped revision 0.
* Dumped revision 1.
% svnadmin dump r | grep -B1 -A2 svn:log
* Dumped revision 0.
K 7
svn:log
V 1
m
* Dumped revision 1.
% 
]]]

I agree it makes sense to keep the log message, at least as an option.

I'll reopen SVN-4850 in a minute.

As to the cause, I stand corrected: it's indeed due to authz, exactly as
you said:

[[[
(lldb) n
Process 24108 stopped
* thread #1, name = 'svnadmin', stop reason = step over
    frame #0: 0x00007ffff7f9ba21 \
libsvn_repos-1.so.0`svn_repos_fs_revision_proplist(table_p=0x00007fffffffdd80, \
repos=0x00007ffff7deb4c0, rev=1, \
authz_read_func=(libsvn_repos-1.so.0`dump_filter_authz_func at dump.c:2010), \
authz_read_baton=0x00007fffffffdf50, pool=0x00007ffff66a7028) at fs-wrap.c:514  511   \
authz_read_func, authz_read_baton,  512                                            \
pool));  513 
-> 514    if (readability == svn_repos_revision_access_none)
   515      {
   516        /* Return an empty hash. */
   517        *table_p = apr_hash_make(pool);
(lldb) p readability
(svn_repos_revision_access_level_t) $0 = svn_repos_revision_access_partial
]]]

authz was set up internally by svn_repos_dump_fs4():

[[[
  2083	  /* We use read authz callback to implement dump filtering. If there is no
  2084	   * read access for some node, it will be excluded from dump as well as
  2085	   * references to it (e.g. copy source). */
  2086	  if (filter_func)
  2087	    {
  2088	      authz_func = dump_filter_authz_func;
  2089	      authz_baton.filter_func = filter_func;
  2090	      authz_baton.filter_baton = filter_baton;
  2091	    }
  2092	  else
  2093	    {
  2094	      authz_func = NULL;
  2095	    }
]]]

Nevertheless, we can't just make svn_repos_fs_revision_proplist()
include svn:log; that would make svnserve and mod_dav_svn expose
information that currently they do not.

I'm not sure what the easiest way to fix this is…

Cheers,

Daniel


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic