My hunch, though I'll try to make some time to test this out thoroughly, is that the entity is parsed initially with variables resolved, but not per request. Variables/expressions do get expanded for fields of course, but perhaps not for other high-level attributes?

        Erik

On Aug 12, 2009, at 5:38 PM, John Lowe wrote:

Hmmm...perhaps my original note was a bit TLTR.  Trying again:

The v1.3 docs say that one can pass one's own parameters in to DIH via the HTTP request:

http://wiki.apache.org/solr/DataImportHandler#head-520f8e527d9da55e8ed1e274e29709c8805c8eae

SO if I have a URL like the following to dataimport:

http://localhost:8983/solr/rss/dataimport?command=full-import&foo=http%3A%2F%2Fbar.com

AND, in my data-config file I have something like:

<dataConfig>
      <dataSource type="HttpDataSource" name="rss-feed" />
      <document>
              <entity name="article" dataSource="rss-feed"
                              pk="link"
                              url="${dataimporter.request.foo}"
                              processor="XPathEntityProcessor"

[blah blah blah...looks pretty much like the slashdot RSS rss-data- config.xml]

the value of url should be filled in with 'http://bar.com', right?

Well...it's not!

I get an exception:

SEVERE: Exception thrown while getting data
java.net.MalformedURLException: no protocol: null

Which seems to indicate that the value is not getting passed. or I'm not referring to it correctly. Or something.

Any hints would be greatly appreciated...apologies for re-spamming the list with my desperate request,

John

Reply via email to