Giter Site home page Giter Site logo

Comments (7)

Vervious avatar Vervious commented on July 18, 2024

@ian-algorand

from go-algorand.

zeldovich avatar zeldovich commented on July 18, 2024

I think submodules are somewhat clunky.

An alternative proposal would be to fork off libsodium-fork, along with a minimal Go shim around it, into a separate repo, and import that using dep vendoring (or, eventually, using Go modules). I think that fits into our dependency management plan better.

from go-algorand.

jecassis avatar jecassis commented on July 18, 2024

If I may add my own experience from wrestling with this same issue in the past. I would also like to preface this by saying that the code base I was working on consisted of about 120 "subrepos" and tens of millions of LOC so it might be overkill for go-algorand's purposes and due to confidentiality I can't go into too much of the implementation details.

The first thing we looked at is git submodule and almost immediately discarded that idea. As Alex said, too clunky, slow, won't play nice with branches, but worse of all requires constant developer tracking of the upstream code base and does not support versioning (at least easily).

What we came up with eventually relied on git tag and a repo tags file (not unlike NPM, except it didn't exist at that time). Then using git hook and some Perl glue we made it seamless to the developer team. This also had the advantage of extremely fast integration builds and tests using prebuilt binaries for any subrepo which was not touched (looking at Travis logs I think you already do something similar). And another nice feature was that one didn't need to git clone all 120 subrepos to bootstrap a dev environment because the hooks and the Makefile generator knew where to look.

Circling back to your dilemma, and this is where I'll show my ignorance as an outsider, these would be my questions to you: Do you really need to import the source? Can you just have prebuilt library releases in a separate repo and just link them? Does it matter if you have a monorepo or two sister repos?

If nothing else, I hope this gives you some ideas or you have a good laugh :)

from go-algorand.

tsachiherman avatar tsachiherman commented on July 18, 2024

If I may add my own experience from wrestling with this same issue in the past. I would also like to preface this by saying that the code base I was working on consisted of about 120 "subrepos" and tens of millions of LOC so it might be overkill for go-algorand's purposes and due to confidentiality I can't go into too much of the implementation details.

The first thing we looked at is git submodule and almost immediately discarded that idea. As Alex said, too clunky, slow, won't play nice with branches, but worse of all requires constant developer tracking of the upstream code base and does not support versioning (at least easily).

What we came up with eventually relied on git tag and a repo tags file (not unlike NPM, except it didn't exist at that time). Then using git hook and some Perl glue we made it seamless to the developer team. This also had the advantage of extremely fast integration builds and tests using prebuilt binaries for any subrepo which was not touched (looking at Travis logs I think you already do something similar). And another nice feature was that one didn't need to git clone all 120 subrepos to bootstrap a dev environment because the hooks and the Makefile generator knew where to look.

Circling back to your dilemma, and this is where I'll show my ignorance as an outsider, these would be my questions to you: Do you really need to import the source? Can you just have prebuilt library releases in a separate repo and just link them? Does it matter if you have a monorepo or two sister repos?

If nothing else, I hope this gives you some ideas or you have a good laugh :)

@jecassis, I think that there are two requirement that we absolutely need :

  • Traceability - we need to be able to show what is the complete source code that was used to build our product. Using mystery, non-versioned library binaries defeat that goal. Versioned libraries are good only as long as their source code is available.
  • Reusability - we need to make sure that all the resources that builds up our product and be re-evaluated from the ground-up. The best way to make sure this is the case is to compile the entire source code. ( which also give you control on which compiler you use )

Reflecting back, I can recall several companies I worked for, which failed with the above ( mystery library that cannot be rebuilt, etc.). These scenarios rarely plays into the company best interest.

from go-algorand.

jecassis avatar jecassis commented on July 18, 2024

Commendable goals, to be sure. Thanks for the explanation!

from go-algorand.

ian-algorand avatar ian-algorand commented on July 18, 2024

The Dev Ops team has determined that this is no longer applicable, we won't be implementing this issue. Also, no activity for 2 years, stale issue.

from go-algorand.

 avatar commented on July 18, 2024

I have some concerns about this too. It appears that you are falling behind upstream libsodium as well. Wouldn't a patchfile or something make more sense to be able to integrate with upstream directly?

from go-algorand.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.