Checkout Tools
  • last updated 7 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates

Changeset 1567023 is being indexed.

For TXN IDs in FSX, use a single integer instead of a two-part struct.

This allows for packing the TXN ID into the same struct that holds

the revision info for committed data.

Most of this commit is code churn replacing (pointers to) structs with

the new integer value. Similarly, NULL values cannot be used anymore

and must be replaced by the new SVN_FS_X__INVALID_TXN_ID constant.

* subversion/libsvn_fs_x/id.h

(svn_fs_x__txn_id_t): Define the new data type for TXN IDs.

(SVN_FS_X__INVALID_TXN_ID): Define the corresponding NULL constant.

(svn_fs_x__id_txn_parse,

svn_fs_x__id_txn_unparse): Drop. These will be replaced by new

private API functions in utils.h

(svn_fs_x__id_txn_used,

svn_fs_x__id_txn_reset,

svn_fs_x__txn_id_t svn_fs_x__id_txn_id,

svn_fs_x__id_txn_create_root,

svn_fs_x__id_txn_create): Switch TXN_ID type in these APIs

from struct to integer type.

* subversion/libsvn_fs_x/id.c

(fs_x__id_t): Use the new data type to store the TXN_ID member.

(txn_id_parse): Simplify calling the new utils API function.

(svn_fs_x__id_txn_used,

svn_fs_x__id_txn_reset): Update function signature and "no value" handling.

(svn_fs_x__id_txn_parse,

svn_fs_x__id_txn_unparse): Drop.

(svn_fs_x__id_txn_id,

svn_fs_x__id_is_txn): Update function signatures and TXN_ID references.

(svn_fs_x__id_unparse): Update serializer to write the TXN_ID as a single

value instead of a value pair.

(svn_fs_x__id_eq): The struct has become smaller.

(svn_fs_x__id_check_related): TXN_ID-based checks are now simple.

(svn_fs_x__id_txn_create_root,

svn_fs_id_t *svn_fs_x__id_create_root): Update function signatures and

TXN_ID references.

(svn_fs_x__id_create_root,

svn_fs_x__id_rev_create,

svn_fs_x__id_parse): Update TXN_ID references and "no value" handling.

* subversion/libsvn_fs_x/util.h

(svn_fs_x__txn_name,

svn_fs_x__txn_by_name): Declare new utility API functions that

convert TXN IDs from / to string.

(svn_fs_x__path_txn_dir,

svn_fs_x__path_txn_sha1,

svn_fs_x__path_txn_changes,

svn_fs_x__path_l2p_proto_index,

svn_fs_x__path_p2l_proto_index,

svn_fs_x__path_txn_props,

svn_fs_x__path_txn_props_final,

svn_fs_x__path_txn_next_ids,

svn_fs_x__path_txn_item_index,

svn_fs_x__path_txn_proto_rev,

svn_fs_x__path_txn_proto_rev_lock): Switch TXN_ID type in these APIs

from struct to integer type.

* subversion/libsvn_fs_x/util.c

(svn_fs_x__txn_name,

svn_fs_x__txn_by_name): Implement these new conversion functions using

out base36 converters.

(combine_txn_id_string): Call the new TXN_ID -> string conversion API.

(svn_fs_x__path_txn_dir,

svn_fs_x__path_txn_sha1,

svn_fs_x__path_txn_changes,

svn_fs_x__path_l2p_proto_index,

svn_fs_x__path_p2l_proto_index,

svn_fs_x__path_txn_props,

svn_fs_x__path_txn_props_final,

svn_fs_x__path_txn_next_ids,

svn_fs_x__path_txn_item_index,

svn_fs_x__path_txn_proto_rev,

svn_fs_x__path_txn_proto_rev_lock): Switch TXN_ID types in function

signatures.

* subversion/libsvn_fs_x/cached_data.c

(open_and_seek_revision,

open_and_seek_transaction,

open_and_seek_representation,

get_node_revision_body,

svn_fs_x__get_mergeinfo_count,

create_rep_state_body,

build_rep_list,

auto_set_start_offset,

get_dir_contents,

svn_fs_x__get_proplist,

svn_fs_x__get_changes,

block_read): Update function callers to use numbers instead of

pointers for txn_ids.

* subversion/libsvn_fs_x/verify.c

(compare_l2p_to_p2l_index,

compare_p2l_to_l2p_index): Ditto.

