How to enable logging in replay while using Workflow Loggers in Temporal?

Hi Team,

I am using Temporal Workflow Loggers in java sdk. How to enable the logging in replay?
I am unable to find the configuration to activate it.

Use WorkerFactoryOptions.enableLoggingInReplay property.

    WorkflowServiceStubs service = WorkflowServiceStubs.newInstance(stubOptions);
    WorkflowClient client = WorkflowClient.newInstance(service, clientOptions);
    WorkerFactoryOptions factoryOptions =
    WorkerFactory factory = WorkerFactory.newInstance(client, factoryOptions);

Thank you!