Skip to content

Hi! I cleaned up your code for you! #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<artifactId>bigbird-api</artifactId>
<version>0.1-SNAPSHOT</version>
<name>API</name>

<dependencies>
<dependency>
<groupId>org.slf4j</groupId>
Expand All @@ -36,7 +36,7 @@
<artifactId>log4j</artifactId>
<version>1.2.14</version>
</dependency>

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
Expand Down
1 change: 0 additions & 1 deletion api/src/main/java/bigbird/BackendException.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,3 @@ public BackendException(Throwable cause) {


}

4 changes: 2 additions & 2 deletions benchmark/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
<version>4.0.1</version>
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
Expand All @@ -46,5 +46,5 @@
</plugin>
</plugins>
</build>

</project>
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ public void run() {

try {
HttpRequest req = requestGenerator.generateRequest(count);

if (!conn.isOpen()) {
Socket socket = null;
if ("https".equals(targetHost.getSchemeName())) {
Expand Down
18 changes: 9 additions & 9 deletions benchmark/src/main/java/bigbird/benchmark/HttpBenchmark.java
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public class HttpBenchmark {
protected int socketTimeout = 60000;
protected boolean useHttp1_0 = false;
protected RequestGenerator[] requestGenerators;

public void setRequests(int requests) {
this.requests = requests;
}
Expand All @@ -82,29 +82,29 @@ public void execute() {
for (RequestGenerator g : requestGenerators) {
g.setParameters(params);
}

host = new HttpHost(url.getHost(), url.getPort(), url.getProtocol());

ThreadPoolExecutor workerPool = new ThreadPoolExecutor(
threads, threads, 5, TimeUnit.SECONDS,
new LinkedBlockingQueue<Runnable>(),
new ThreadFactory() {

public Thread newThread(Runnable r) {
return new Thread(r, "ClientPool");
}

});
workerPool.prestartAllCoreThreads();

BenchmarkWorker[] workers = new BenchmarkWorker[threads];
for (int i = 0; i < threads; i++) {
workers[i] = new BenchmarkWorker(
params,
verbosity,
requestGenerators[i],
host,
requests,
params,
verbosity,
requestGenerators[i],
host,
requests,
keepAlive);
workerPool.execute(workers[i]);
}
Expand Down
2 changes: 1 addition & 1 deletion buildsetup/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -164,5 +164,5 @@
</plugin>
</plugins>
</build>

</project>
2 changes: 1 addition & 1 deletion cacti-templates/c_cq_snapshot.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<cacti>
<cacti>
<hash_000016de0fadb4756b4c6792918b70bea6747c>
<name>Voldemort Command Queue Snapshot</name>
<graph>
Expand Down
2 changes: 1 addition & 1 deletion cacti-templates/t_cq_thread_status.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<cacti>
<cacti>
<hash_0000160f46d5a301f22059974c763b4f26073c>
<name>Tatter CQ Thread Status</name>
<graph>
Expand Down
2 changes: 1 addition & 1 deletion cacti-templates/t_t_thread_status.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<cacti>
<cacti>
<hash_000016963b3be3f1af082ecedad0731458d012>
<name>Tatter T Thread Status</name>
<graph>
Expand Down
2 changes: 1 addition & 1 deletion cacti-templates/v_f_snapshot.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<cacti>
<cacti>
<hash_0000169ff91b08cba76810593ef713f775696e>
<name>Voldemort Friends Timeline Snapshot</name>
<graph>
Expand Down
2 changes: 1 addition & 1 deletion cacti-templates/v_store_ex.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<cacti>
<cacti>
<hash_00001656c842821d427be1dbc019f205cfc0ed>
<name>Voldemort Store Exceptions</name>
<graph>
Expand Down
2 changes: 1 addition & 1 deletion cacti-templates/v_t_snapshot.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<cacti>
<cacti>
<hash_000016f1901872a9ec3a4fd5cc46d81c8c6939>
<name>Voldemort Tweets Snapshot</name>
<graph>
Expand Down
2 changes: 1 addition & 1 deletion cacti-templates/v_thead_status.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<cacti>
<cacti>
<hash_00001651712bb5c0ed326fc4d298ed0e39d5e8>
<name>Voldemort Node Thread Status</name>
<graph>
Expand Down
2 changes: 1 addition & 1 deletion cacti-templates/v_users_snapshot.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<cacti>
<cacti>
<hash_000016d47e63be1c7073570b1be4f741c1d782>
<name>Voldemort Users Snapshot</name>
<graph>
Expand Down
4 changes: 2 additions & 2 deletions couchdb/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@
<artifactId>bigbird-couchdb</artifactId>
<version>0.1-SNAPSHOT</version>
<name>CouchDB Backend</name>

<dependencies>
<dependency>
<groupId>bigbird</groupId>
<artifactId>bigbird-api</artifactId>
<version>${version}</version>
</dependency>

<dependency>
<groupId>com.google.code.jcouchdb</groupId>
<artifactId>jcouchdb</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion couchdb/src/test/java/log4j.properties
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ log4j.appender.DRFA.layout.ConversionPattern=%d %-5p [%t] %C{2}(%L): %m%n

#
# console
# Add "console" to rootlogger above if you want to use this
# Add "console" to rootlogger above if you want to use this
#
log4j.appender.console=org.apache.log4j.ConsoleAppender
log4j.appender.console.target=System.err
Expand Down
4 changes: 2 additions & 2 deletions ops/src/main/scripts/tomcat-init.d
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ status() {
echo 'foo'
}

case $1 in
case $1 in
'status')
status
;;

'start')
start
start
;;

'stop')
Expand Down
10 changes: 5 additions & 5 deletions ops/src/main/scripts/voldemort
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ start() {
pids=`ps xwww | grep voldemort.server.VoldemortServe[r] | awk '{print $1}'`

if [ "$pids" != "" ]
then
then
echo $(hostname)': Voldemort is already running under ${pids}...'
else
echo $(hostname)': Starting Voldemort...'
echo $(hostname)': Starting Voldemort...'
/opt/voldemort/bin/voldemort-server.sh /opt/voldemort/config > /var/log/voldemort.log &
fi
}
Expand All @@ -31,17 +31,17 @@ status() {
else
echo $(hostname)': Voldemort is not running.'
fi

}

case $1 in
case $1 in

'status')
status
;;

'start')
start
start
;;

'stop')
Expand Down
8 changes: 4 additions & 4 deletions ops/src/main/scripts/voldemort-init.d
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ start() {
pids=`ps xwww | grep voldemort.server.VoldemortServe[r] | awk '{print $1}'`

if [ "$pids" != "" ]
then
then
echo $(hostname)': Voldemort is already running under '${pids}'...'
else
/opt/voldemort/bin/voldemort-server.sh /opt/voldemort-home >> /var/log/voldemort.log 2>&1 &
Expand All @@ -29,17 +29,17 @@ status() {
else
echo $(hostname)': Voldemort is not running.'
fi

}

case $1 in
case $1 in

'status')
status
;;

