public void Execute(Instance instance, Product module) { XmlDocument sitecoreConfig = instance.GetShowconfig(); string solrUrl = GetUrlFrom(sitecoreConfig); XmlNodeList solrIndexes = GetSolrIndexNodesFrom(sitecoreConfig); SolrInformation info = GetSolrInformation(solrUrl); string sourcePath = info.TemplateFullPath; foreach (XmlElement node in solrIndexes) { string coreName = GetCoreName(node); string newCorePath = info.SolrBasePath.EnsureEnd(@"\") + coreName; CopyDirectory(sourcePath, newCorePath); RemoveCorePropertiesFile(newCorePath); UpdateSchema(instance.WebRootPath, newCorePath); UpdateSolrConfig(newCorePath); CreateSolrCore(solrUrl, coreName, newCorePath); } }
public InvalidException(string message, SolrInformation solrInformation) { _message = message; _solrInformation = solrInformation; }