Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

User macro stopped working because of missing context keys

Houssein Barkallah
Contributor
February 8, 2024

Hello fellow people.

We have a Confluence DC, to which we have added several "User Macros". 
One of which is pretty old yet very useful to us in formatting pages.

The macro stopped working and it only displays this message: 

User Macro "MACRO NAME" may use context keys [ action, permissionHelper, pageManager ] which are not set in system property macro.required.velocity.context.keys. If the macro is not rendered as expected, try to manually add those keys into the system property.

How is it possible to add the missing context keys? Thanks.

1 answer

1 accepted

1 vote
Answer accepted
Pavel Junek
Community Champion
February 8, 2024

Hi Houssein,

You can see this Confluence Bug - CONFSERVER-82741 (Variables in user macro are not resolved) 

Here is described workaround:

Workaround

Please review the User Macro administration interface and the documentation at Confluence objects accessible from Velocity to determine what modules should be allow listed.

Modules can be added using the system property below

-Dmacro.required.velocity.context.keys=comma,seperated,key,values

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
8.5.5
TAGS
AUG Leaders

Atlassian Community Events