From my perspective this is a cycle dependency.
I would have all classes in the module.
Add a dependecy from a module to a deployed archiv looks not possible to me.
Module can be added as dependencies and made visible to a deployment not the other way around
But. I understand what you are trying to do, I can think of an alternate ways to achieve it
separate the java component out of your deployment, package it as a jar and add it as a dependency to both the deployment and the module