예제 #1
0
 public void TestSorlCloud()
 {
     using (var provider = new SolrCloudStateProvider("10.26.11.30:9983")) {
         CloudStartup.Init <TestEntity>(provider);
         TestRoutine();
     }
 }
예제 #2
0
        public async Task TestSolrCloud()
        {
            using (var provider = new SolrCloudStateProvider("10.26.11.30:9983"))
            {
                await CloudStartup.InitAsync <TestEntity>(provider);

                TestRoutine();
            }
        }
예제 #3
0
        public async Task InitializeAsync()
        {
            solrconnection = new SolrConnection(SOLR_CONNECTION_URL);
            collections    = new SolrCollectionsAdmin(solrconnection, new HeaderResponseParser <string>());

            var solrCloud = new SolrCloudStateProvider(ZOOKEEPER_CONNECTION);
            await Startup.InitAsync <string>(solrCloud, COLLECTION_NAME, true);

            solrCloudStateProvider = Startup.Container.GetInstance <ISolrCloudStateProvider>(solrCloud.Key);
        }
 public async Task ThrowExceptionOnBadConnection()
 {
     var provider = new SolrCloudStateProvider("desktop-lmqi80k:9984");
     await Assert.ThrowsAsync <Exceptions.SolrNetCloudConnectionException>(() => provider.InitAsync());
 }