Ivar,
That’s an interesting idea.
> Would it be possible to provide a warning of some kind both at compile time and runtime for Option 2?
At run time, yes. The spec could require implementations to log a warning at run time when seeing the annotation. I think that would be a good idea if going with Option 2.
At compile time, even if there were a way to cause a warning at compile time, it would be wrong to do so because it is a valid scenario to compile your application with Java SE 17 but run it on Java SE 21.
Users should not have to receive a warning for that.
From:
cu-dev <cu-dev-bounces@xxxxxxxxxxx> on behalf of Ivar Grimstad via cu-dev <cu-dev@xxxxxxxxxxx>
Date: Friday, February 2, 2024 at 11:25 AM
To: cu developer discussions <cu-dev@xxxxxxxxxxx>
Cc: Ivar Grimstad <ivar.grimstad@xxxxxxxxxxxxxxxxxxxxxx>
Subject: [EXTERNAL] Re: [cu-dev] Behavior of virtual=true on Java SE 17
On Fri, Feb 2, 2024 at 9: 09 AM Nathan Rauh via cu-dev <cu-dev@ eclipse. org> wrote: If anyone else has an opinion on what the behavior of virtual=true should be
when running on Java SE 17, please comment in https: //github. com/jakartaee/concurrency/pull/415
This Message Is From an External Sender
This message came from outside your organization.
If anyone else has an opinion on what the behavior of virtual=true should be when running on Java SE 17, please comment in
https://github.com/jakartaee/concurrency/pull/415
The options being considered are:
-
It’s an error because Java SE 17 can’t possibly ever honor your request to use virtual threads.
-
Ignore your request for a virtual thread on Java SE 17 and use a platform thread instead.
Would it be possible to provide a warning of some kind both at compile time and runtime for Option 2?
I’ll leave this open for several more days, but I’d like to get a decision made one way or the other so that we can make progress on supporting Java
SE 17 which is now being required by the Jakarta platform.
_______________________________________________
cu-dev mailing list
cu-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/cu-dev
--
Ivar Grimstad
Jakarta EE Developer Advocate |
Eclipse Foundation
Eclipse Foundation - Community. Code.
Collaboration.