source: proiecte/HadoopJUnit/hadoop-0.20.1/docs/api/org/apache/hadoop/contrib/index/main/UpdateIndex.html @ 120

Last change on this file since 120 was 120, checked in by (none), 14 years ago

Added the mail files for the Hadoop JUNit Project

  • Property svn:executable set to *
File size: 14.2 KB
Line 
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
2<!--NewPage-->
3<HTML>
4<HEAD>
5<!-- Generated by javadoc (build 1.6.0_07) on Tue Sep 01 20:56:59 UTC 2009 -->
6<TITLE>
7UpdateIndex (Hadoop 0.20.1 API)
8</TITLE>
9
10<META NAME="date" CONTENT="2009-09-01">
11
12<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
13
14<SCRIPT type="text/javascript">
15function windowTitle()
16{
17    if (location.href.indexOf('is-external=true') == -1) {
18        parent.document.title="UpdateIndex (Hadoop 0.20.1 API)";
19    }
20}
21</SCRIPT>
22<NOSCRIPT>
23</NOSCRIPT>
24
25</HEAD>
26
27<BODY BGCOLOR="white" onload="windowTitle();">
28<HR>
29
30
31<!-- ========= START OF TOP NAVBAR ======= -->
32<A NAME="navbar_top"><!-- --></A>
33<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35<TR>
36<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37<A NAME="navbar_top_firstrow"><!-- --></A>
38<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39  <TR ALIGN="center" VALIGN="top">
40  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/UpdateIndex.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48  </TR>
49</TABLE>
50</TD>
51<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52</EM>
53</TD>
54</TR>
55
56<TR>
57<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58&nbsp;PREV CLASS&nbsp;
59&nbsp;NEXT CLASS</FONT></TD>
60<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61  <A HREF="../../../../../../index.html?org/apache/hadoop/contrib/index/main/UpdateIndex.html" target="_top"><B>FRAMES</B></A>  &nbsp;
62&nbsp;<A HREF="UpdateIndex.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
63&nbsp;<SCRIPT type="text/javascript">
64  <!--
65  if(window==top) {
66    document.writeln('<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67  }
68  //-->
69</SCRIPT>
70<NOSCRIPT>
71  <A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72</NOSCRIPT>
73
74
75</FONT></TD>
76</TR>
77<TR>
78<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82</TR>
83</TABLE>
84<A NAME="skip-navbar_top"></A>
85<!-- ========= END OF TOP NAVBAR ========= -->
86
87<HR>
88<!-- ======== START OF CLASS DATA ======== -->
89<H2>
90<FONT SIZE="-1">
91org.apache.hadoop.contrib.index.main</FONT>
92<BR>
93Class UpdateIndex</H2>
94<PRE>
95<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96  <IMG SRC="../../../../../../resources/inherit.gif" ALT="extended by "><B>org.apache.hadoop.contrib.index.main.UpdateIndex</B>
97</PRE>
98<HR>
99<DL>
100<DT><PRE>public class <B>UpdateIndex</B><DT>extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></DL>
101</PRE>
102
103<P>
104A distributed "index" is partitioned into "shards". Each shard corresponds
105 to a Lucene instance. This class contains the main() method which uses a
106 Map/Reduce job to analyze documents and update Lucene instances in parallel.
107 
108 The main() method in UpdateIndex requires the following information for
109 updating the shards:
110   - Input formatter. This specifies how to format the input documents.
111   - Analysis. This defines the analyzer to use on the input. The analyzer
112     determines whether a document is being inserted, updated, or deleted.
113     For inserts or updates, the analyzer also converts each input document
114     into a Lucene document.
115   - Input paths. This provides the location(s) of updated documents,
116     e.g., HDFS files or directories, or HBase tables.
117   - Shard paths, or index path with the number of shards. Either specify
118     the path for each shard, or specify an index path and the shards are
119     the sub-directories of the index directory.
120   - Output path. When the update to a shard is done, a message is put here.
121   - Number of map tasks.
122
123 All of the information can be specified in a configuration file. All but
124 the first two can also be specified as command line options. Check out
125 conf/index-config.xml.template for other configurable parameters.
126
127 Note: Because of the parallel nature of Map/Reduce, the behaviour of
128 multiple inserts, deletes or updates to the same document is undefined.
129<P>
130
131<P>
132<HR>
133
134<P>
135<!-- =========== FIELD SUMMARY =========== -->
136
137<A NAME="field_summary"><!-- --></A>
138<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
139<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
140<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
141<B>Field Summary</B></FONT></TH>
142</TR>
143<TR BGCOLOR="white" CLASS="TableRowColor">
144<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
145<CODE>static&nbsp;org.apache.commons.logging.Log</CODE></FONT></TD>
146<TD><CODE><B><A HREF="../../../../../../org/apache/hadoop/contrib/index/main/UpdateIndex.html#LOG">LOG</A></B></CODE>
147
148<BR>
149&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
150</TR>
151</TABLE>
152&nbsp;
153<!-- ======== CONSTRUCTOR SUMMARY ======== -->
154
155<A NAME="constructor_summary"><!-- --></A>
156<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
157<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
158<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
159<B>Constructor Summary</B></FONT></TH>
160</TR>
161<TR BGCOLOR="white" CLASS="TableRowColor">
162<TD><CODE><B><A HREF="../../../../../../org/apache/hadoop/contrib/index/main/UpdateIndex.html#UpdateIndex()">UpdateIndex</A></B>()</CODE>
163
164<BR>
165&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
166</TR>
167</TABLE>
168&nbsp;
169<!-- ========== METHOD SUMMARY =========== -->
170
171<A NAME="method_summary"><!-- --></A>
172<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
173<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
174<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
175<B>Method Summary</B></FONT></TH>
176</TR>
177<TR BGCOLOR="white" CLASS="TableRowColor">
178<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
179<CODE>static&nbsp;void</CODE></FONT></TD>
180<TD><CODE><B><A HREF="../../../../../../org/apache/hadoop/contrib/index/main/UpdateIndex.html#main(java.lang.String[])">main</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>[]&nbsp;argv)</CODE>
181
182<BR>
183&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The main() method</TD>
184</TR>
185</TABLE>
186&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
187<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
188<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
189<TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
190</TR>
191<TR BGCOLOR="white" CLASS="TableRowColor">
192<TD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
193</TR>
194</TABLE>
195&nbsp;
196<P>
197
198<!-- ============ FIELD DETAIL =========== -->
199
200<A NAME="field_detail"><!-- --></A>
201<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
202<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
203<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
204<B>Field Detail</B></FONT></TH>
205</TR>
206</TABLE>
207
208<A NAME="LOG"><!-- --></A><H3>
209LOG</H3>
210<PRE>
211public static final org.apache.commons.logging.Log <B>LOG</B></PRE>
212<DL>
213<DL>
214</DL>
215</DL>
216
217<!-- ========= CONSTRUCTOR DETAIL ======== -->
218
219<A NAME="constructor_detail"><!-- --></A>
220<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
221<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
222<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
223<B>Constructor Detail</B></FONT></TH>
224</TR>
225</TABLE>
226
227<A NAME="UpdateIndex()"><!-- --></A><H3>
228UpdateIndex</H3>
229<PRE>
230public <B>UpdateIndex</B>()</PRE>
231<DL>
232</DL>
233
234<!-- ============ METHOD DETAIL ========== -->
235
236<A NAME="method_detail"><!-- --></A>
237<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
238<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
239<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
240<B>Method Detail</B></FONT></TH>
241</TR>
242</TABLE>
243
244<A NAME="main(java.lang.String[])"><!-- --></A><H3>
245main</H3>
246<PRE>
247public static void <B>main</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>[]&nbsp;argv)</PRE>
248<DL>
249<DD>The main() method
250<P>
251<DD><DL>
252<DT><B>Parameters:</B><DD><CODE>argv</CODE> - </DL>
253</DD>
254</DL>
255<!-- ========= END OF CLASS DATA ========= -->
256<HR>
257
258
259<!-- ======= START OF BOTTOM NAVBAR ====== -->
260<A NAME="navbar_bottom"><!-- --></A>
261<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
262<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
263<TR>
264<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
265<A NAME="navbar_bottom_firstrow"><!-- --></A>
266<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
267  <TR ALIGN="center" VALIGN="top">
268  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
269  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
270  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
271  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/UpdateIndex.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
272  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
273  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
274  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
275  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
276  </TR>
277</TABLE>
278</TD>
279<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
280</EM>
281</TD>
282</TR>
283
284<TR>
285<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
286&nbsp;PREV CLASS&nbsp;
287&nbsp;NEXT CLASS</FONT></TD>
288<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
289  <A HREF="../../../../../../index.html?org/apache/hadoop/contrib/index/main/UpdateIndex.html" target="_top"><B>FRAMES</B></A>  &nbsp;
290&nbsp;<A HREF="UpdateIndex.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
291&nbsp;<SCRIPT type="text/javascript">
292  <!--
293  if(window==top) {
294    document.writeln('<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
295  }
296  //-->
297</SCRIPT>
298<NOSCRIPT>
299  <A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>
300</NOSCRIPT>
301
302
303</FONT></TD>
304</TR>
305<TR>
306<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
307  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
308<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
309DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
310</TR>
311</TABLE>
312<A NAME="skip-navbar_bottom"></A>
313<!-- ======== END OF BOTTOM NAVBAR ======= -->
314
315<HR>
316Copyright &copy; 2009 The Apache Software Foundation
317</BODY>
318</HTML>
Note: See TracBrowser for help on using the repository browser.