hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Hadoop Wiki] Update of "Hive/HowToContribute" by JohnSichi
Date Tue, 26 Jan 2010 22:14:52 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Hadoop Wiki" for change notification.

The "Hive/HowToContribute" page has been changed by JohnSichi.
http://wiki.apache.org/hadoop/Hive/HowToContribute?action=diff&rev1=13&rev2=14

--------------------------------------------------

  
  == Generating Code ==
  
- Some portions of the metastore code are generated by [[http://incubator.apache.org/thrift/|thrift]].
 For most Hive changes, you don't need to worry about this, but if you end up needing to change
the file metastore/if/hive_metastore.thrift, then you'll also need to regenerate these files
and submit their updated versions as part of your patch.
+ Some portions of the metastore code are generated by [[http://incubator.apache.org/thrift/|thrift]].
 For most Hive changes, you don't need to worry about this, but if you end up needing to change
the file {{{metastore/if/hive_metastore.thrift}}}, then you'll also need to regenerate these
files and submit their updated versions as part of your patch.
  
  Steps:
  
+  1. Don't make any changes to {{{hive_metastore.thrift}}} until instructed below.
   1. Use the approved version of thrift.  This is currently {{{thrift-instant-r790732}}},
which you can obtain from http://instant.thrift-rpc.org.
   1. Build the thrift compiler from its sources, then install it:
   1. {{{cd /path/to/thrift-instant-rXYZ}}}
   1. {{{./configure --without-csharp --without-ruby}}}
   1. {{{make}}}
   1. {{{sudo make install}}}
-  1. Now verify that {{{which thrift}}} returns the build of thrift you just installed (typically
{{{/usr/local/bin}}} on Linux); if not, edit your PATH before proceeding and repeat the verification.
+  1. Before proceeding, verify that {{{which thrift}}} returns the build of thrift you just
installed (typically {{{/usr/local/bin}}} on Linux); if not, edit your PATH and repeat the
verification.
+  1. Now you can run the thrift compiler to generate code:
   1. {{{cd /path/to/hive-trunk/metastore}}}
   1. {{{ant thriftif}}}
-  1. Use {{{svn status}}} and {{{svn diff}}} to verify that the regenerated code corresponds
only to the changes you made to hive_metastore.thrift.  You may also need {{{svn add}}} if
new files were generated (and {{{svn remove}}} if files have been obsoleted).  If you see
spurious noise in the changes, you probably used the wrong version of thrift.  If you can't
figure out what is going wrong, ask for help from a committer.
+  1. Use {{{svn status}}} to verify that the code generation was a no-op, which should be
the case if you have the correct thrift version and everyone has been following these instructions.
 If you can't figure out what is going wrong, ask for help from a committer.
+  1. Now make your changes to {{{hive_metastore.thrift}}}, and then run the compiler again:
+  1. {{{ant thriftif}}}
+  1. Now use {{{svn status}}} and {{{svn diff}}} to verify that the regenerated code corresponds
only to the changes you made to {{{hive_metastore.thrift}}}.  You may also need {{{svn add}}}
if new files were generated (and {{{svn remove}}} if files have been obsoleted).
   1. {{{cd /path/to/hive-trunk}}}
   1. {{{ant clean package}}}
   1. Verify that hive is still working correctly

Mime
View raw message