SnowMaker icon indicating copy to clipboard operation
SnowMaker copied to clipboard

Using a TokenCredential for the Blob Store

Open endintiers opened this issue 1 year ago • 7 comments

Hiya Tatham,

I want to use SnowMaker with Neo4jClient (it just makes sense - Guid Indexes are DEEP).

BUT. My Ops Manager really hates using Keys - its all

            // Get a credential and create a service client object for the blob container.
            _containerClient = new BlobContainerClient(new Uri(containerEndpoint), AuthService.TokenProvider);

with us.

I guess: I should just fork, add that and do a PR? - Unless you have/done wanna/doit?

  • Chris :-)

endintiers avatar Mar 14 '23 03:03 endintiers

👋 I haven't meaningfully touched this repo since 2013 sorry. I think I should likely mark it as "Archived" in GitHub, and let somebody else choose to fork / evolve it.

tathamoddie avatar Mar 14 '23 03:03 tathamoddie

No Problemo. Got any other suggestions? - Going to make a Neo4j DB with a billion nodes, need unique keys, also need index speed/size to be small as possible.

endintiers avatar Mar 14 '23 03:03 endintiers

Actually, maybe https://github.com/tathamoddie/SnowMaker/pull/13 does what you want already?

tathamoddie avatar Mar 14 '23 03:03 tathamoddie

Close enough (DefaultCredential will do for now). A month ago? classic. I'll try it out - want me to review?

endintiers avatar Mar 14 '23 03:03 endintiers

Sounds good!

tathamoddie avatar Mar 14 '23 03:03 tathamoddie

Alternatively:

  1. Why do you need a unique ID? Many Neo4j/graph models don't actually. They can be a bit of a "but I did this in SQL" smell. There's already an internal ID for each node.
  2. Try apoc.create.uuid in Neo4j directly (https://neo4j.com/labs/apoc/4.2/graph-updates/uuid/#manual-uuids)
  3. Try applying a unique constraint on the label and bulk applying that way (see https://neo4j.com/labs/apoc/4.2/graph-updates/uuid/#_uuid_examples)

For bulk creation, consider an import approach instead of firing a billion calls over the wire: https://neo4j.com/docs/getting-started/current/data-import/

tathamoddie avatar Mar 14 '23 03:03 tathamoddie

Heh, well yes, I DO happen to be migrating from a SQL DB to Neo4j... So, I just assumed I would need some Unique Id for each node - can I trust the Neo4j Ids?? I will need a bunch-o-indexes on other fields in various Node types.

Every class will normally have a REAL key like email address or source Uri. In SQL we generate keys mostly to use in junction tables which in a Graph DB are just the Edges.... so often no need for a manufactured key...

endintiers avatar Mar 14 '23 04:03 endintiers