I'm only getting 90 records a second at best, so you're doing way better
than me already!
The process could very well be either CPU bound or disk bound.
However, to map from Marc to the solr fields we need, we need to do a
lot more logic than the "hello world" Solr examples that brag of fast
indexing times, so it could very well be unavoidably CPU bound in
SolrMarc. My own local example uses even more complex logic than the
out of the box example. It's possible SolrMarc could be optimized, but
it's also possible we're just doing a lot of work, and it's going to
take time.
(There are also various different ways for an indexing client to talk to
Solr, with possibly different performance implications. binary vs XML,
streaming server vs not, how many updates you batch together in a single
POST. I get confused figuring out what SolrMarc does by default, and
what the config is to change it. But it's possible you could change some
of these configs in your solrmarc to improve speed -- although,
actually, probably not relevant if you are using the 'direct to disk'
SolrMarc indexing method, it's not actually talking to an external
solrserver at all, it's just writing solr/lucene-compatible indexes
directly to disk itself. I myself only use HTTP -- it's _not_ faster
than what you're doing, but it is more bug-free in _my_ experience. Not
sure what you were running into.)
I (and many others) use the Solr replication feature to have an indexing
server and a search serving server. Then, if I need to re-index because
I've changed the schema, I reindex in my indexing server (without
bothering the search serving server at all, or causing any downtime),
and then replicate to the search serving server when I'm done.
(replication can send the new schema.xml over too). This is one way to
deal with long reindexing times. In development, I use a different
development solr index, and when I can avoid it, I don't work on a full
index, so I can change my schema and reindex quickly to see changes,
iteratively. I only do a full reindex when I really need to, or when I'm
ready to make the switch in production.
I guess this whole discussion at this point would really be better on
the SolrMarc list, it's mostly about SolrMarc, a little about Solr
itself, and not at all about Blacklight at this level we're talking about.
On 4/30/2012 1:52 PM, Louis St-Amour wrote:
> Thanks for the multivalued tips, Chris, Jonathan. I've no idea if it'll
> cause trouble down the road, but as I'm using the jetty-solr provided by
> the generator, I edited *jetty/solr/conf/schema.xml* to set
> *marc_display* through *author_vern_display* to *multiValued="true"* and
> I haven't yet encountered an error. Yay!
>
> I also seem to have fixed, or delayed, the crashing, by editing
> *config/SolrMarc/config.properties* to have absolute paths set for
> *solrmarc.solr.war.path* and *solr.path*. Doing so should allow direct
> access via SolrMarc to the Solr data store, which seems a bit slower,
> but is perhaps more reliable. I also gave the Java more RAM with *export
> SOLRMARC_MEM_ARGS='-server -Xms2048m -Xmx7000m -XX:+UseParallelGC
> -XX:NewRatio=5'*
>
> And it imported the first file with no problems. Awesome. Let's see what
> the end result looks like in 4 hours ... How long has it taken other
> people to import records? If I want to adjust the schema down the road,
> it'd be nice to get imports down to an hour or less. Then again, it
> probably doesn't matter, and Googling further reveals that the process
> appears to be CPU-bound or something, perhaps because of the Marc to
> Solr mapping... and people often get 200-500 a sec. So I'm doing well.
> If I want it faster, I suppose I should set up a central Solr server
> then distribute Marc files to different computers and run it over HTTP
> instead of the embedded Solr instance I'm using now to avoid that bug.
>
>
> Louis.
>
> On Monday, 30 April 2012 10:58:37 UTC-4, Chris Beer wrote:
>
> Hi Louis,
>
> I was tinkering with the Harvard data last week too and ran into the
> same problems. The multivalued issue has to do with the
> Blacklight-distributed schema.xml (which can be easily modified),
> although from what I gather, this may indicate some non-standard(?)
> MARC.
>
> I also had the problem with SolrMarc hanging, but persistence seemed
> to be sufficient to index the whole dataset.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Blacklight Development" group.
> To view this discussion on the web visit
>
https://groups.google.com/d/msg/blacklight-development/-/7fPjG-m0Q98J.