Re: Reason for not using auto-incrementing id field?

2018-02-13 Thread Blake Regalia
Thanks Sebastian, I was also curious if someone ran perf tests for this. Good to know! I can see how it would speed up bulk importing if (1) the importer assumes the ids of existing nodes will not change during execution and (2) keeps a synced mapping of datatype and predicate ids in memory and

Re: Reason for not using auto-incrementing id field?

2018-02-13 Thread Sebastian Schaffert
Hi Blake, I did performance tests back then, it actually makes a significant difference on most databases, especially for batch imports. Even more if the database is not running on localhost. Not sure about the actual numbers though. You can always switch to the database sequence generator for

Re: Reason for not using auto-incrementing id field?

2018-02-13 Thread Blake Regalia
I can see how this makes sense for future compatibility with distributed systems across a variety of RDBMS, although I'm not convinced it's more efficient for single nodes (e.g., auto-incrementing fields do not require round trips). Thanks for the reply! Just wanted to know while porting a bulk

Re: Reason for not using auto-incrementing id field?

2018-02-13 Thread Sebastian Schaffert
Hi Blake, Auto-increment requires querying the database for the next sequence number (or the last given ID, depending on the database you use), and that's adding another database roundtrip. Snowflake is purely in code, very fast to compute, and safe even in distributed setups. Is it causing

Reason for not using auto-incrementing id field?

2018-02-13 Thread Blake Regalia
What was the justification for using the 'snowflake' bigint type for the id fields on nodes, triples and namespaces? - Blake