mjsax commented on code in PR #21600:
URL: https://github.com/apache/kafka/pull/21600#discussion_r2887583359


##########
streams/src/main/java/org/apache/kafka/streams/kstream/internals/SessionStoreMaterializer.java:
##########
@@ -58,18 +59,20 @@ public SessionStoreMaterializer(
 
     @Override
     public StoreBuilder<?> builder() {
+        final DslStoreFormat storeFormat = dslStoreFormat() == null ? 
DslStoreFormat.PLAIN : DslStoreFormat.HEADERS;
         final SessionBytesStoreSupplier supplier = 
materialized.storeSupplier() == null
                 ? dslStoreSuppliers().sessionStore(new DslSessionParams(
                         materialized.storeName(),
                         Duration.ofMillis(retentionPeriod),
-                        emitStrategy))
+                        emitStrategy,
+                        storeFormat))
                 : (SessionBytesStoreSupplier) materialized.storeSupplier();
 
-        final StoreBuilder<SessionStore<K, V>> builder = 
Stores.sessionStoreBuilder(
-                supplier,
-                materialized.keySerde(),
-                materialized.valueSerde()
-        );
+        final StoreBuilder<?> builder = Stores.sessionStoreBuilderWithHeaders(

Review Comment:
   I think we should use `StoreBuilder<SessionStoreWithHeaders>` -- we should 
express what type we expect to get, and we don't expect "any" `SessionStore`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to