This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mvn archetype:generate -DgroupId=com.javacodegeeks -DartifactId=SampleApplication -DarchetypeArtifactId=maven-archetype-quickstart -DinteractiveMode=false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--[[ | |
RATELIMIT LUA script does the following : | |
1. Increments counter for the supplied bucket. | |
2. Deletes the subsequent buckets. | |
3. Renews expiry time for the subjectKey | |
KEYS[1]: subject's key | |
ARGV[1]: bucket number | |
ARGV[2]: subject expiry in seconds | |
ARGV[3]: buckets to clear ahead |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2014-01-16 20:29:08:228 [INFO ] [main] [TestKafkaConsumer] - Zookeeper url :192.168.64.210:2181 | |
2014-01-16 20:29:08:403 [INFO ] [main] [VerifiableProperties] - Verifying properties | |
2014-01-16 20:29:08:428 [INFO ] [main] [VerifiableProperties] - Property auto.commit.interval.ms is overridden to 6000 | |
2014-01-16 20:29:08:428 [INFO ] [main] [VerifiableProperties] - Property group.id is overridden to consumer.group.1 | |
2014-01-16 20:29:08:428 [INFO ] [main] [VerifiableProperties] - Property zookeeper.connect is overridden to 192.168.64.210:2181 | |
2014-01-16 20:29:08:428 [INFO ] [main] [VerifiableProperties] - Property zookeeper.session.timeout.ms is overridden to 10000 | |
2014-01-16 20:29:08:429 [INFO ] [main] [VerifiableProperties] - Property fetch.wait.max.ms is overridden to 100 | |
2014-01-16 20:29:08:429 [INFO ] [main] [VerifiableProperties] - Property consumer.timeout.ms is overridden to 100 | |
2014-01-16 20:29:08:465 [INFO ] [main] [ZookeeperConsumerConnector] - [consumer.group.1_Impetus-L292-1389884348463-3e0deb32], Con |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.nsinfra.camel; | |
import org.apache.camel.spring.Main; | |
public class SpringCamelMain { | |
public static void main(String[] args) throws Exception { | |
/** | |
* Loads spring application context files kept under | |
* META-INF/spring folder placed in CLASSPATH |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<beans xmlns="http://www.springframework.org/schema/beans" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd | |
http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring-2.10.1.xsd"> | |
<camelContext id="demoCamelContext" xmlns="http://camel.apache.org/schema/spring"> | |
<route id="demoCBRRoute"> | |
<from | |
uri="activemq:queue:NewOrders?brokerURL=tcp://192.168.64.144:61616" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.nsinfra.camel; | |
import org.apache.camel.CamelContext; | |
import org.apache.camel.builder.RouteBuilder; | |
import org.apache.camel.impl.DefaultCamelContext; | |
public class JavaDSLMain extends RouteBuilder { | |
/** | |
* {@link RouteBuilder#configure()} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>org.nsinfra</groupId> | |
<artifactId>demoOne</artifactId> | |
<packaging>jar</packaging> | |
<version>1.0</version> |