Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- data-config:
- <dataConfig>
- <dataSource type="JdbcDataSource"
- driver="com.mysql.jdbc.Driver"
- url="jdbc:mysql://localhost/xxxx"
- batchSize="-1"
- user="xxxx"
- password="xxxx"/>
- <document>
- <entity name="name" query="SELECT id, name FROM name LIMIT 10"></entity>
- <entity name="title" query="SELECT id AS titleid, title FROM title LIMIT 10"></entity>
- </document>
- </dataConfig>
- schema.xml
- <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
- indexed: true if this field should be indexed (searchable or sortable)
- stored: true if this field should be retrievable
- multiValued: true if this field may contain multiple values per document
- omitNorms: (expert) set to true to omit the norms associated with
- this field (this disables length normalization and index-time
- boosting for the field, and saves some memory). Only full-text
- fields or fields that need an index-time boost need norms.
- Norms are omitted for primitive (non-analyzed) types by default.
- 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" />
- <field name="name" type="text_general" indexed="true" stored="true" />
- <field name="titleid" type="string" indexed="true" stored="true" />
- <field name="title" type="text_general" indexed="true" stored="true" />
- <!-- uncomment the following to ignore any fields that don't already match an existing
- field name or dynamic field, rather than reporting them as an error.
- alternately, change the type="ignored" to some other type e.g. "text" if you want
- unknown fields indexed and/or stored by default -->
- <dynamicField name="*" type="ignored" multiValued="true" />
- </fields>
- <uniqueKey>id</uniqueKey>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement