# Wrapper file stopped logging during benchmarking? when in general it will stop?

**URL:** <https://forum.inductiveautomation.com/t/wrapper-file-stopped-logging-during-benchmarking-when-in-general-it-will-stop/75982>\
**Category:** Ignition\
**Tags:** ignition81\
**Created:** [July 6, 2023, 9:52am UTC](https://forum.inductiveautomation.com/t/wrapper-file-stopped-logging-during-benchmarking-when-in-general-it-will-stop/75982 "2023-07-06T09:52:21Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![hewking32](https://avatars.discourse-cdn.com/v4/letter/h/b5ac83/32.png) [@hewking32](https://forum.inductiveautomation.com/u/hewking32)\
**Post date:** [July 6, 2023, 9:52am UTC](https://forum.inductiveautomation.com/t/wrapper-file-stopped-logging-during-benchmarking-when-in-general-it-will-stop/75982/1 "2023-07-06T09:52:21Z")

</div>

Hi  
I just noticed that wrapper file stopped logging (i checked its size was 0) so i went to system logs and got a hint that my benchmarking code probably caused an issue so i removed it and wrapper is happy again.  
1 Do you know when in general wrapper file will stop logging? are system logs the only way to get a clue to debug?  
2 I am checking potentially long running scripts triggered cyclically from the gateway using code below - can you see any reason it could cause the issue? I remember nano time is a lot more consistent and @pturmel mentioned in the past.

> from java.lang import System
> 
> start = System.nanotime()
> 
> # your code
> 
> end = System.nanotime()  
> print 'Took {} nanosecodes'.format(end-start)

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [July 6, 2023, 11:31am UTC](https://forum.inductiveautomation.com/t/wrapper-file-stopped-logging-during-benchmarking-when-in-general-it-will-stop/75982/2 "2023-07-06T11:31:46Z")

</div>

Don't use print. Use a logger instance with `.debugf(...)` and set the DEBUG level when you need it.

The wrapper will rotate to new log files if configured to do so, based on time or size. I recommend the latter. Ensure there's enough room for that size times the number to keep.

---

<div class="post-metadata">

**Author:** ![hewking32](https://avatars.discourse-cdn.com/v4/letter/h/b5ac83/32.png) [@hewking32](https://forum.inductiveautomation.com/u/hewking32)\
**Post date:** [July 6, 2023, 2:23pm UTC](https://forum.inductiveautomation.com/t/wrapper-file-stopped-logging-during-benchmarking-when-in-general-it-will-stop/75982/3 "2023-07-06T14:23:17Z")

</div>

> [@hewking32](#):
>
> System.nanotime()

loggers work beautifully - is there space limit somewhere in the config how big internal database can grow?  
can you please advise where to find reference information on System.nanotime() - i noticed i had to correct it to System.nanoTime() - is it part of SDK documentation?

---

<div class="post-metadata">

**Author:** ![hewking32](https://avatars.discourse-cdn.com/v4/letter/h/b5ac83/32.png) [@hewking32](https://forum.inductiveautomation.com/u/hewking32)\
**Post date:** [July 6, 2023, 2:35pm UTC](https://forum.inductiveautomation.com/t/wrapper-file-stopped-logging-during-benchmarking-when-in-general-it-will-stop/75982/4 "2023-07-06T14:35:02Z")

</div>

i also noticed that when the function runs as gateway cyclic event it takes about 100ms (bad database code) but when i run the same function from script console it takes about 300ms - any idea why is that so different and how the code executes diferently?

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [July 6, 2023, 3:10pm UTC](https://forum.inductiveautomation.com/t/wrapper-file-stopped-logging-during-benchmarking-when-in-general-it-will-stop/75982/5 "2023-07-06T15:10:54Z")

</div>

> [@hewking32](#):
>
> System.nanoTime() - is it part of SDK documentation?

It is part of [java itself](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/System.html).

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [July 6, 2023, 3:12pm UTC](https://forum.inductiveautomation.com/t/wrapper-file-stopped-logging-during-benchmarking-when-in-general-it-will-stop/75982/6 "2023-07-06T15:12:39Z")

</div>

> [@hewking32](#):
>
> any idea why is that so different and how the code executes diferently?

When you run from the script console, there is extra traffic: designer=\>gateway, gateway=\>DB, DB=\>gateway, gateway=\>designer. The latter two carry the result set. If it is big, encoding and compressing will be significant.
