-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
remove CentralRegistry #3554
remove CentralRegistry #3554
Conversation
backend/src/main/java/com/bakdata/conquery/apiv1/query/TableExportQuery.java
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/apiv1/query/TableExportQuery.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/io/jackson/serializer/IdDeserializer.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/io/jackson/serializer/IdDeserializer.java
Outdated
Show resolved
Hide resolved
@@ -1,24 +0,0 @@ | |||
package com.bakdata.conquery.io.jackson.serializer; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
könntest du eine UtilityMethode machen, die Collection<TID extends Id<ID>> -> Collection<ID>
abbildet?
backend/src/main/java/com/bakdata/conquery/models/identifiable/ids/IdUtil.java
Outdated
Show resolved
Hide resolved
ConceptElementId<?> element = entry.getKey(); | ||
ConceptId conceptId = element.findConcept(); | ||
|
||
// mapping function cannot use Id::resolve here yet, somehow the nsIdResolver is not set because it |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
das klingt nach einem Bug in dem Deserliazier? Vlt brauchst du einen dedizierten Key Deserializer
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Das hatte ich noch nicht ganz verstanden. Ich war davon ausgegangen, dass der Normale Deserialiser genutzt wird, wenn kein KeyDeserializer genutzt wird. Aber es ist wohl am besten mit einem Test herauszufinden.
backend/src/main/java/com/bakdata/conquery/models/preproc/PreprocessedReader.java
Outdated
Show resolved
Hide resolved
import org.junit.jupiter.api.extension.ExtensionContext; | ||
|
||
@Getter | ||
public class GroupExtension implements BeforeAllCallback { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
was ist das?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ich habe das für einige Komponenten erstellt, die in einen Storage müssen, noch dem er geöffnet wurde, damit die Logik nicht in den @BeforeAll
-Callback eines Tests muss und man es wiederverwenden kann.
Wir könnten diesen Extensions-Mechanismus auch um die Cached TestConqueries bauen um dann nicht mehr die DynamicNodes für ProgrammaticTests zu nutzen, sondern sie als echte Tests nutzen.
Der RestartTest könnte vermutlich auch DropwizardAppExtension nutzen
backend/src/test/java/com/bakdata/conquery/util/support/TestConquery.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/apiv1/query/concept/specific/CQConcept.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/commands/ShardNode.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/io/jackson/serializer/IdDeserializer.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/models/datasets/concepts/tree/TreeConcept.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/models/events/Bucket.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/models/jobs/CalculateCBlocksJob.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/models/worker/ShardWorkers.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/models/worker/Worker.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/io/jackson/serializer/IdDeserializer.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/models/identifiable/ids/IIdInterner.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/resources/admin/rest/AdminDatasetProcessor.java
Outdated
Show resolved
Hide resolved
backend/src/main/java/com/bakdata/conquery/resources/api/QueryResource.java
Outdated
Show resolved
Hide resolved
allgemeine bitte: Bitte squashe deinen merge, das ist dann schöner in der history. |
@awildturtok wir können sqash auch gerne als default machen |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Eine letzte Sache: Kannst du bitte einmal alle call-sites von resolve überprüfen ob sie in hotcode sind? Es ist unwahrscheinlich, aber es wäre schlecht wenn wir da so viel performance verballern.
@@ -90,38 +94,38 @@ public class CQConcept extends CQElement implements NamespacedIdentifiableHoldin | |||
|
|||
public static CQConcept forSelect(Select select) { | |||
final CQConcept cqConcept = new CQConcept(); | |||
cqConcept.setElements(List.of(select.getHolder().findConcept())); | |||
cqConcept.setElements(List.of(select.getHolder().findConcept().getId())); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
man könnte drüber nachdenken, ob du die ganze methode auf Id umstellen kannst. Mach mal bitte einen KOmmentar für später ran
} | ||
|
||
return cqConcept; | ||
} | ||
|
||
public static CQConcept forConnector(Connector source) { | ||
final CQConcept cqConcept = new CQConcept(); | ||
cqConcept.setElements(List.of(source.getConcept())); | ||
cqConcept.setElements(List.of(source.getConcept().getId())); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ebenso
// We need to assign resolvers for namespaced and meta ids because meta-objects might reference namespaced objects (e.g. ExecutionsId) | ||
NamespacedStorageProvider namespacedStorageProvider = NamespacedStorageProvider.getResolver(ctxt); | ||
MetaStorage metaStorage = MetaStorage.get(ctxt); | ||
setResolver(id, metaStorage, namespacedStorageProvider); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
kannst du das assignment aus dem try-catch Block nehmen? das wäre glaube ich sauberer?
if (subId instanceof NamespacedId) { | ||
subId.setNamespacedStorageProvider(namespacedStorageProvider); | ||
} | ||
else if (subId instanceof MetaId) { | ||
subId.setMetaStorage(metaStorage); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Blöde Frage, aber kannst du das nicht dem Interface überlassen? Also MetaId und NamespacedId sind Id<MetaStorage/NamespacedStorage> und haben ein Feld storageProvider? dann kannst du dir die ambiguation komplett sparen
public Object createScriptValue(int event, @NotNull Column column) { | ||
return getStore(column).createScriptValue(event); | ||
} | ||
|
||
public Map<String, Object> calculateMap(int event) { | ||
final Map<String, Object> out = new HashMap<>(stores.length); | ||
Column[] columns = getTable().resolve().getColumns(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
resolve immernoch in hot-loop
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
calculateMap wird pro Zeile aufgerufen
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ich habe es jetzt in ein Lambda ausgelagert, dass pro bucket und cblock einmal generiert wird und stores und columns referenziert
private int getBucket(String id) { | ||
return entity2Bucket.getInt(id); | ||
} | ||
|
||
/** | ||
* Remove all buckets comprising the import. Which will in-turn remove all CBLocks. | ||
*/ | ||
public void removeImport(Import imp) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
=> ImportId
c80118f
to
cbbfa29
Compare
No description provided.