gharris1727 commented on code in PR #15469:
URL: https://github.com/apache/kafka/pull/15469#discussion_r1591636980


##########
connect/api/src/main/java/org/apache/kafka/connect/data/Values.java:
##########
@@ -766,135 +852,23 @@ protected static boolean 
canParseSingleTokenLiteral(Parser parser, boolean embed
     protected static SchemaAndValue parse(Parser parser, boolean embedded) 
throws NoSuchElementException {

Review Comment:
   Parser was protected, so I think it's still safe to refactor. The class 
doesn't show up here: 
https://javadoc.io/doc/org.apache.kafka/connect-api/latest/index.html
   
   I moved the existing Parser to Tokenizer, as it had a good interface 
already, and adding methods would just be clutter. The methods which took a 
Parser argument have now been moved to a single toplevel class named Parser. 
Both of these classes are package-local, so shouldn't appear in the API docs.
   
   I left almost all of the private/protected static methods in Values, just 
bringing a few over that were only ever called by the Parser. I tried moving 
things from Values to Parser to break the circular dependency, but this 
required moving nearly everything to Parser. The two classes are really 
intertwined, and i'm not really satisfied with this refactor now.



-- 
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: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to