it is not supported now. If it does it should be a new method say getOrCreateCore(). The problem is creating a core usually requires extra parameters( like instanceDir)
On Sat, Jan 23, 2010 at 1:59 AM, Matthieu Labour <matth...@strateer.com> wrote: > Hi > > Would it make sense to modify/ add a method to CoreContainer that creates a > core if the core doesn't exist ? > > something like > > public SolrCore getCore(String name) { > synchronized(cores) { > SolrCore core = cores.get(name); > if (core != null) > core.open(); // increment the ref count while still synchronized > else { > core = create(name); > cores.put(name,core); > } > return core; > } > } > > > My apology if this already documented... > > matt > -- ----------------------------------------------------- Noble Paul | Systems Architect| AOL | http://aol.com