augustogiles
augustogiles
Reputation Top 10%
augustogiles
2 Snippets  (291st place)
Published
1 Channel
Created
2 Channels
Following
31 points  (1140th place)
Reputation
Junior Code Generator
Junior Popular Coder
Junior Autobiographer
Serious Autobiographer
Junior Snip2Coder
Junior Famous Coder
Junior Wise Coder

Recent Snippets See all snippets by augustogiles

public by augustogiles  3034  7  4  -2

Escolher o schema (já listados no main) e setá-lo no atributo mapName. Os atributos owner, filterPage, genericBrand, createReplyTable, createPrivateMessageTable normalmente são false. O atributo category normalmente é null. languageFilter = true. Preen...

Escolher o schema (já listados no main) e setá-lo no atributo mapName. Os atributos owner, filterPage, genericBrand, createReplyTable, createPrivateMessageTable normalmente são false. O atributo category normalmente é null. languageFilter = true. Preencher os campos brandName (não colocar caracteres especiais no nome da brand), userName, password (
package elife.fbmeter.etl.logic;

import java.io.BufferedReader;
import java.io.FileReader;
import java.io.IOException;
import java.security.spec.InvalidParameterSpecException;
import java.sql.DatabaseMetaData;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Timestamp;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.LinkedList;
import java.util.List;

import elife.fbmeter.etl.data.AuthorDAO;
import elife.fbmeter.etl.data.MapDAO;
import elife.fbmeter.etl.model.Author;
import elife.fbmeter.etl.model.Feed;
import elife.fbmeter.etl.model.Map;
import elife.fbmeter.etl.model.Post;
import elife.fbmeter.etl.util.JDBCConnection;
import elife.fbmeter.etl.util.Util;

public class Etl {


	//	public static void main1(String[] args) throws Exception {
	//		
	//		String parametros = "facebookmeter---facebookmeter_data---zon---2---236---Zon---140762494935---http://www.facebook.com/pages/ZON-Lusomundo/140762494935---pt_PT---Zon";
	//		args = parametros.split("---");
	//		
	//		String hostName = args[0];// "facebookmeter_2011";
	//		String mapName = args[1];//"facebookmeter_data";
	//		String userName = args[2];//"ades";
	//		Long userId = Long.valueOf(args[3]);//604L;
	//		String brandIds = args[4];//"108,109,110";
	//		String brandName = args[5];//"Ades";
	//		Long authorId = (args[6].equals("null") ? null : Long.valueOf(args[6]));// 126196530731714L;
	//		String pageUrl = (args[7].equals("null") ? null : args[7]);//"http://www.facebook.com/adesbrasil";
	//		String locale = args[8];//"pt_BR";
	//		String category = args[9];//"Unilever";
	//		String password = args[10];
	//
	//		JDBCConnection from = new JDBCConnection("174.123.19.114", hostName, "fbsearch", "armando210687");
	//		JDBCConnection to = new JDBCConnection("50.23.32.185", mapName, "fbmeter", "938271");
	//		JDBCConnection fromMapper = new JDBCConnection("174.123.19.114", "facebookmeter_map", "fbsearch", "armando210687");
	//		JDBCConnection toMapper = new JDBCConnection("50.23.32.185", "facebookmeter_mapper", "fbmeter", "938271");
	//	
	//		boolean owner = true;
	//		
	//		Etl.migrateBrand(from,to,toMapper,fromMapper,mapName,brandName,pageUrl,locale,category,brandIds,authorId,userName,userId,owner,password);
	//	}

	//	public static void migrateBrand(JDBCConnection from, JDBCConnection to, JDBCConnection toMapper, JDBCConnection fromMapper, 
	//			String mapName, String brandName, String pageUrl, String locale, String category, String brandsIds, String authorId, 
	//			String userName, Long userId, boolean owner, String password ) throws InvalidParameterSpecException, SQLException{
	//
	//		//CARREGA POSTS E FEEDS
	//		System.out.println("Iniciando Extra��o dos posts...");
	//		List<Post> posts = E.getPostsByBrands(from,brandsIds,authorId);
	//		System.out.println(posts.size());
	//		System.out.println("Iniciando Extra��o dos feeds...");
	//		List<Feed> feeds = E.getFeedsByAuthor(from,authorId,true);
	//		if(feeds != null){ System.out.println(feeds.size());}
	//		System.out.println("Iniciando Extra��o dos feeds dos usu�rios...");
	//		List<Feed> feedsByUsers = E.getFeedsByAuthor(from,authorId,false);
	//		if(feedsByUsers != null){System.out.println(feedsByUsers.size());}
	//
	//		//CARREGA COMENT�RIOS
	//		System.out.println("Carregando coment�rios de posts...");
	//		E.getPostsComments(from, posts);
	//		if(feeds != null){
	//			System.out.println("Carregando coment�rios de feeds...");
	//			E.getFeedsComments(from,feeds);
	//		}
	//		if(feedsByUsers != null){
	//			System.out.println("Carregando coment�rios de feeds by users...");
	//			E.getFeedsComments(from, feedsByUsers);
	//		}
	//		
	//		//CARREGA TERMS
	//		System.out.println("Carregando terms");
	//		String terms = E.getTerms(from, brandsIds);
	//
	//		//CRIA AS BASES
	//		System.out.println("Criando a base...");
	//		T.createBases(to,brandName);
	//
	//		//INSERE NO MAPPER
	//		System.out.println("Inserindo user e brands");
	//		L.loadUser(toMapper,userName,password);
	//		L.loadBrand(toMapper,mapName,terms,null,userName,brandName,pageUrl,locale,category,authorId,owner,false,null);
	//
	//		//INSERE POSTS e FEEDS
	//		System.out.println("Inseindo posts...");
	//		L.loadPosts(to,posts,brandName.toLowerCase().replace(" ", "_"));
	//		if(feeds != null){
	//			System.out.println("Inseindo feeds...");
	//			L.loadFeeds(to,feeds,brandName.toLowerCase().replace(" ", "_"));
	//		}
	//		if(feedsByUsers != null){
	//			System.out.println("Inseindo feeds...");
	//			L.loadFeeds(to,feedsByUsers,brandName.toLowerCase().replace(" ", "_"));
	//		}
	//		
	//		//INSERE COMMENTS
	//		System.out.println("Inseindo posts comments...");
	//		L.loadPostsComments(to,posts,brandName.toLowerCase().replace(" ", "_"));
	//		if(feeds != null){
	//			System.out.println("Inseindo feeds comments...");
	//			L.loadFeedsComments(to,feedsByUsers,brandName.toLowerCase().replace(" ", "_"));
	//		}
	//		if(feeds != null){
	//			System.out.println("Inseindo feeds comments...");
	//			L.loadFeedsComments(to,feedsByUsers,brandName.toLowerCase().replace(" ", "_"));
	//		}
	//
	//	}

	//CRIA UMA NOVA BRAND
	public static void main(String args[]) throws Exception{
		//		JDBCConnection to = new JDBCConnection("173.193.126.214", "facebookmeter_data_cocacola", "root", "9wenesex");
		//		JDBCConnection to = new JDBCConnection("50.112.180.232", "facebookmeter2_data_32", "root", "kes4abe8adedaswe");
		//		JDBCConnection to = new JDBCConnection("174.123.19.114", "facebookmeter_data_espanha", "fbsearch", "armando210687");
		//		JDBCConnection to = new JDBCConnection("50.23.32.185", "facebookmeter_data_santander", "fbmeter", "938271");
		//		JDBCConnection to = new JDBCConnection("54.244.1.115", "facebookmeter_data_4", "root", "gest73ruh2naxadr");
		//		JDBCConnection to = new JDBCConnection("50.23.14.108", "facebookmeter_data_generics", "root", "SdhFB1cm00DW");
		//		JDBCConnection to = new JDBCConnection("50.112.180.232", "facebookmeter2_data_62", "root", "kes4abe8adedaswe");
		//		JDBCConnection to = new JDBCConnection("54.208.56.16", "facebookmeter2_data_52", "root", "p2ucs6SCiZ");
		//		JDBCConnection to = new JDBCConnection("74.52.74.18", "facebookmeter_data_saas", "root", "Dkqze3u6im");
		//		JDBCConnection to = new JDBCConnection("fbmeter.ckgikzcuozwi.us-east-1.rds.amazonaws.com", "facebookmeter_data_avenidabrasil", "root", "F4qAca8RehesEx56");
		//		JDBCConnection to = new JDBCConnection("74.52.74.18", "facebookmeter_data_avenidabrasil", "root", "Dkqze3u6im");	
		//		JDBCConnection to = new JDBCConnection("54.244.2.17", "facebookmeter_data_72", "root", "sputac5aprafaqad");
		//		JDBCConnection to = new JDBCConnection("54.244.2.17", "facebookmeter_data_temp", "root", "sputac5aprafaqad");
		//		JDBCConnection to = new JDBCConnection("107.23.172.26", "facebookmeter_data_bbb", "root", "hequw4e6");
				JDBCConnection to = new JDBCConnection("107.23.172.26", "facebookmeter2_data_9", "root", "hequw4e6");
		//		JDBCConnection to = new JDBCConnection("107.23.172.26", "facebookmeter_data_bayer", "root", "hequw4e6");
		//		JDBCConnection to = new JDBCConnection("fbmeter.ckgikzcuozwi.us-east-1.rds.amazonaws.com", "facebookmeter_data_saas_rds", "root", "prU5rusw2ph3waqa");
		//		JDBCConnection to = new JDBCConnection("107.23.193.113", "facebookmeter_data_vueling", "root", "phuthe4a7rucu7ra");
		//		JDBCConnection to = new JDBCConnection("50.112.181.15", "facebookmeter_data_schincariol", "root", "2rucruthez82heke");
		//		JDBCConnection to = new JDBCConnection("54.244.1.85", "facebookmeter_data_walmart", "root", "qasw83hafr8qejat");
//				JDBCConnection to = new JDBCConnection("54.244.1.85", "facebookmeter2_data_8", "root", "qasw83hafr8qejat");
		//		JDBCConnection to = new JDBCConnection("54.244.1.91", "facebookmeter_data_genericbrands", "root", "pherawr3phewruch");
		//		JDBCConnection to = new JDBCConnection("54.244.1.91", "facebookmeter2_data_globo", "root", "pherawr3phewruch");
		//		JDBCConnection to = new JDBCConnection("54.244.1.91", "facebookmeter_data_globoteste", "root", "pherawr3phewruch");
		//		JDBCConnection to = new JDBCConnection("54.244.1.91", "facebookmeter_data_groups", "root", "pherawr3phewruch");
		//		JDBCConnection to = new JDBCConnection("54.208.61.122", "facebookmeter_data2", "root", "p2ucs6SCiZ");
		//		JDBCConnection to = new JDBCConnection("54.208.214.61", "facebookmeter_data_generic_1", "root", "p2ucs6SCiZ");
		//		JDBCConnection to = new JDBCConnection("54.193.45.123", "facebookmeter_data_generic_2", "root", "flg1Gsk1");
		//		JDBCConnection to = new JDBCConnection("54.193.72.124", "facebookmeter_data_globo_bbb", "root", "p2ucs6SCiZ");
		//		JDBCConnection to = new JDBCConnection("54.193.72.124", "facebookmeter_data_globo_carnavaleoscar", "root", "p2ucs6SCiZ");
		//		JDBCConnection to = new JDBCConnection("54.208.61.122", "facebookmeter_data_santander2", "root", "p2ucs6SCiZ");
		//		JDBCConnection to = new JDBCConnection("54.208.56.16", "facebookmeter2_data_cocacola2", "root", "p2ucs6SCiZ");
		//		JDBCConnection to = new JDBCConnection("localhost", "fbm-mapper", "root", "");


		//		JDBCConnection toMapper = new JDBCConnection("localhost", "fbm-mapper", "root", "");
		JDBCConnection toMapper = new JDBCConnection("fbm-mapper.c86wtlra7auy.us-west-2.rds.amazonaws.com", "facebookmeter_mapper", "root", "4egafepededacetu");
		/*

#minhaparadanosjogosescolares OR "jogos escolares" OR (jogos coca (londrina OR joao pessoa)) OR "jogos da juventude" OR #jogosdajuventude OR #jogosescolares OR #jogosescolaresdajuventude

E a seguinte página: https://www.facebook.com/jogosescolaresdajuventude

		 */

		String brandName = "Audi Portugal";
		String userName = "audi_pt";
		String password = "para15";
		String mapName = "facebookmeter2_data_9";
		String terms = null;
		String booleanTerm = null;
		String pageUrl = "https://www.facebook.com/PTAudi";
		String locale = "pt_PT";
		String category = null;
		String authorId = "359431947423356";
		boolean owner = false;
		boolean languageFilter = true;
		String next_fetch = Long.toString(Util.BuildDateUnix(""));
		boolean filterPage = false;
		boolean genericBrand = true;
		boolean createReplyTable = false;
		boolean createPrivateMessageTable = false;
		//CRIA AS BASES
		System.out.println("Criando a base...");
		T.createBases(to,brandName,createReplyTable, createPrivateMessageTable);
		T.createPMBases(toMapper, userName);

		//INSERE NO MAPPER
		System.out.println("Inserindo user e brands");
		L.loadUser(toMapper,userName,password);
		L.loadBrand(toMapper,mapName,terms,booleanTerm,userName,brandName,pageUrl,locale,category,authorId,owner,languageFilter,next_fetch,filterPage,genericBrand);


		System.out.println("Finalizado!!!");
	}

	//	public static void main3(String[] args) {
	//		Etl.migrateAllPosts();
	//	}
	//	

	//Create PMs tables
	public static void mainPM(String[] args) throws InvalidParameterSpecException, SQLException{
		JDBCConnection fromTo = new JDBCConnection("fbm-mapper.c86wtlra7auy.us-west-2.rds.amazonaws.com", "facebookmeter_mapper", "root", "4egafepededacetu");
		List<String> userNames = E.getUsersFromPrivateMessages(fromTo);
		T.createPMBases(fromTo, userNames);
		L.loadPMs(fromTo,userNames);
	}

	public static void migrateAllPosts(){
		JDBCConnection from = new JDBCConnection("174.123.19.114", "facebookmeter", "fbsearch", "armando210687");
		JDBCConnection to = new JDBCConnection("localhost", "facebookmeter", "root", "456789");
		List<Post> posts = new ArrayList<Post>(); 
		boolean continuar = true;
		from.createTransaction();
		to.createTransaction();
		PreparedStatement statement = null;
		ResultSet rs = null;
		PreparedStatement st2 = null;
		Post p = null;
		Author a = null;
		int limit = 100000;
		int offset = 3780000;
		while(continuar){
			continuar = false;
			try {
				from.createTransaction();
				String ids = Etl.getPostsIds(from);
				System.out.println("pegou ids");
				statement = from.getConnection().prepareStatement("SELECT * FROM post WHERE id2 IN ("+ids+")");
				System.out.println(statement);
				rs = statement.executeQuery();
				System.out.println("...");
				while(rs.next()){
					continuar = true;
					p = new Post();
					p.setId(rs.getString("id2"));
					SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ssZ");
					Timestamp createdAt = rs.getTimestamp("created_at");
					p.setCreated_time(sdf.format(new Date(createdAt.getTime())));
					p.setMessage(rs.getString("content"));
					p.setLikes(rs.getInt("likes"));
					Timestamp updatedAt = rs.getTimestamp("updated_at");
					p.setUpdated_time(sdf.format(new Date(updatedAt.getTime())));
					p.setPicture(rs.getString("picture"));
					p.setLink(rs.getString("link"));
					p.setDescription(rs.getString("description"));
					p.setIcon(rs.getString("icon"));
					p.setName(rs.getString("name_link"));

					a = new Author();
					a.setId(rs.getString("author_id"));
					p.setFrom(a);

					posts.add(p);
				}
				System.out.println("inserindo");
				statement.close(); statement = null;
				rs.close(); rs = null;
				from.closeConnection();
				to.createTransaction();
				for (Post post : posts) {
					st2 = to.getConnection().prepareStatement("" +
							"INSERT IGNORE INTO `post` (`id`, `created_at`, `content`, `author_id`, `likes`, " +
							"`updated_at`, `picture`, `link`, `description`, `icon`, `id2`, `caption`, `name_link`) " +
							"VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?)");
					int index = 1;
					st2.setString(index++, post.getFrom().getId());
					st2.setDate(index++, new java.sql.Date(post.getCreatedTimeCalendar().getTimeInMillis()));
					st2.setString(index++, post.getMessage());
					st2.setString(index++, post.getFrom().getId());
					st2.setInt(index++, post.getLikes());
					st2.setDate(index++, new java.sql.Date(post.getUpdated_time().getTimeInMillis()));
					st2.setString(index++, post.getPicture());
					st2.setString(index++, post.getLink());
					st2.setString(index++, post.getDescription());
					st2.setString(index++, post.getIcon());
					st2.setString(index++, post.getId());
					st2.setString(index++, post.getCaption());
					st2.setString(index++, post.getName());
					st2.execute();
				}

				System.out.println("carregou "+(offset+posts.size())+" posts");
				offset += limit;
				posts.clear();
				to.commitTransaction();
				to.closeConnection();
			} catch (SQLException e) {
				// TODO Auto-generated catch block
				e.printStackTrace();
			}
		}
	}
	public static void main2(String[] args) throws InvalidParameterSpecException, SQLException, IOException {
		JDBCConnection to = new JDBCConnection("107.23.172.26", "facebookmeter2_data_9", "root", "hequw4e6");

		String brandName = "";
		String mapName = "facebookmeter2_data_9";
		boolean createReplyTable = false;
		boolean createPrivateMessageTable = false;
		//CRIA AS BASES
		List<String> brands = nomes();
		for(String brand : brands){
			System.out.println("Criando a base...");
			T.createBases(to,brand,createReplyTable, createPrivateMessageTable);
			System.out.println("feito para "+brand);
		}
	}


	public static List<String> nomes() throws IOException{
		BufferedReader br = new BufferedReader(new FileReader("nome_brand.txt"));
		List<String> urls = new ArrayList<String>(); 

		try {
			String line = br.readLine();

			while (line != null) {
				//				System.out.println(line);
				urls.add(line);
				line = br.readLine();
			}

		} finally {
			br.close();
		}

		return urls;
	}

	public static void mainAlter(String[] args) {
		//		String schema = args[0];
		//		String minusString = args[1];
		//		String from = args[2];
		String schema = "facebookmeter_data_saas_rds";
		String minusString = "";
		String from = "";
		System.out.println("Schema: "+schema);
		System.out.println("Minus: "+minusString);
		List<String> minus = new LinkedList<String>();
		String[] minusSplit = minusString.split(",");
		for (int i = 0; i < minusSplit.length; i++) {
			minus.add(minusSplit[i]);
		}		
		JDBCConnection connectionMapper = new JDBCConnection("fbm-mapper.c86wtlra7auy.us-west-2.rds.amazonaws.com", "facebookmeter_mapper", "root", "4egafepededacetu");
		connectionMapper.createTransaction();
		try{
			Map map = MapDAO.getDataMap(connectionMapper, schema);
			Etl.alterSchemas(schema,minus,map,from);
		}finally{
			connectionMapper.closeConnection();
		}
	}

	public static void alterSchemas(String schema, List<String> minus, Map map, String from){
		JDBCConnection to = new JDBCConnection(map.getHost(), map.getSchema(), map.getUsername(), map.getPassword());

		to.createTransaction();
		StringBuilder failedTables = new StringBuilder();
		ResultSet rs = null;
		int count = 1;
		try {
			PreparedStatement statement = to.getConnection().prepareStatement("SELECT table_name FROM INFORMATION_SCHEMA.TABLES WHERE table_schema = ? " +
					(from != null && !from.isEmpty() ? "AND table_name > ?" : ""));
			statement.setString(1, schema);
			if(from != null && !from.isEmpty()){
				statement.setString(2, from);
			}
			rs = statement.executeQuery();
			PreparedStatement statement2 = null;			
			while(rs.next()){
				String tableName = rs.getString("table_name");
				//				if (tableName.startsWith("post_gás_natural_fenosa") ) {
				if (minus.indexOf(tableName) == -1) {
					try {
						statement2 = to
								.getConnection()
								.prepareStatement(
										//											"ALTER TABLE `"	+ tableName	+ "` " +
										//													"ADD COLUMN `comment_reply_id` BIGINT(20) NOT NULL DEFAULT '0' AFTER `comment_id`, DROP INDEX `id`, ADD UNIQUE INDEX `id` (`post_id`, `comment_id`, `comment_reply_id`);"
										"ALTER TABLE `"+tableName+"`  ADD COLUMN `comment_reply_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT '0' AFTER `comment_id`, DROP INDEX `id`, ADD UNIQUE INDEX `id` (`post_id`,`comment_id`,`comment_reply_id`); "
										);



						System.out.println("tabela: " + (count++) + " "	+ statement2);
						statement2.executeUpdate();
					} catch (Exception e) {
						e.printStackTrace();
						failedTables.append((!failedTables.toString()
								.isEmpty() ? "," : "")
								+ tableName);
					} finally {
						if (statement2 != null) {
							statement2.close();
						}
					}
				}
				if (minus.indexOf(tableName) == -1) {
					try {
						ResultSet rsColumns = null;
						DatabaseMetaData meta = to.getConnection()
								.getMetaData();
						rsColumns = meta.getColumns(null, map.getSchema(),
								tableName, "replied_element_id");

						boolean updatedRepliedElementId = false;
						while (rsColumns.next()) {
							if (rsColumns.getInt("COLUMN_SIZE") == 70) {
								updatedRepliedElementId = true;
							}
						}

						if (!updatedRepliedElementId) {
							statement2 = to
									.getConnection()
									.prepareStatement(
											//											"ALTER TABLE `"	+ tableName	+ "` " +
											//													"ADD COLUMN `comment_reply_id` BIGINT(20) NOT NULL DEFAULT '0' AFTER `comment_id`, DROP INDEX `id`, ADD UNIQUE INDEX `id` (`post_id`, `comment_id`, `comment_reply_id`);"
											"ALTER TABLE `"+tableName+"`  CHANGE COLUMN `replied_element_id` `replied_element_id` VARCHAR(70) NULL DEFAULT NULL AFTER `tags`;"
											);

							System.out.println("tabela: " + (count++) + " "	+ statement2);
							statement2.executeUpdate();
						}
					} catch (Exception e) {
						e.printStackTrace();
						failedTables.append((!failedTables.toString()
								.isEmpty() ? "," : "")
								+ tableName);
					} finally {
						if (statement2 != null) {
							statement2.close();
						}
					}
				}
				//				}
			}
			to.commitTransaction();
			System.out.println("Failed Tables:");
			System.out.println(failedTables);
		} catch (SQLException e) {
			to.rollBackTransaction();
			e.printStackTrace();
		}finally{
			to.closeConnection();
		}
	}

	private static String getPostsIds(JDBCConnection from) throws SQLException {
		StringBuilder ids = new StringBuilder(); 
		PreparedStatement statement = from.getConnection().prepareStatement("SELECT DISTINCT post_id2 FROM brand_post WHERE brand_id = 236");
		ResultSet rs = statement.executeQuery();
		ids.append("0");
		while(rs.next()){
			ids.append(","+rs.getString("post_id2"));
		}
		return ids.toString();
	}

}


;

public by augustogiles  100040  0  3  0

Error rake db:schema:load

Error rake db:schema:load: gistfile1.txt
rake db:schema:load
rake aborted!
/usr/local/rvm/gems/ruby-1.9.3-p551/gems/rake-10.0.4/lib/rake/trace_output.rb:18:in `block in trace_on': invalid byte sequence in US-ASCII (ArgumentError)
        from /usr/local/rvm/gems/ruby-1.9.3-p551/gems/rake-10.0.4/lib/rake/trace_output.rb:16:in `map'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/gems/rake-10.0.4/lib/rake/trace_output.rb:16:in `trace_on'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/gems/rake-10.0.4/lib/rake/application.rb:328:in `trace'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/gems/rake-10.0.4/lib/rake/application.rb:183:in `display_error_message'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/gems/rake-10.0.4/lib/rake/application.rb:169:in `rescue in standard_exception_handling'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/gems/rake-10.0.4/lib/rake/application.rb:159:in `standard_exception_handling'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/gems/rake-10.0.4/lib/rake/application.rb:70:in `run'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/gems/rake-10.0.4/bin/rake:33:in `<top (required)>'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/bin/rake:23:in `load'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/bin/rake:23:in `<main>'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/bin/ruby_executable_hooks:15:in `eval'
        from /usr/local/rvm/gems/ruby-1.9.3-p551/bin/ruby_executable_hooks:15:in `<main>'


;