projects
/
demos
/
kafka
/
wordcount
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
feb9d86
)
popular: 1.1.1 - Refined output JSON
popular-1.1.1
author
Kai Moritz
<kai@juplo.de>
Thu, 20 Jun 2024 19:50:15 +0000
(21:50 +0200)
committer
Kai Moritz
<kai@juplo.de>
Thu, 20 Jun 2024 19:50:15 +0000
(21:50 +0200)
pom.xml
patch
|
blob
|
history
src/main/java/de/juplo/kafka/wordcount/popular/WindowedWord.java
patch
|
blob
|
history
src/main/java/de/juplo/kafka/wordcount/popular/WordCounter.java
patch
|
blob
|
history
src/test/java/de/juplo/kafka/wordcount/popular/TestData.java
patch
|
blob
|
history
src/test/java/de/juplo/kafka/wordcount/stats/OutputWindowedWord.java
patch
|
blob
|
history
src/test/java/de/juplo/kafka/wordcount/stats/OutputWordCounter.java
patch
|
blob
|
history
diff --git
a/pom.xml
b/pom.xml
index
a9ba9e1
..
0c99200
100644
(file)
--- a/
pom.xml
+++ b/
pom.xml
@@
-10,7
+10,7
@@
</parent>
<groupId>de.juplo.kafka.wordcount</groupId>
<artifactId>popular</artifactId>
</parent>
<groupId>de.juplo.kafka.wordcount</groupId>
<artifactId>popular</artifactId>
- <version>1.1.
0
</version>
+ <version>1.1.
1
</version>
<name>Wordcount-Popular-Words</name>
<description>Query stream-processor that gives access to the most popular words</description>
<properties>
<name>Wordcount-Popular-Words</name>
<description>Query stream-processor that gives access to the most popular words</description>
<properties>
diff --git
a/src/main/java/de/juplo/kafka/wordcount/popular/WindowedWord.java
b/src/main/java/de/juplo/kafka/wordcount/popular/WindowedWord.java
index
df988fb
..
b759f2e
100644
(file)
--- a/
src/main/java/de/juplo/kafka/wordcount/popular/WindowedWord.java
+++ b/
src/main/java/de/juplo/kafka/wordcount/popular/WindowedWord.java
@@
-14,5
+14,5
@@
public class WindowedWord
{
ZonedDateTime start;
ZonedDateTime end;
{
ZonedDateTime start;
ZonedDateTime end;
- String
word
;
+ String
key
;
}
}
diff --git
a/src/main/java/de/juplo/kafka/wordcount/popular/WordCounter.java
b/src/main/java/de/juplo/kafka/wordcount/popular/WordCounter.java
index
c94ec0e
..
bc4243e
100644
(file)
--- a/
src/main/java/de/juplo/kafka/wordcount/popular/WordCounter.java
+++ b/
src/main/java/de/juplo/kafka/wordcount/popular/WordCounter.java
@@
-10,6
+10,6
@@
import lombok.NoArgsConstructor;
@AllArgsConstructor(staticName = "of")
public class WordCounter
{
@AllArgsConstructor(staticName = "of")
public class WordCounter
{
- String
word
;
+ String
key
;
long counter;
}
long counter;
}
diff --git
a/src/test/java/de/juplo/kafka/wordcount/popular/TestData.java
b/src/test/java/de/juplo/kafka/wordcount/popular/TestData.java
index
fa6a258
..
4ac9fd4
100644
(file)
--- a/
src/test/java/de/juplo/kafka/wordcount/popular/TestData.java
+++ b/
src/test/java/de/juplo/kafka/wordcount/popular/TestData.java
@@
-192,7
+192,7
@@
class TestData
windowedWord.setStart(ZonedDateTime.ofInstant(outputWindowedWord.getStart(), CLOCK.getZone()));
windowedWord.setEnd(ZonedDateTime.ofInstant(outputWindowedWord.getEnd(), CLOCK.getZone()));
windowedWord.setStart(ZonedDateTime.ofInstant(outputWindowedWord.getStart(), CLOCK.getZone()));
windowedWord.setEnd(ZonedDateTime.ofInstant(outputWindowedWord.getEnd(), CLOCK.getZone()));
- windowedWord.set
Word(outputWindowedWord.getWord
());
+ windowedWord.set
Key(outputWindowedWord.getKey
());
return windowedWord;
}
return windowedWord;
}
@@
-211,7
+211,7
@@
class TestData
WordCounter counter)
{
OutputWordCounter outputWordCounter = OutputWordCounter.of(
WordCounter counter)
{
OutputWordCounter outputWordCounter = OutputWordCounter.of(
- word.get
Word
(),
+ word.get
Key
(),
counter.getCounter());
assertWordCountEqualsWordCountFromLastMessage(word, outputWordCounter);
}
counter.getCounter());
assertWordCountEqualsWordCountFromLastMessage(word, outputWordCounter);
}
diff --git
a/src/test/java/de/juplo/kafka/wordcount/stats/OutputWindowedWord.java
b/src/test/java/de/juplo/kafka/wordcount/stats/OutputWindowedWord.java
index
1589ea0
..
470f727
100644
(file)
--- a/
src/test/java/de/juplo/kafka/wordcount/stats/OutputWindowedWord.java
+++ b/
src/test/java/de/juplo/kafka/wordcount/stats/OutputWindowedWord.java
@@
-14,5
+14,5
@@
public class OutputWindowedWord
{
Instant start;
Instant end;
{
Instant start;
Instant end;
- String
word
;
+ String
key
;
}
}
diff --git
a/src/test/java/de/juplo/kafka/wordcount/stats/OutputWordCounter.java
b/src/test/java/de/juplo/kafka/wordcount/stats/OutputWordCounter.java
index
f132707
..
ce8a764
100644
(file)
--- a/
src/test/java/de/juplo/kafka/wordcount/stats/OutputWordCounter.java
+++ b/
src/test/java/de/juplo/kafka/wordcount/stats/OutputWordCounter.java
@@
-10,6
+10,6
@@
import lombok.NoArgsConstructor;
@AllArgsConstructor(staticName = "of")
public class OutputWordCounter
{
@AllArgsConstructor(staticName = "of")
public class OutputWordCounter
{
- String
word
;
+ String
key
;
long counter;
}
long counter;
}