Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace joda-time with JSR 310 in Jenkins plugins #32

Open
basil opened this issue Aug 18, 2023 · 3 comments
Open

Replace joda-time with JSR 310 in Jenkins plugins #32

basil opened this issue Aug 18, 2023 · 3 comments
Labels
good first issue Good for newcomers recipe Requests for new automated code changes

Comments

@basil
Copy link
Contributor

basil commented Aug 18, 2023

Java 7 and prior had time libraries that were inadequate. The joda-time library was created to provide better ways of handling time. The joda-time library was used as the design basis for the JSR 310 time libraries. Use of joda-time should be replaced by calls to the JSR 310 time classes and methods. To identify sources with the issue, do a search in all project files for the pattern org.joda.time. See Stephen Colebourne’s 2014 blog post that describes the transition process from joda-time to JSR 310.

@timtebeek timtebeek added the recipe Requests for new automated code changes label Aug 18, 2023
@timtebeek timtebeek moved this to Recipes Wanted in OpenRewrite Aug 18, 2023
@timtebeek
Copy link
Contributor

We're working on making such recipes available over in

You might want to follow that issue before any work is started here; We have a friend looking to make her recipes available, once those get cleared to open source.

@timtebeek timtebeek changed the title Replace joda-time with JSR 310 Replace joda-time with JSR 310 in Jenkins plugins Oct 5, 2024
@timtebeek timtebeek added the good first issue Good for newcomers label Oct 5, 2024
@timtebeek
Copy link
Contributor

A first batch of recipes has since been merged in:

I've renamed this issue to reflect replacement in Jenkins plugins; this is likely best handled by referencing the new recipes from

type: specs.openrewrite.org/v1beta/recipe
name: org.openrewrite.jenkins.ModernizePlugin
displayName: Modernize a Jenkins plugin to the latest recommended versions
description: >-
This recipe is intended to change over time to reflect the most recent tooling and
[recommended Jenkins baseline](https://www.jenkins.io/doc/developer/plugin-development/choosing-jenkins-baseline/).
recipeList:

@timtebeek
Copy link
Contributor

And the last PR has made it in, such that this work can now leverage those recipes when you depend on rewrite-migrate-java:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers recipe Requests for new automated code changes
Projects
Status: Recipes Wanted
Development

No branches or pull requests

2 participants