2

Note: this is not a duplicate of Comparing ThreeTen backport to JSR-310. My question is more specific.

In my company, I'm trying to get DevOps to O.K. the use of ThreeTen-Backport for refactoring legacy code (which because of deployment constraints with WebLogic 10.3.6.0 we can't upgrade from Java 6 and can't use any version of JodaTime beyond version 1.2.1).

I can see DevOps having an issue with this statement on ThreeTen-Backport's Github page:

The backport is NOT an implementation of JSR-310, as that would require jumping through lots of unnecessary hoops. Instead, this is a simple backport intended to allow users to quickly use the JSR-310 API on Java SE 6 and 7.

When they ask me what "Not an implementation" means, I need to be able to explain it to them. However, the word implementation can have a wide semantic range, and I'm not sure exactly what is meant by that myself.

So my question is, in contexts like this, what is meant by implementation vs. backport? Since JSR-310 is a backport and not an implementation, is there a counter example of something that I could use, that is an implementation of something else, in the same sense that ThreeTen-Backport is not an implementation of JSR-310? What would an actual implementation of JSR-310 for Java 6 look like if such a thing existed, and how would it be different from ThreeTen-Backport?

Community
  • 1
  • 1
James Dunn
  • 8,064
  • 13
  • 53
  • 87

1 Answers1

4

JSR 310: Date and Time API is a formal specification controlled by the Java Community Process (JCP) and with a whole heap of legalistic controls. An implementation of any JSR, including JSR-310, requires passing the testing kit and other hurdles.

In the case of JSR-310, the JSR is integrated into Java 8 itself, which means that it simply is not possible to implement the JSR independently. There is no testing kit for JSR-310 outside the JDK. Thus no piece of code can implement JSR-310 outside the JDK itself.

Thus, ThreeTen-Backport is as close to an implementation of the JSR-310 specification without actually being an implementation, where "implementation" is with reference to the JSR-310 specification.

Basil Bourque
  • 303,325
  • 100
  • 852
  • 1,154
JodaStephen
  • 60,927
  • 15
  • 95
  • 117