* subversion/libsvn_fs_x/changes.c

(binary_change_t): Document mapping of TXN_IDs onto ID part structs.

(append_change,

svn_fs_x__changes_get_list,

svn_fs_x__changes_get_list_func): Change storage and retrieval of

TXN IDs accordingly.

* subversion/libsvn_fs_x/dag.h

(svn_fs_x__dag_set_entry,

svn_fs_x__dag_txn_root,

svn_fs_x__dag_txn_base_root,

svn_fs_x__dag_clone_child,

svn_fs_x__dag_clone_root,

svn_fs_x__dag_delete,

svn_fs_x__dag_make_file,

svn_fs_x__dag_make_dir,

svn_fs_x__dag_copy):

svn_fs_x__path_txn_proto_rev_lock): Switch TXN_ID type in these APIs

from struct to integer type.

* subversion/libsvn_fs_x/dag.c

(set_entry,

make_entry,

svn_fs_x__dag_set_entry,

svn_fs_x__dag_txn_root,

svn_fs_x__dag_txn_base_root,

svn_fs_x__dag_clone_child,

svn_fs_x__dag_clone_root,

svn_fs_x__dag_delete,

svn_fs_x__dag_make_file,

svn_fs_x__dag_make_dir,

svn_fs_x__dag_copy):

svn_fs_x__path_txn_proto_rev_lock): Switch TXN_ID types in function

signatures; they are all pass-

through values.

* subversion/libsvn_fs_x/fs.h

(fs_x_shared_txn_data_t,

representation_t): Use the new TXN_ID type instead of the old structs.

* subversion/libsvn_fs_x/index.h

(svn_fs_x__item_offset): Switch TXN_ID type from struct to integer type.

* subversion/libsvn_fs_x/index.c

(l2p_proto_index_lookup): Switch TXN_ID type in function signature; it is

a simple pass-through value.

(svn_fs_x__item_offset): Switch TXN_ID type in function signature and

update "no value" handling.

* subversion/libsvn_fs_x/low_level.c

(svn_fs_x__parse_representation,

read_rep_offsets,

svn_fs_x__unparse_representation,

svn_fs_x__unparse_representation): Adapt to TXN ID API changes.

* subversion/libsvn_fs_x/noderevs.c

(shared_representation_t): Use the new data type for the TXN ID member.

(svn_fs_x__write_noderevs_container,

svn_fs_x__read_noderevs_container): Simplify as we only need to write

and read single values instead of

structs for TXN IDs.

* subversion/libsvn_fs_x/transaction.h

(svn_fs_x__txn_get_id,

svn_fs_x__txn_changes_fetch,

svn_fs_x__get_txn,

svn_fs_x__reserve_copy_id,

svn_fs_x__create_node,

svn_fs_x__set_entry,

svn_fs_x__add_change,

svn_fs_x__create_successor,

svn_fs_x__get_txn_ids): Switch TXN_ID type from struct to integer type.

* subversion/libsvn_fs_x/transaction.c

(fs_txn_data_t): Use the new data type for the TXN ID member.

(svn_fs_x__txn_get_id): Update signature and TXN_ID reference.

(get_shared_txn,

free_shared_txn): Update signature, TXN_ID references and comparison.

(unlock_proto_rev_baton): Use the new data type for the TXN ID member.

(unlock_proto_rev_body): Update references to TXN_ID and use the new

utlis API to convert TXN_IDs into strings.

(unlock_proto_rev,

unlock_proto_rev_list_locked): Update signature and TXN_ID reference.

(get_writable_proto_rev_baton): Use the new data type for the TXN ID member.

(get_writable_proto_rev_body): Update references to TXN_ID and use the new

utlis API to convert TXN_IDs into strings.

(get_writable_proto_rev): Update signature and TXN_ID reference.

(purge_shared_txn_body,

purge_shared_txn): Switch baton from struct to pointer the new TXN_ID.

(store_sha1_rep_mapping): Update TXN_ID reference.

(svn_fs_x__txn_changes_fetch,

create_new_txn_noderev_from_rev): Update signatures.

(create_txn_dir): Update signatures as well as TXN_ID references and

use the new utlis API to convert a TXN_ID into string.

(svn_fs_x__create_txn): Update TXN_ID references.

(get_txn_proplist): Use new TXN_ID type in signature and update

TXN_ID value check.

(change_txn_props): Update TXN_ID references.

