-
-
Notifications
You must be signed in to change notification settings - Fork 124
[Store] Add a way to bypass document loading in Indexer #911
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
base: main
Are you sure you want to change the base?
Conversation
lyrixx
commented
Nov 20, 2025
| Q | A |
|---|---|
| Bug fix? | no |
| New feature? | yes |
| Docs? | |
| Issues | Fix #875 |
| License | MIT |
|
Before fixing test & co, is this the way to go? |
| private VectorizerInterface $vectorizer, | ||
| private StoreInterface $store, | ||
| string|array|null $source = null, | ||
| EmbeddableDocumentInterface|array|null $document = [], |
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.
| EmbeddableDocumentInterface|array|null $document = [], | |
| EmbeddableDocumentInterface|array|null $documents = [], |
?
| } | ||
|
|
||
| public function withSource(string|array $source): self | ||
| public function withSource(EmbeddableDocumentInterface|string|array $source): self |
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.
Why should we accept the EmbeddableDocumentInterface here too?
| return new self($this->loader, $this->vectorizer, $this->store, $source, [], $this->filters, $this->transformers, $this->logger); | ||
| } | ||
|
|
||
| public function withDocument(EmbeddableDocumentInterface|array $document): self |
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.
| public function withDocument(EmbeddableDocumentInterface|array $document): self | |
| public function withDocuments(array $documents): self |
?
|
Lets wait for @chr-hertel here |
|
with without a source provided, that implementation will be called with but that's basically just another idea, but i just struggle with state in constructors - Oskar knows about that flaw in my mind already :D I think that solution is alright here, I would just omit the |