Skip to content

Instantly share code, notes, and snippets.

View jayunit100's full-sized avatar
🎯
Focusing

jay vyas jayunit100

🎯
Focusing
View GitHub Profile
package org.roofmonkey.hadoop.glusterfs;
import java.io.IOException;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.Writer;
import java.util.HashSet;
import java.util.Set;
import java.util.StringTokenizer;
@jayunit100
jayunit100 / Hadoop_Stripping_Headers
Last active December 19, 2015 14:29
Hadoop_Stripping_Headers.java
package org.roofmonkey.hadoop.glusterfs;
import java.io.IOException;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.Writer;
import java.util.HashSet;
import java.util.Set;
import java.util.StringTokenizer;
@jayunit100
jayunit100 / puppet example 1
Created July 24, 2013 04:39
An example puppet manifest
node default {
include jenkins
include wget
include openjdk
include archiva
jenkins::plugin {'swarm':}
jenkins::plugin {'git':}
include firewall
testrel test.sh
[root@jvyas test_archiva]# ./test.sh 1.0
--2013-08-05 12:38:49-- http://23.23.239.119/archiva/repository/internal/org/apache/hadoop/fs/glusterfs/glusterfs-hadoop/1.0/glusterfs-hadoop-1.0.jar
Connecting to 23.23.239.119:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 21733 (21K) [application/java-archive]
Saving to: “glusterfs-hadoop-1.0.jar”
100%[==============================================================================================================================================>] 21,733 --.-K/s in 0.03s
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
There was an error while executing `VBoxManage`, a CLI used by Vagrant
for controlling VirtualBox. The command and stderr is shown below.
Command: ["import", "/Users/Jpeerindex/.vagrant.d/boxes/vagrant-fedora19B/virtualbox/box.ovf"]
Stderr: 0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
Interpreting /Users/Jpeerindex/.vagrant.d/boxes/vagrant-fedora19B/virtualbox/box.ovf...
OK.
0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...
Progress state: VBOX_E_FILE_ERROR
@jayunit100
jayunit100 / gist:6923234
Last active December 25, 2015 05:18
An example of a generating input format for map/reduce jobs with no hard coded input
/**
* An input split that generates (firstname lastname product) tuples.
* These simulate transactions at a pet store by clients.
* First iteration of the BigPetStore blueprint project.
*/
public static class TransactionGeneratorInputFormat extends
FileInputFormat<Text,Text> {
static final Integer TRANSACTIONS = 100;
static String[] FIRSTNAMES = new String[]{
@jayunit100
jayunit100 / gist:7033147
Created October 17, 2013 22:10
vagrant results hbase gluster
jays-MacBook-Pro:gluster-hbase-example Jpeerindex$ vagrant up
Bringing machine 'hbase1' up with 'virtualbox' provider...
Bringing machine 'hbase2' up with 'virtualbox' provider...
[hbase1] Importing base box 'vagrant-fedora19B2'...
[hbase1] Matching MAC address for NAT networking...
[hbase1] Setting the name of the VM...
[hbase1] Clearing any previously set forwarded ports...
[hbase1] Creating shared folders metadata...
[hbase1] Clearing any previously set network interfaces...
[hbase1] Preparing network interfaces based on configuration...
@jayunit100
jayunit100 / gist:7254065
Created October 31, 2013 17:56
simplesmoke for sqoop
hsql=`find $SQOOP_HOME/lib -name hsql*jar`
echo "hsql : $hsql"
rm -rf /tmp/sqsmoke
# Create db permissions
echo "
# A personal, local, persistent database.
urlid smoketest
url jdbc:hsqldb:file:/tmp/sqsmoke;shutdown=true