(svn_fs_x__get_txn,

write_next_ids,

read_next_ids,

get_new_txn_node_id,

svn_fs_x__reserve_copy_id,

svn_fs_x__create_node): Use new TXN_ID type in signature - pass-through

parameters only.

(svn_fs_x__purge_txn): Update TXN_ID references and types and use the new

utlis API to convert TXN_IDs into strings.

(set_uniquifier): Update TXN_ID reference.

(svn_fs_x__set_entry): Update signature and TXN_ID references.

(svn_fs_x__add_change,

store_l2p_index_entry,

store_p2l_index_entry,

allocate_item_index,

svn_fs_x__create_successor,

write_hash_delta_rep): Use new TXN_ID type in signature --

they are pass-through parameters only.

(get_shared_rep,

rep_write_contents_close,

svn_fs_x__set_proplist): Update TXN_ID references.

(write_hash_delta_rep): Use new TXN_ID type in signature --

they are pass-through parameters only

(write_final_rev): Use the new TXN_ID type internally and udapte

all TXN_ID references.

(write_final_changed_path_info,

verify_locks): Use new TXN_ID type in signature.

(verify_moves): Switch the signature to using the full TXN object

and get the base revision from that since TXN_IDs

don't provide this info anymore.

(write_final_revprop): Use new TXN_ID type in signature and adapt

to signature changes in called functions.

(svn_fs_x__open_txn,

svn_fs_x__delete_node_revision): Update references to TXN_IDs.

(svn_fs_x__get_txn_ids): Use new TXN_ID type in signature.

* subversion/libsvn_fs_x/tree.c

(fs_txn_root_data_t): Use the new data type for the TXN_ID member.

(make_txn_root): Use new TXN_ID type in signature.

(svn_fs_x__txn_id_t): Same and update TXN_ID reference.

(add_change,

merge): Use new TXN_ID type in signature.

(make_path_mutable,

x_change_node_prop,

x_make_dir,

x_delete_node): Use the correct TXN_ID type internally.

(copy_helper): Same and use the root objects to access the TXN

base revision because the TXN_ID does no longer

provide that information.

(x_make_file,

apply_textdelta,

apply_text): Use the correct TXN_ID type internally.

(make_txn_root): Update TXN_ID type in signature, update TXN_ID

references and call the new string conversion API.

  1. … 17 more files in changeset.
Store revision values in FSX change lists containers as signed integers

instead of unsigned ones.

* subversion/libsvn_fs_x/changes.c

(svn_fs_x__write_changes_container,

svn_fs_x__read_changes_container): use "int" instead of "uint" for revs

Silence a number of integer size conversion warnings by casting the output

of our rather generic reader functions to the correct target type.

* subversion/libsvn_fs_x/string_table.c

(svn_fs_x__read_string_table): explicitly cast to the target type

* subversion/libsvn_fs_x/reps.c

(svn_fs_x__read_reps_container): ditto

* subversion/libsvn_fs_x/noderevs.c

(svn_fs_x__read_noderes_container): ditto

* subversion/libsvn_fs_x/changes.c

(svn_fs_x__read_changes_container): ditto

* subversion/libsvn_subr/packed_data.c

(svn_packed__get_bytes): ditto

  1. … 4 more files in changeset.
Localized strings must not contain preprocessor macros.

* subversion/libsvn_fs_x/noderevs.c

(svn_fs_x__noderevs_get,

read_reps): use the double-escape trick for localized strings

as we already do in other places

* subversion/libsvn_fs_x/changes.c

(svn_fs_x__changes_get_list): ditto

* subversion/svnserve/serve.c

(log_cmd): ditto

* subversion/libsvn_fs_x/index.c

(l2p_page_get_offset): ditto; had to provide a pool

(l2p_page_access_func,

l2p_index_lookup): update callers

Found by: Mattias Engdegård <mattiase@bredband.net>

  1. … 3 more files in changeset.
[Reverted in r1597989]

Add MOVe support to FSX. This is mainly duplicating changes from FSFS.

* subversion/libsvn_fs_x/changes.c

(CHANGE_KIND_MOVE,

CHANGE_KIND_MOVEREPLACE): pro forma declaration of the new change kinds

* subversion/libsvn_fs_x/low_level.c

(ACTION_MOVE,

ACTION_MOVEREPLACE): declare new change type strings

(read_change,

write_change_entry): write / parse the new change types

* subversion/libsvn_fs_x/transaction.c

