You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2021/09/29 21:35:36 UTC

[GitHub] [pinot] richardstartin opened a new issue #7499: Consider migrating joda-time to `java.time`

richardstartin opened a new issue #7499:
URL: https://github.com/apache/pinot/issues/7499


   Joda-time was superseded by `java.time` when JDK8 was released and there is a straightforward migration path.


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] richardstartin closed issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
richardstartin closed issue #7499:
URL: https://github.com/apache/pinot/issues/7499


   


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] ddcprg commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
ddcprg commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-938121717


   Looks like this is going to be a large piece of work. I've opened a draft PR with unit tests for the scalar functions, more to come


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] ddcprg commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
ddcprg commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-947976049


   hey @camac that'd be great!


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] ddcprg commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
ddcprg commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-931050305


   Cool, Thank you for the suggestions!


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] ddcprg commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
ddcprg commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-938121717


   Looks like this is going to be a large piece of work. I've opened a draft PR with unit tests for the scalar functions, more to come


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] camac edited a comment on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
camac edited a comment on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-938438835


   > Looks like this is going to be a large piece of work. I've opened a draft PR with unit tests for the scalar functions, more to come
   
   Hi @ddcprg Happy to help make this migration easier. I am currently working on an IntelliJ plugin called Sensei that provides custom recipes/rules that can help migrate and rewrite code as defined. I have a bunch of rules created for Joda to Java-Time migration and would love to contribute if they would help this process. Would you be interested?


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] camac edited a comment on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
camac edited a comment on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-938438835


   > Looks like this is going to be a large piece of work. I've opened a draft PR with unit tests for the scalar functions, more to come
   
   Hi @ddcprg  would you be interested in some help with this? I am working on an intellij plugin that provides custom recipes (refactorings) that rewrite code. I am currently working on a bunch of recipes for Joda to Java-Time migration and would love to see if they would help this process


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] ddcprg commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
ddcprg commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-952116603


   @camac many thanks, indeed it may be difficult to schedule a time for a live demo. It may be better a blog post / video so everyone else can also look at it if they are interested. Cheers!


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] camac commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
camac commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-948458895


   @ddcprg Excellent! we are hoping to publish these Joda-Time to java.time migration recipes tomorrow. After they are published I can give you a demo on how to use them? I'm in Sydney, Australia so if the time zone doesn't suit I can do a blog post / video demonstrating how to use Sensei and these recipes to perform a large part of the migration.


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] ddcprg commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
ddcprg commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-931026138


   @richardstartin  @xiangfu0 I might be able to look into this one if no one else has picked it up


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] camac commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
camac commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-938438835


   > Looks like this is going to be a large piece of work. I've opened a draft PR with unit tests for the scalar functions, more to come
   
   Hey Daniel would you be interested in some help with this? I am working on an intellij plugin that provides custom recipes (refactorings) that rewrite code. I am currently working on a bunch of recipes for Joda to Java-Time migration and would love to see if they would help this process


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] richardstartin commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
richardstartin commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-931041329


   @ddcprg that would be awesome! As part of the effort, I would suggest building some unit testing around `DateTimeFunctions` to be sure there aren't any regressions. 
   
   There is a blog post from the author of both libraries on performing the migration (from 2014) [here](https://blog.joda.org/2014/11/converting-from-joda-time-to-javatime.html). Don't miss the comment here:
   
   > One more "odds and ends" which is important to be aware of:
   >
   > the Joda DateTimeFormat (http://www.joda.org/joda-time/apidocs/org/joda/time/format/DateTimeFormat.html) uses "Y" for "year of era", and "y" for "year". The Java 8 DateTimeFormatter (https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html) uses "Y" for "week based year", and "y" for "year of era". If you're currently using a Joda DateTimeFormat object with "Y" as part of the pattern, this may introduce an off-by-one error (https://stackoverflow.com/questions/26431882/difference-between-year-of-era-and-week-based-year) if you change it to a Java 8 DateTimeFormatter without also replacing "Y" with "y" in the pattern string.
   


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] camac commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
camac commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-969861144


   > @ddcprg no worries! I'm working on the blog post this week. I'll post here when it's published
   
   For anyone interested here is the aforementioned blog post which gives a bit of an overview of the kinds of Joda-Time to java.time transformations we are covering in our Sensei migration cookbook for Joda-time to java.time
   : https://www.securecodewarrior.com/blog/migrating-joda-time-to-java-time
   
   We have quite a few more recipes to publish over the next month so the cookbook should start to cover more of the Joda-Time classes.
   
   Classes like `org.joda.time.Interval` (which are not included in java.time) will be covered in a separate cookbook for people who are happy to include [Threeten-extra](https://www.threeten.org/threeten-extra/) as a new dependency (in place of Joda-Time)


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [pinot] camac commented on issue #7499: Consider migrating joda-time to `java.time`

Posted by GitBox <gi...@apache.org>.
camac commented on issue #7499:
URL: https://github.com/apache/pinot/issues/7499#issuecomment-953457538


   @ddcprg no worries! I'm working on the blog post this week. I'll post here when it's published


-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org