git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v4 0/1] receive-pack: optionally deny case clone refs

From
Ronnie Sahlberg <sahlberg@google.com>
Date
Aug 13, 2014, 16:20 UTC
Message-ID
<CAL=YDW=5ynUFFLVNAG=M9x-DRyEyM2q=GPVxzxHVPYDNGHYm=A@mail.gmail.com>
In-Reply-To
<1402525838-31975-1-git-send-email-dturner@twitter.com>
David,

One possible solution can be to use the external database daemon I am working of for ref transactions. Since this makes all refs be stored in a dedicated database instead of the filesystem you no longer are dependent on file system semantics.

While not in the official git trees yet I would appreciate any testing and comments you may have it you want to test it. https://github.com/rsahlberg/git/tree/backend-struct-db-2

Not for production use but seeing if it does build and works on your platforms would be great.

    refsd-tdb: example refs database daemon
    refsd-tdb.c is a simple reference implementation of a refs daemon.
    This will eventually be hosted in a separate project but can live in this
    branch for now.
    Compile with :
    gcc refsd-tdb.c -o refsd-tdb -l tdb
    Run with:
    ./refsd-tdb /tmp/refsd.socket /tmp /tmp/refsd.log
    Once the refs daemon is running you can start using it with newly
    created git repositories by specifying the --db-socket and --db-repo-name
    arguments to git clone/init-db :
    git clone --db-repo-name=ROCKy --db-socket=/tmp/refsd.socket <some repo> .
    This refs daemon is an example. It should be relatively straightforward
    to modify it to attach to any other kind of data store.

regards ronnie sahlberg

On Wed, Jun 11, 2014 at 3:30 PM, David Turner <dturner@twopensource.com> wrote:
Show 17 quoted lines
> This issue bit us again recently.
>
> In talking with some colleagues, I realized that the previous version
> of this patch, in addition to being potentially slow, was incomplete.
> Specifically, it didn't handle the case of refs/heads/case/one vs
> refs/heads/CASE/two; these are case clones even though they strcasecmp
> different.
>
> This new version contains code to prevent this, as well as tests for
> this case.
>
> Also it uses a hashmap to make lookups constant-time.
>
> --
> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous: Ronnie SahlbergNext: David Turner
Message 17 of 18 in “receive-pack: optionally deny case clone refs”
  1. 0/1 receive-pack: optionally deny case clone refsDavid Turner, Jun 11, 2014
  2. 1/1 receive-pack: optionally deny case clone refsDavid Turner, Jun 11, 2014
  3. Torsten BögershausenJun 13, 2014
  4. Junio C HamanoJun 12, 2014
  5. David TurnerJun 12, 2014
  6. Torsten BögershausenJun 13, 2014
  7. Junio C HamanoJun 13, 2014
  8. Junio C HamanoJun 13, 2014
  9. Ronnie SahlbergJun 13, 2014
  10. Ronnie SahlbergJun 13, 2014
  11. Junio C HamanoJun 13, 2014
  12. Ronnie SahlbergJun 13, 2014
  13. David TurnerJun 15, 2014
  14. Junio C HamanoJun 13, 2014
  15. Michael HaggertyJun 18, 2014
  16. Ronnie SahlbergJun 18, 2014
  17. Ronnie SahlbergAug 13, 2014
  18. David TurnerAug 13, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.