I have a gemfire function which is ment to be deployed in a gemfire cluster. What is the way to write log from function, so that it goes to server log file.
My gemfire version is 8.2.0
I have a gemfire function which is ment to be deployed in a gemfire cluster. What is the way to write log from function, so that it goes to server log file.
My gemfire version is 8.2.0
You should use either the LogService.getLogger(String)
or LogService.getLogger()
method to get a Logger
instance. The latter is a convenience method and sets the name of the returned Logger
to the name of the calling class. The Logger
returned by these methods is a log4j
Logger
.
I actually figured it out. From Gemfire 8.1.0 the log library they use has changed and it now uses Apache Log4j2. Logs done through this logger goes to the server log file.