Stat & Logs

One Star

Stat & Logs

Hello
I've a problem using the project's stats and logs.
I want to save all the log in a database but I can't use my context variable to set the connection.
I've an error message :
Exception in component connectionStatsLogs
org.postgresql.util.PSQLException: La tentative de connexion a échoué. (connection failed)
How can I do to use my context's variable on the Stats and logs ?
Thanks !
Six Stars

Re: Stat & Logs

Try using Implicit context load property along with it.
One Star

Re: Stat & Logs

The value of my contextes variables are set in a file. I think that's the reason why I can't use my contexte variable in the stat / log and in the implicit context ...
Is there a solution for that ? Or I have to set my variable in the context ?
One Star

Re: Stat & Logs

Hi,
I don't know if it helps, but we use --context_param with key/value pairs when running jobs to fill the context for the database connection which is used for stats and logs. Maybe you can use a similar approach.
Good luck,
Arno
Six Stars

Re: Stat & Logs

I had the same problem, solution is:
1. Project settings, Implicit context load - load your context file
2. In file path you can now write: context.path
3. in your job you have to create a new context variable path
Your job is done.
One Star

Re: Stat & Logs

Thanks a lot for your help Smiley Happy
I use the solution of djugal and it works fine Smiley Very Happy