Need help understanding some basic terminology and App IDs

Is there a glossary or some kind of high-level architectural diagram that describes Holochain?

I see the whitepaper, but I’m looking for something a little more practical to digest.

Specifically, here’s what I want to know –

What is an App, and how does it relate to DNA / Zomes, Agents, and Cells?

I know you can install an app, which takes as an input:

  • an app ID
  • an agent key
  • a list of DNAs

I’m guessing a “Cell” is essentially an instantiation of a “Zome” within an app; once a Zome’s “DNA” is installed, it becomes related to the installation for that particular agent, and each can be referenced by a Cell ID. Cells also have a human-readable nickname.

Questions:

What is the best practice for choosing an App ID? What happens if two separate developers choose the same App ID for different apps?

Where does the DNA actually live once installed? In a DHT somewhere? I see that you can activate and deactivate an app, but can you uninstall an app? What if I need to modify and recompile some DNA related to an App?

How do you coordinate upgrades? There seem to be a couple moving targets: the holochain version, as well as the version of each zome for each agent. How will apps maintain forward compatibility with changes to holochain, and how will compatibility between agents be coordinated?

For example, I managed to get the Elemental chat running locally, but had to run through a few headaches making sure that the holochain version matched both the holochain conductor API as well as the Elemental Chat zome’s dependency on the HDK crate.

Insight into any of the questions above is most welcome. Thank you!

I’ve been doing some exploring and have been able to answer a few of my own questions:

How do you coordinate upgrades?

Seems like this is still being explored. But basically, have a “DNAUpdate” entry with a validation function that checks against a developer key, then somehow applies the update.

Post: Versioned Releases
Migration RFC: https://hackmd.io/5OQgaCSbSvWj4eqiHmV27Q

I don’t understand how you could do this with the current HDK though. Can you update the DNA of an existing App ID, or would you have to generate another App ID? I seem to remember calling installApp through the admin interface generated an error when reusing the same App ID.

So I’m still a bit confused about App IDs.

I figured out some more stuff this weekend.

The reason install_app requires the agent key is just to keep track of which agent originally installed the app. For some reason, I thought each agent had to install their own version of the app but that does not seem to be case!

Once “DNA” is successfully installed, it has both a Cell ID and Cell Handle (aka “nickname”).

What’s really interesting, is that DNA installation is separate from App Installation. Presumably, you could install DNA, then share those “cells” with multiple apps. Pretty cool!