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
@InjectMocks | |
private MoipAccountTransferExecutor executor; | |
@Mock | |
private SchedulingService schedulingService; | |
/** | |
* schedulingService é o mock que irá receber List<Scheduling>. | |
* Saber quantos elementos tem nesta lista é importante para saber se | |
* a transfer entre constas moip irá gerar a quantidade correta de entries |
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
create database mini-paycom; | |
CREATE TABLE mini-paycom.order ( | |
id INT AUTO_INCREMENT NOT NULL, | |
customer VARCHAR(100) NOT NULL, | |
amount INT NOT NULL, | |
created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, | |
updated_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | |
PRIMARY KEY (id) | |
); |
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
# These are defaults. This file just demonstrates how to override some settings. | |
bootstrap.servers=localhost:9092 | |
# unique name for the cluster, used in forming the Connect cluster group. Note that this must not conflict with consumer group IDs | |
group.id=connect-cluster | |
# The converters specify the format of data in Kafka and how to translate it into Connect data. Every Connect user will | |
# need to configure these based on the format they want their data in when loaded from or stored into Kafka | |
key.converter=org.apache.kafka.connect.json.JsonConverter | |
value.converter=org.apache.kafka.connect.json.JsonConverter |
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
{ | |
"name": "cdc-mysql-source", | |
"config": { | |
"connector.class": "io.confluent.connect.jdbc.JdbcSourceConnector", | |
"tasks.max": 1, | |
"connection.url": "jdbc:mysql://127.0.0.1:6603/mini-paycom?user=root&password=root", | |
"table.whitelist": "payment,order", | |
"mode": "timestamp+incrementing", | |
"timestamp.column.name": "updated_at", | |
"incrementing.column.name": "id", |
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
#KAFKA ALIAS | |
alias k-zookeeper-start='~/development/servers/confluent/./bin/zookeeper-server-start ~/development/servers/confluent/etc/kafka/zookeeper.properties' | |
alias k-kafka-start='~/development/servers/confluent/./bin/kafka-server-start ~/development/servers/confluent/etc/kafka/server.properties' | |
alias k-kafka-rest-start='~/development/servers/confluent/./bin/kafka-rest-start' | |
alias k-kafka-rest-stop='~/development/servers/confluent/./bin/kafka-rest-stop' | |
alias k-register-start='~/development/servers/confluent/./bin/schema-registry-start ~/development/servers/confluent/etc/schema-registry/schema-registry.properties' | |
alias k-list-topics='~/development/servers/confluent/./bin/kafka-topics --list --zookeeper localhost:2181' | |
alias k-create-topic='~/development/servers/confluent/./bin/kafka-topics --create --zookeeper localhost:2181 --replication-factor 1 --partitions 5 --topic ' | |
alias k-del-topic='~/development/servers/confluent/./bin/kafka-topics --zookeeper localhost:2181 --delete --topic ' |
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
/** | |
* Manually, no big deal | |
* ObjectNode representes a Json. When you create a HTTP Post, this object should be enough or send it as a converted String | |
**/ | |
public class JsonJacksonTest { | |
@Test | |
public void testJsonByHand() { | |
ObjectMapper objectMapper = new ObjectMapper(); |
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 de.conrad.crm360.createofferservice; | |
import com.google.common.collect.Lists; | |
import jdepend.framework.JDepend; | |
import jdepend.framework.JavaPackage; | |
import jdepend.framework.PackageFilter; | |
import org.junit.Test; | |
import java.io.IOException; |