Closed 123joshuawu closed 4 years ago
kg_node_label
to represent node labelkg_node_label_edge
for node label <-> node label edgesIf this is not missing anything then I will begin implementing the PostgresCommandStore
Updated diagram: https://dbdesigner.page.link/GQ3U7bmCH6nfy7oi9
Use text
instead of varchar(n)
, there's no reason to limit the length of those fields. I assume text
can still be a primary key.
page_rank should be real
(aka float4
), those don't need 8-byte precision.
It'd be nice to have some marker of the join tables, since the names can get awkward. I've used _x_
in the past, as in kg_node_x_kg_source
. (You currently call it kg_edge_source
, which is inconsistent with the other join table names.)
You could probably dispense with the kg prefixes entirely. We need them in the code because it's shared with the benchmark app, but the neo4j store doesn't use kg prefixes in its naming.
I thought VARCHAR(254)
was the default mapping for String
but it turns out TEXT
is the default for Postgres
@gordom6 am stuck on this error when I try to run sbt "project kgApp" -DkgStore=postgres run
, seems like my @Inject
for the postgres config is not working but not sure why
CreationException: Unable to create injector, see the following errors:
1) Error injecting constructor, java.lang.NullPointerException
at io.github.tetherlessworld.mcsapps.lib.kg.stores.postgres.PostgresKgCommandStore.<init>(PostgresKgCommandStore.scala:16)
at io.github.tetherlessworld.mcsapps.lib.kg.stores.postgres.PostgresKgCommandStore.class(PostgresKgCommandStore.scala:16)
while locating io.github.tetherlessworld.mcsapps.lib.kg.stores.postgres.PostgresKgCommandStore
while locating io.github.tetherlessworld.mcsapps.lib.kg.stores.KgCommandStore
for the 2nd parameter of io.github.tetherlessworld.mcsapps.lib.kg.stores.KgDataDirectoryLoader.<init>(KgDataDirectoryLoader.scala:24)
at io.github.tetherlessworld.mcsapps.lib.kg.stores.KgStoresModule.configure(KgStoresModule.scala:44) (via modules: com.google.inject.util.Modules$OverrideModule -> stores.KgStoresModule -> io.github.tetherlessworld.mcsapps.lib.kg.stores.KgStoresModule)
while locating io.github.tetherlessworld.mcsapps.lib.kg.stores.KgDataDirectoryLoader
@gordom6 I think this wraps up the current pr. The command store should be complete, I will implement the remaining query store methods in the subsequent two prs in the following order: 1) PageRank
I'd like to get your review on the current state, then I will merge master into this branch to update the docker compose
@gordom6 Yes, the test failures are due to the missing fulltext and pageRank
@gordom6 I'd like to get your feedback on the schema before moving on
Here is a visual of what the relationships look like to help with review