See if the following helps:
Open up the Software Updater, and click on the STOP button.
then go to avast's Settings (in the upper right-hand corner), select Software Updater (on the left),
UNcheck the box to "Automatically download updates if possible".
Click on the down-arrow to expand the "database reset (troubleshooting)" section, and press the RESET DATABASE NOW button. Accept any prompts it offers, and click OK to close the settings screen.
You should be back at the Software Updater (if not, go there). Hit START, and then RESCAN.
Hopefully, it will no longer be continually "preparing" Java (nor anything else).
*** Nor will it automatically download updates in the background without getting your permission. ***