Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在 Solr 中,我有两个核心。架构是相同的,但它们有不同的文档。
现在我希望只有一个文档类并使用相同的文档类为这两个核心初始化 Solr。例如:
Startup.Init("http://localhost:8983/solr/core1"); Startup.Init("http://localhost:8983/solr/core2");
但是我收到异常说密钥已经注册。
解决办法是什么?
谢谢。
从文档:
内置容器(启动)目前仅限于访问具有不同映射类型的多个内核/实例。
因此,您可以为项目做出贡献以解除此限制,或者切换到 Windsor 或 StructureMap。