tjwatson commented on PR #433:
URL: https://github.com/apache/felix-dev/pull/433#issuecomment-3357572321

   > But this will only work if the API is not gone (or non existent) if you 
not choose reflection ... what is a nightmare on its own of course.
   
   This is all theoretical since `SecurityManager` is still there.  I would 
never recommend going to MRJs if the class is still there.
   
   I also would never recommend using a compiler that doesn't understand the 
release you are targeting where the class still exists that your code wants to 
use on old Java versions.  Even if/when they really remove the class the 
`--release` option must continue to know about the removed class for the java 
version you are targeting and must allow your code to compile against it.  If 
no compiler exists that can do the `--release` option to the java version you 
are targeting then it is really finally time you move onto a new Java version.
   
   Since Oracle just [extended their Java 8 
support](https://www.oracle.com/java/technologies/java-se-support-roadmap.html) 
way out to 2030 (and other vendors will follow) I don't see that happening any 
earlier for the new Java versions being released through 2030.  I suspect they 
will continue to support `--release 8` for a long time yet.
   
   > The source jar?!? Do you mean the final build jar or the source code in 
the project?
   
   I mean the source jar, typically published to maven central.  As in 
[org.eclipse.osgi-3.23.200-sources.jar](https://repo1.maven.org/maven2/org/eclipse/platform/org.eclipse.osgi/3.23.200/org.eclipse.osgi-3.23.200-sources.jar)
   
   Even if that all works out and all IDEs handle it in a useful way. I often 
am handed an error log and asked to analyze some stack trace with methods and 
line numbers.  At that point it is nice to just know the version I am dealing 
with to find the code for the class/method/line-number in the stack trace 
without having to worry about which "version" of the class within the MRJ got 
loaded.
   
   I am doubtful anyone can convince me that MRJs are a perfect solution for me.


-- 
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