Revision 7531
Added by ben leinfelder over 11 years ago
docs/user/metacat/source/query-index.rst | ||
---|---|---|
75 | 75 |
.. |
76 | 76 |
@startuml images/indexing-class-diagram.png |
77 | 77 |
|
78 |
package cn-index-processor.parser {
|
|
78 |
package "Current cn-index-processor (library)" {
|
|
79 | 79 |
|
80 | 80 |
interface IDocumentSubprocessor { |
81 | 81 |
+ boolean canProcess(Document doc) |
... | ... | |
103 | 103 |
} |
104 | 104 |
class CommonRootSolrField { |
105 | 105 |
} |
106 |
class RootElement { |
|
107 |
} |
|
108 |
class LeafElement { |
|
109 |
} |
|
106 | 110 |
class FullTextSolrField { |
107 | 111 |
} |
108 | 112 |
class MergeSolrField { |
... | ... | |
129 | 133 |
|
130 | 134 |
ISolrField <|-- SolrField |
131 | 135 |
SolrField <|-- CommonRootSolrField |
136 |
CommonRootSolrField o--"1" RootElement |
|
137 |
RootElement o--"*" LeafElement |
|
132 | 138 |
SolrField <|-- FullTextSolrField |
133 | 139 |
SolrField <|-- MergeSolrField |
134 | 140 |
SolrField <|-- ResolveSolrField |
135 |
SolrField <|-- SolrFieldResourceMap
|
|
141 |
SolrField <|-- SolrFieldResourceMap |
|
136 | 142 |
|
137 |
|
|
138 | 143 |
AbstractDocumentSubprocessor o--"*" ISolrField |
139 | 144 |
|
140 | 145 |
IDocumentSubprocessor --> SolrDoc |
141 | 146 |
|
142 | 147 |
SolrDoc o--"*" SolrElementField |
143 | 148 |
|
144 |
package solr {
|
|
149 |
package "SOLR (library)" {
|
|
145 | 150 |
|
146 | 151 |
abstract class SolrServer { |
147 | 152 |
+ add(SolrInputDocument doc) |
... | ... | |
158 | 163 |
SolrServer <|-- EmbeddedSolrServer |
159 | 164 |
SolrServer <|-- HttpSolrServer |
160 | 165 |
|
161 |
|
|
162 |
package edu.ucsb.nceas.metacat.indexer { |
|
166 |
package "Stand-alone indexer (webapp or daemon)" { |
|
163 | 167 |
|
164 |
class MetacatSolrIndex {
|
|
168 |
class SolrIndex { |
|
165 | 169 |
- List<IDocumentSubprocessor> subprocessors |
166 | 170 |
- IDocumentSubprocessorFactory subprocessorFactory |
167 |
- EmbeddedSolrServer solrServer
|
|
171 |
- SolrServer solrServer |
|
168 | 172 |
+ insert(String pid, InputStream data) |
169 | 173 |
+ update(String pid, InputStream data) |
170 | 174 |
+ remove(String pid) |
171 |
+ OutputStream query(String solrQuery) |
|
172 | 175 |
} |
173 |
|
|
174 |
class IDocumentSubprocessorFactory { |
|
175 |
+ IDocumentSubprocessor getIDocumentSubprocessor(InputStream config) |
|
176 |
|
|
177 |
class DocumentEventListener { |
|
178 |
- SolrIndex solrIndex |
|
179 |
- IMap systemMetadataMap |
|
180 |
+ entryAdded() |
|
181 |
+ entryUpdated() |
|
182 |
+ entryRemoved() |
|
176 | 183 |
} |
177 | 184 |
|
178 | 185 |
} |
179 | 186 |
|
180 |
MetacatSolrIndex *--"1" EmbeddedSolrServer |
|
181 |
MetacatSolrIndex --> IDocumentSubprocessorFactory |
|
182 |
MetacatSolrIndex o--"*" IDocumentSubprocessor |
|
183 |
IDocumentSubprocessorFactory --> IDocumentSubprocessor |
|
187 |
package "Metacat (webapp)" { |
|
188 |
|
|
189 |
class MetacatSolrIndex { |
|
190 |
+ query() |
|
191 |
} |
|
192 |
|
|
193 |
class HazelcastService { |
|
194 |
- IMap systemMetadataMap |
|
195 |
} |
|
196 |
} |
|
184 | 197 |
|
185 |
|
|
198 |
MetacatSolrIndex *--"1" SolrServer |
|
199 |
HazelcastService .. DocumentEventListener |
|
186 | 200 |
|
201 |
SolrIndex *--"1" SolrServer |
|
202 |
SolrIndex "1"--o DocumentEventListener |
|
203 |
SolrIndex o--"*" IDocumentSubprocessor: Assembled using Spring bean configuration |
|
187 | 204 |
|
188 | 205 |
|
206 |
|
|
189 | 207 |
|
190 | 208 |
@enduml |
Also available in: Unified diff
add new Stand-alone indexer component that can utilize more of the cn-index-processor code (Spring configuration) as is. Include Hazelcast reference to illustrate listener mechanism for responding to events that affect the index.