source: proiecte/HadoopJUnit/hadoop-0.20.1/docs/api/org/apache/hadoop/mapred/lib/db/package-summary.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: 9.5 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>
7org.apache.hadoop.mapred.lib.db (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="org.apache.hadoop.mapred.lib.db (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="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
42  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-use.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;<A HREF="../../../../../../org/apache/hadoop/mapred/lib/aggregate/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
59&nbsp;<A HREF="../../../../../../org/apache/hadoop/mapred/pipes/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
60<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61  <A HREF="../../../../../../index.html?org/apache/hadoop/mapred/lib/db/package-summary.html" target="_top"><B>FRAMES</B></A>  &nbsp;
62&nbsp;<A HREF="package-summary.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</TABLE>
78<A NAME="skip-navbar_top"></A>
79<!-- ========= END OF TOP NAVBAR ========= -->
80
81<HR>
82<H2>
83Package org.apache.hadoop.mapred.lib.db
84</H2>
85org.apache.hadoop.mapred.lib.db Package
86<P>
87<B>See:</B>
88<BR>
89&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF="#package_description"><B>Description</B></A>
90<P>
91
92<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
93<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
94<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
95<B>Interface Summary</B></FONT></TH>
96</TR>
97<TR BGCOLOR="white" CLASS="TableRowColor">
98<TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBWritable.html" title="interface in org.apache.hadoop.mapred.lib.db">DBWritable</A></B></TD>
99<TD>Objects that are read from/written to a database should implement
100 <code>DBWritable</code>.</TD>
101</TR>
102</TABLE>
103&nbsp;
104
105<P>
106
107<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
108<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
109<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
110<B>Class Summary</B></FONT></TH>
111</TR>
112<TR BGCOLOR="white" CLASS="TableRowColor">
113<TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBConfiguration.html" title="class in org.apache.hadoop.mapred.lib.db">DBConfiguration</A></B></TD>
114<TD>A container for configuration property names for jobs with DB input/output.</TD>
115</TR>
116<TR BGCOLOR="white" CLASS="TableRowColor">
117<TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBInputFormat.html" title="class in org.apache.hadoop.mapred.lib.db">DBInputFormat&lt;T extends DBWritable&gt;</A></B></TD>
118<TD>A InputFormat that reads input data from an SQL table.</TD>
119</TR>
120<TR BGCOLOR="white" CLASS="TableRowColor">
121<TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBInputFormat.DBInputSplit.html" title="class in org.apache.hadoop.mapred.lib.db">DBInputFormat.DBInputSplit</A></B></TD>
122<TD>A InputSplit that spans a set of rows</TD>
123</TR>
124<TR BGCOLOR="white" CLASS="TableRowColor">
125<TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBInputFormat.NullDBWritable.html" title="class in org.apache.hadoop.mapred.lib.db">DBInputFormat.NullDBWritable</A></B></TD>
126<TD>A Class that does nothing, implementing DBWritable</TD>
127</TR>
128<TR BGCOLOR="white" CLASS="TableRowColor">
129<TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" title="class in org.apache.hadoop.mapred.lib.db">DBOutputFormat&lt;K extends DBWritable,V&gt;</A></B></TD>
130<TD>A OutputFormat that sends the reduce output to a SQL table.</TD>
131</TR>
132</TABLE>
133&nbsp;
134
135<P>
136<A NAME="package_description"><!-- --></A><H2>
137Package org.apache.hadoop.mapred.lib.db Description
138</H2>
139
140<P>
141<h2>org.apache.hadoop.mapred.lib.db Package</h2>
142<p>
143This package contains a library to read records from a database as an
144input to a mapreduce job, and write the output records to the database.   
145</p>
146<p>
147The Database to access can be configured using the static methods in the
148DBConfiguration class. Jobs reading input from a database should use
149DBInputFormat#setInput() to set the configuration. And jobs writing
150its output to the database should use DBOutputFormat#setOutput().
151</p>
152<p> 
153Tuples from/to the database are converted to/from Java objects using
154DBWritable methods. Typically, for each table in the db, a class extending
155DBWritable is defined, which holds the fields of the tuple. The fields
156of a record are read from the database using DBWritable#readFields(ResultSet),
157and written to the database using DBWritable#write(PreparedStatament
158statement).
159</p>
160<p>
161An example program using both DBInputFormat and DBOutputFormat can be found
162at src/examples/org/apache/hadoop/examples/DBCountPageview.java.
163</p>
164<P>
165
166<P>
167<DL>
168</DL>
169<HR>
170
171
172<!-- ======= START OF BOTTOM NAVBAR ====== -->
173<A NAME="navbar_bottom"><!-- --></A>
174<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
175<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
176<TR>
177<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
178<A NAME="navbar_bottom_firstrow"><!-- --></A>
179<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
180  <TR ALIGN="center" VALIGN="top">
181  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
182  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
183  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
184  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-use.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
185  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
186  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
187  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
188  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
189  </TR>
190</TABLE>
191</TD>
192<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
193</EM>
194</TD>
195</TR>
196
197<TR>
198<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
199&nbsp;<A HREF="../../../../../../org/apache/hadoop/mapred/lib/aggregate/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
200&nbsp;<A HREF="../../../../../../org/apache/hadoop/mapred/pipes/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
201<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
202  <A HREF="../../../../../../index.html?org/apache/hadoop/mapred/lib/db/package-summary.html" target="_top"><B>FRAMES</B></A>  &nbsp;
203&nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
204&nbsp;<SCRIPT type="text/javascript">
205  <!--
206  if(window==top) {
207    document.writeln('<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
208  }
209  //-->
210</SCRIPT>
211<NOSCRIPT>
212  <A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>
213</NOSCRIPT>
214
215
216</FONT></TD>
217</TR>
218</TABLE>
219<A NAME="skip-navbar_bottom"></A>
220<!-- ======== END OF BOTTOM NAVBAR ======= -->
221
222<HR>
223Copyright &copy; 2009 The Apache Software Foundation
224</BODY>
225</HTML>
Note: See TracBrowser for help on using the repository browser.