(replace_change): factored out from ...

(fold_change): ... this one; handle moves similar to adds

(process_changes): handle move-replaces similar to replaces

(write_final_changed_path_info): update move source revs to Rev-1;

make changed_paths an input parameter

(check_for_duplicate_move_source,

verify_moves): new move verification code

(commit_body): verify moves when finalizing the commit;

update function all

* subversion/libsvn_fs_x/tree.c

(enum copy_type_t): declare new parameter type

(copy_helper): support moves just like ADDs; add extra param checks

(x_copy,

x_revision_link): update callers

(x_move): add new function for MOVes

  1. … 3 more files in changeset.
* subversion/bindings/javahl/native/CommitEditor.h

* subversion/bindings/javahl/native/EditorProxy.h

* subversion/bindings/javahl/native/Iterator.h

* subversion/bindings/javahl/native/LockTokenTable.h

* subversion/bindings/javahl/native/RemoteSession.h

* subversion/bindings/javahl/native/RemoteSessionContext.h

* subversion/bindings/javahl/native/RevisionRangeList.h

* subversion/bindings/javahl/native/StateReporter.h

* subversion/include/private/svn_file.h

* subversion/include/private/svn_packed_data.h

* subversion/libsvn_fs_fs/cached_data.c

* subversion/libsvn_fs_fs/cached_data.h

* subversion/libsvn_fs_fs/hotcopy.c

* subversion/libsvn_fs_fs/hotcopy.h

* subversion/libsvn_fs_fs/low_level.c

* subversion/libsvn_fs_fs/low_level.h

* subversion/libsvn_fs_fs/pack.c

* subversion/libsvn_fs_fs/pack.h

* subversion/libsvn_fs_fs/recovery.c

* subversion/libsvn_fs_fs/recovery.h

* subversion/libsvn_fs_fs/revprops.c

* subversion/libsvn_fs_fs/revprops.h

* subversion/libsvn_fs_fs/transaction.c

* subversion/libsvn_fs_fs/transaction.h

* subversion/libsvn_fs_fs/util.c

* subversion/libsvn_fs_fs/util.h

* subversion/libsvn_fs_fs/verify.c

* subversion/libsvn_fs_fs/verify.h

* subversion/libsvn_fs_x/cached_data.c

* subversion/libsvn_fs_x/cached_data.h

* subversion/libsvn_fs_x/changes.c

* subversion/libsvn_fs_x/changes.h

* subversion/libsvn_fs_x/hotcopy.c

* subversion/libsvn_fs_x/hotcopy.h

* subversion/libsvn_fs_x/index.c

* subversion/libsvn_fs_x/index.h

* subversion/libsvn_fs_x/low_level.h

* subversion/libsvn_fs_x/noderevs.c

* subversion/libsvn_fs_x/noderevs.h

* subversion/libsvn_fs_x/pack.c

* subversion/libsvn_fs_x/pack.h

* subversion/libsvn_fs_x/recovery.c

* subversion/libsvn_fs_x/recovery.h

* subversion/libsvn_fs_x/reps.c

* subversion/libsvn_fs_x/reps.h

* subversion/libsvn_fs_x/revprops.h

* subversion/libsvn_fs_x/string_table.c

* subversion/libsvn_fs_x/string_table.h

* subversion/libsvn_fs_x/transaction.c

* subversion/libsvn_fs_x/transaction.h

* subversion/libsvn_fs_x/util.h

* subversion/libsvn_ra_svn/deprecated.c

* subversion/libsvn_subr/compress.c

* subversion/libsvn_subr/file.c

* subversion/libsvn_subr/packed_data.c

* subversion/libsvn_subr/prefix_string.c

* subversion/libsvn_subr/utf8proc/utf8proc.c

* subversion/libsvn_subr/utf8proc/utf8proc.h

* subversion/libsvn_subr/utf8proc/utf8proc_data.c

* subversion/libsvn_subr/utf8proc.c

* subversion/tests/libsvn_fs_x/string-table-test.c

* subversion/tests/libsvn_subr/packed-data-test.c

* subversion/tests/libsvn_subr/prefix-string-test.c

* subversion/tests/libsvn_subr/priority-queue-test.c

(svn:eol-style): Set to native.

  1. … 63 more files in changeset.
Merge fsx branch into /trunk with no conflicts.

Remove BRANCH-README.

  1. … 83 more files in changeset.