Apache Solr open-source search software
cleanup of comments relating to 'default' field values; cleanup of 'timestamp' usage examples -- switched to using 'manufacturedate_dt' as a generic date field example since yonik doens't want schema to have fields with default values uncommented
Chris M. Hostetter9099b123d11b
diff --git a/example/exampledocs/hd.xml b/example/exampledocs/hd.xmlindex 4003f961d54..90a87f0ad74 100644--- a/example/exampledocs/hd.xml+++ b/example/exampledocs/hd.xml@@ -27,7 +27,7 @@<field name="price">92</field><field name="popularity">6</field><field name="inStock">true</field>- <field name="timestamp">NOW</field>+ <field name="manufacturedate_dt">2006-02-13T15:26:37Z</field></doc><doc>@@ -42,7 +42,7 @@<field name="price">350</field><field name="popularity">6</field><field name="inStock">true</field>- <field name="timestamp">NOW</field>+ <field name="manufacturedate_dt">2006-02-13T15:26:37Z</field></doc></add>diff --git a/example/exampledocs/ipod_other.xml b/example/exampledocs/ipod_other.xmlindex a5ece70d05f..a1924d33b0e 100644--- a/example/exampledocs/ipod_other.xml+++ b/example/exampledocs/ipod_other.xml@@ -28,7 +28,7 @@<field name="price">19.95</field><field name="popularity">1</field><field name="inStock">false</field>- <field name="timestamp">2005-08-01T16:30:25Z</field>+ <field name="manufacturedate_dt">2005-08-01T16:30:25Z</field></doc><doc>@@ -42,7 +42,7 @@<field name="price">11.50</field><field name="popularity">1</field><field name="inStock">false</field>- <field name="timestamp">2006-02-14T23:55:59Z</field>+ <field name="manufacturedate_dt">2006-02-14T23:55:59Z</field></doc>diff --git a/example/exampledocs/ipod_video.xml b/example/exampledocs/ipod_video.xmlindex 1298c5426ef..9b155f5f69c 100644--- a/example/exampledocs/ipod_video.xml+++ b/example/exampledocs/ipod_video.xml@@ -32,5 +32,5 @@<field name="price">399.00</field><field name="popularity">10</field><field name="inStock">true</field>- <field name="timestamp">2005-10-12T08:00:00Z</field>+ <field name="manufacturedate_dt">2005-10-12T08:00:00Z</field></doc></add>diff --git a/example/exampledocs/mem.xml b/example/exampledocs/mem.xmlindex 71e2e838e7c..13eb9e351d3 100644--- a/example/exampledocs/mem.xml+++ b/example/exampledocs/mem.xml@@ -26,7 +26,7 @@<field name="price">185</field><field name="popularity">5</field><field name="inStock">true</field>- <field name="timestamp">NOW</field>+ <field name="manufacturedate_dt">2006-02-13T15:26:37Z</field></doc><doc>@@ -38,7 +38,7 @@<field name="price">74.99</field><field name="popularity">7</field><field name="inStock">true</field>- <field name="timestamp">NOW</field>+ <field name="manufacturedate_dt">2006-02-13T15:26:37Z</field></doc><doc>@@ -48,10 +48,10 @@<field name="cat">electronics</field><field name="cat">memory</field><field name="features">CAS latency 3, 2.7v</field>- <!-- note: price is missing on this one -->- <field name="popularity">5</field>+ <!-- note: price & popularity is missing on this one -->+ <field name="popularity">0</field><field name="inStock">true</field>- <field name="timestamp">NOW</field>+ <field name="manufacturedate_dt">2006-02-13T15:26:37Z</field></doc>diff --git a/example/exampledocs/sd500.xml b/example/exampledocs/sd500.xmlindex 52712d67527..f04f7b7061d 100644--- a/example/exampledocs/sd500.xml+++ b/example/exampledocs/sd500.xml@@ -30,5 +30,5 @@<field name="price">329.95</field><field name="popularity">7</field><field name="inStock">true</field>- <field name="timestamp">NOW</field>+ <field name="manufacturedate_dt">2006-02-13T15:26:37Z</field></doc></add>diff --git a/example/exampledocs/vidcard.xml b/example/exampledocs/vidcard.xmlindex db460063f34..4aa86983064 100644--- a/example/exampledocs/vidcard.xml+++ b/example/exampledocs/vidcard.xml@@ -31,7 +31,7 @@<field name="price">479.95</field><field name="popularity">7</field><field name="inStock">false</field>- <field name="timestamp">NOW/DAY</field>+ <field name="manufacturedate_dt">2006-02-13T15:26:37Z/DAY</field></doc><!-- yes, you can add more than one document at a time --><doc>@@ -49,6 +49,6 @@<field name="price">649.99</field><field name="popularity">7</field><field name="inStock">false</field>- <field name="timestamp">NOW/DAY</field>+ <field name="manufacturedate_dt">2006-02-13T15:26:37Z/DAY</field></doc></add>diff --git a/example/solr/conf/schema.xml b/example/solr/conf/schema.xmlindex 09b29699517..741cadaa47f 100755--- a/example/solr/conf/schema.xml+++ b/example/solr/conf/schema.xml@@ -362,7 +362,8 @@<fields><!-- Valid attributes for fields:name: mandatory - the name for the field- type: mandatory - the name of a previously defined type from the <types> section+ type: mandatory - the name of a previously defined type from the+ <types> sectionindexed: true if this field should be indexed (searchable or sortable)stored: true if this field should be retrievablecompressed: [false] if this field should be stored using gzip compression@@ -373,11 +374,16 @@this field (this disables length normalization and index-timeboosting for the field, and saves some memory). Only full-textfields or fields that need an index-time boost need norms.- termVectors: [false] set to true to store the term vector for a given field.- When using MoreLikeThis, fields used for similarity should be stored for- best performance.- termPositions: Store position information with the term vector. This will increase storage costs.- termOffsets: Store offset information with the term vector. This will increase storage costs.+ termVectors: [false] set to true to store the term vector for a+ given field.+ When using MoreLikeThis, fields used for similarity should be+ stored for best performance.+ termPositions: Store position information with the term vector.+ This will increase storage costs.+ termOffsets: Store offset information with the term vector. This+ will increase storage costs.+ default: a value that should be used if no value is specified+ when adding a document.--><field name="id" type="string" indexed="true" stored="true" required="true" />@@ -391,11 +397,8 @@<field name="weight" type="float" indexed="true" stored="true"/><field name="price" type="float" indexed="true" stored="true"/>- <!-- "default" values can be specified for fields, indicating which- value should be used if no value is specified when adding a document.- -->- <field name="popularity" type="int" indexed="true" stored="true"/>- <field name="inStock" type="boolean" indexed="true" stored="true"/>+ <field name="popularity" type="int" indexed="true" stored="true" />+ <field name="inStock" type="boolean" indexed="true" stored="true" /><field name="title" type="text" indexed="true" stored="true"/>@@ -410,11 +413,12 @@<field name="payloads" type="payloads" indexed="true" stored="true"/>- <!-- Here, default is used to create a "timestamp" field indicating- When each document was indexed.- <field name="timestamp" type="date" indexed="true" stored="true" default="NOW" multiValued="false"/>+ <!-- Uncommenting the following will create a "timestamp" field using+ a default value of "NOW" to indicate when each document was indexed.+ -->+ <!--+ <field name="timestamp" type="date" indexed="true" stored="true" default="NOW" multiValued="false"/>-->- <field name="timestamp" type="date" indexed="true" stored="true" multiValued="false"/><!-- Dynamic field definitions. If a field name is not found, dynamicFields