'start')
start
start
;;

'stop')
Expand Down
8 changes: 4 additions & 4 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@
<version>0.1-SNAPSHOT</version>
<packaging>pom</packaging>
<name>Tatter</name>

<properties>
<hadoop.version>0.18.1</hadoop.version>
<voldemort.version>SNAPSHOT</voldemort.version>
<jcouchdb.version>0.9.0-2</jcouchdb.version>
<couchdb4j.version>0.1.2</couchdb4j.version>
<svenson.version>1.3.0</svenson.version>
</properties>

<modules>
<module>api</module>
<module>benchmark</module>
Expand All @@ -22,7 +22,7 @@
<module>voldemort</module>
<module>web</module>
</modules>

<dependencies>
<dependency>
<groupId>junit</groupId>
Expand Down Expand Up @@ -75,5 +75,5 @@
</plugin>
</plugins>
</build>

</project>
2 changes: 1 addition & 1 deletion queue/src/test/resources/log4j.properties
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ log4j.appender.DRFA.layout.ConversionPattern=%d %-5p [%t] %C{2}(%L): %m%n

#
# console
# Add "console" to rootlogger above if you want to use this
# Add "console" to rootlogger above if you want to use this
#
log4j.appender.console=org.apache.log4j.ConsoleAppender
log4j.appender.console.target=System.err
Expand Down
6 changes: 3 additions & 3 deletions voldemort/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<artifactId>bigbird-voldemort</artifactId>
<version>0.1-SNAPSHOT</version>
<name>Voldemort!</name>

<dependencies>
<dependency>
<groupId>bigbird</groupId>
Expand Down Expand Up @@ -109,7 +109,7 @@
<version>1.2.14</version>
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
Expand All @@ -125,5 +125,5 @@
</plugin>
</plugins>
</build>

</project>
10 changes: 5 additions & 5 deletions web/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<version>0.1-SNAPSHOT</version>
<name>Web Interface</name>
<packaging>war</packaging>

<dependencies>
<dependency>
<groupId>bigbird</groupId>
Expand All @@ -29,13 +29,13 @@
<version>${version}</version>
<type>test-jar</type>
</dependency>

<dependency>
<groupId>org.springframework.security</groupId>
<artifactId>spring-security-core</artifactId>
<version>2.0.4</version>
</dependency>

<dependency>
<groupId>com.sun.jersey</groupId>
<artifactId>jersey-server</artifactId>
Expand Down Expand Up @@ -80,7 +80,7 @@
<version>1.1.0</version>
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
Expand All @@ -107,7 +107,7 @@
</plugin>
</plugins>
</build>

<repositories>
<repository>
<id>java.net</id>
Expand Down
Loading