...actually got transformed

51 views
Skip to first unread message

Markus Karg

unread,
Apr 21, 2021, 9:07:13 AM4/21/21
to Payara Forum
What does Payara 5.2021.2 like to tell me with the lots of INFO-messages saying "...actually got transformed"? As it is an INFO (not DEBUG) message, I assume Payara really wants me to read that. So what to do with that information now...?

AleksNo

unread,
Apr 21, 2021, 1:03:35 PM4/21/21
to Payara Forum
Hi, this INFO comes from Eclipselink. At deploy time Eclipselink modifies the entities and adds additional bytecode into them for things like lazy loading or dirty checking. Here is more info:

Cheers

Markus Karg

unread,
Apr 22, 2021, 2:23:49 AM4/22/21
to Payara Forum
Payara Team, can you confirm that this message is actually produced by EclipseLink?

Rudy De Busscher

unread,
Apr 22, 2021, 11:14:01 AM4/22/21
to Payara Forum
Hi Markus,


Best Regards
Rudy

Markus Karg

unread,
Apr 23, 2021, 2:18:11 AM4/23/21
to Payara Forum
Rudy, thanks for picking this up. The log contains lots of these lines:
```
[2021-04-22T16:40:31.610+0200] [Payara 5.2021.2] [INFORMATION] [NCLS-COMUTIL-00017] [javax.enterprise.system.util] [tid: _ThreadID=24 _ThreadName=RunLevelControllerThread-1619102403132] [timeMillis: 1619102431610] [levelValue: 800] [[
  mypackage.MyEntityBean actually got transformed]]
```
For me, these information is rather useless, so I would say, they should by posted with debug-level, not INFORMATION-level.

Rudy De Busscher

unread,
Apr 26, 2021, 4:20:35 AM4/26/21
to Payara Forum
Hi Markus,

I looked deeper in the reason and history of this message in the log.

It was put at info level when that part of the code was still under control of Oracle due to the Glassfish logging policy. And I agree that repeating the message for each JPA entity can be overkill but it informs the user of an important fact. It indicates that the class, JPA entity in this case, was transformed at runtime which is not recommended for performance reasons.  EclipseLink perform ByteCode weaving to implement the JPA functionalities but this should not be done at runtime, but at compile time.


Payara 5.2021.2 uses EclipseLink 2.7.7.

Best Regards
Rudy

Hans Pikkemaat

unread,
Apr 27, 2021, 5:32:11 AM4/27/21
to Payara Forum
Hi Rudy,

You stated that weaving should not be done at runtime but at compile time.
I can imagine the reason is about performance. 
But weaving is only done during startup as far I know. 
So it will speed up startup but after that the performance is identical right?
Or are there other reasons why dynamic weaving is a bad idea?

best regards,

Hans

-- 
You received this message because you are subscribed to the Google Groups "Payara Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to payara-forum...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/payara-forum/354c1b65-02b5-4955-911c-6edd904c3caan%40googlegroups.com.

AleksNo

unread,
Apr 27, 2021, 6:35:24 AM4/27/21
to Payara Forum
Hi, i have found two articles about static and dynamic bytecode enhancements and performance:



Static enhancement has three major advantages:

1. Faster deployment.
2. You do not need a javaagent. Javaagents are a special thing and can be very ugly when your application uses own classloaders.
3. Your unit tests can use the already woven entities ootb without additional configuration.

Cheers

Hans Pikkemaat

unread,
Apr 27, 2021, 6:43:50 AM4/27/21
to Payara Forum
Hi,

Thanks for the links, I’ll read them through.

About the agent, I’m using ‘plain’ payara and JPA where the dynamic weaving is active.
I’m not aware of any java agent being used, or is that part of payara?

best regards, Hans

Ondro Mihályi

unread,
Apr 28, 2021, 11:41:58 AM4/28/21
to Hans Pikkemaat, Payara Forum
Hi, 

I didn’t read the articles yet but I think that java agent is only needed in a plain Java SE application, e. g. in unit tests if the tests are not run inside Payara Server. In Payara Server, the entities are weaved automatically, no java agent is involved. 

In Payara server, static weaving means your application is deployed faster. After the deployment there's no difference in behavior or performance. 

Ondro

Dňa ut 27. 4. 2021, 12:43 Hans Pikkemaat <the...@gmail.com> napísal(a):
Reply all
Reply to author
Forward
0 new messages