# Unreal Engine 4.27.2 Could not initialize class org.codehaus.groovy.reflection.ReflectionCache

**URL:** <https://forums.unrealengine.com/t/unreal-engine-4-27-2-could-not-initialize-class-org-codehaus-groovy-reflection-reflectioncache/507161>\
**Category:** Mobile\
**Tags:** unreal-engine, Android, UE4, UE4-27, question\
**Created:** [March 15, 2022, 10:44pm UTC](https://forums.unrealengine.com/t/unreal-engine-4-27-2-could-not-initialize-class-org-codehaus-groovy-reflection-reflectioncache/507161 "2022-03-15T22:44:12Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Leboulier23](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Leboulier23](https://forums.unrealengine.com/u/Leboulier23)\
**Post date:** [March 15, 2022, 10:44pm UTC](https://forums.unrealengine.com/t/unreal-engine-4-27-2-could-not-initialize-class-org-codehaus-groovy-reflection-reflectioncache/507161/1 "2022-03-15T22:44:12Z")

</div>

Hi,

This similar error was resolved on a previous topic, but the Engine version was an older one.  
I’ve been stuck on it the last 2 days.

this is the error :

Could not initialize class org.codehaus.groovy.reflection.ReflectionCache

---

<div class="post-metadata">

**Author:** ![dev.ue.games](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/dev.ue.games/32/466816_2.png) [@dev.ue.games](https://forums.unrealengine.com/u/dev.ue.games)\
**Post date:** [March 26, 2022, 8:10pm UTC](https://forums.unrealengine.com/t/unreal-engine-4-27-2-could-not-initialize-class-org-codehaus-groovy-reflection-reflectioncache/507161/2 "2022-03-26T20:10:52Z")

</div>

show me please error log

---

<div class="post-metadata">

**Author:** ![999999333](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@999999333](https://forums.unrealengine.com/u/999999333)\
**Post date:** [April 7, 2022, 12:07am UTC](https://forums.unrealengine.com/t/unreal-engine-4-27-2-could-not-initialize-class-org-codehaus-groovy-reflection-reflectioncache/507161/3 "2022-04-07T00:07:18Z")

</div>

Solution is still same… install JDK v8 (its already on oracle archive downloads site) Url [Java Archive Downloads - Java SE 8](https://www.oracle.com/java/technologies/javase/javase8-archive-downloads.html)

---

<div class="post-metadata">

**Author:** ![BBRTY](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@BBRTY](https://forums.unrealengine.com/u/BBRTY)\
**Post date:** [December 13, 2022, 10:35am UTC](https://forums.unrealengine.com/t/unreal-engine-4-27-2-could-not-initialize-class-org-codehaus-groovy-reflection-reflectioncache/507161/4 "2022-12-13T10:35:01Z")

</div>

Still doesn’t work for me unfortunatley!

---

<div class="post-metadata">

**Author:** ![TriAngles](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TriAngles](https://forums.unrealengine.com/u/TriAngles)\
**Post date:** [February 1, 2023, 12:03am UTC](https://forums.unrealengine.com/t/unreal-engine-4-27-2-could-not-initialize-class-org-codehaus-groovy-reflection-reflectioncache/507161/5 "2023-02-01T00:03:05Z")

</div>

You are so kind \<3 … Helped me much … now it works

---

<div class="post-metadata">

**Author:** ![TriAngles](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TriAngles](https://forums.unrealengine.com/u/TriAngles)\
**Post date:** [February 1, 2023, 12:03am UTC](https://forums.unrealengine.com/t/unreal-engine-4-27-2-could-not-initialize-class-org-codehaus-groovy-reflection-reflectioncache/507161/6 "2023-02-01T00:03:32Z")

</div>

You need to update the jdk path in your project settings

---

<div class="post-metadata">

**Author:** ![Mind-Brain](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/mind-brain/32/906573_2.png) [@Mind-Brain](https://forums.unrealengine.com/u/Mind-Brain)\
**Post date:** [February 1, 2023, 12:05am UTC](https://forums.unrealengine.com/t/unreal-engine-4-27-2-could-not-initialize-class-org-codehaus-groovy-reflection-reflectioncache/507161/7 "2023-02-01T00:05:29Z")

</div>

Hey @Leboulier23, I don’t know if anyone welcomed you to the forums yet, but welcome!

Did @999999333’s solution work for you?

---

<div class="post-metadata">

**Author:** ![ericwa](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ericwa](https://forums.unrealengine.com/u/ericwa)\
**Post date:** [April 18, 2023, 5:17pm UTC](https://forums.unrealengine.com/t/unreal-engine-4-27-2-could-not-initialize-class-org-codehaus-groovy-reflection-reflectioncache/507161/8 "2023-04-18T17:17:29Z")

</div>

I had success with Corretto 8 (no login required, unlike the Oracle JDK):

[https://corretto.aws/downloads/resources/8.362.08.1/amazon-corretto-8.362.08.1-windows-x64-jdk.msi](https://corretto.aws/downloads/resources/8.362.08.1/amazon-corretto-8.362.08.1-windows-x64-jdk.msi)

From: [Releases · corretto/corretto-8 · GitHub](https://github.com/corretto/corretto-8/releases)

I opted to install it in `D:/ue4/AmazonCorretto8`, unselected the option for modifying `JAVA_HOME` and `PATH` environment variables (to reduce potential breakage/conflicts later), and set in my UE4 project settings → Android SDK → Location of JAVA: `D:/ue4/AmazonCorretto8/jdk1.8.0_362`
