Usages


This is a new feature in Joget DX 8.2.

A plugin that acts as a web filter, and intercepts the HTTP request, while doing some pre-processing & post-processing to the response.

Common use cases:

Interface Class

org.joget.plugin.base.PluginWebFilter

Method Detail

Interface Methods
getName
public java.lang.String getName

Method returning the name of the filter.

getUrlPatterns


public java.lang.String[] getUrlPatterns()
isPositionAfterSecurityFilter
public boolean isPositionAfterSecurityFilter()

A flag to make the filter execute after the security chain. If after that, you can get the logged-in user.

getOrder
public int getOrder()

The order of plugin web filter execution.

doFilter
public void doFilter(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response, javax.servlet.FilterChain chain)

The filter logic implementation.

Abstract Class

org.joget.apps.app.model.PluginWebFilterAbstract

Method Detail

Abstract Methods
afterRegister
public void afterRegister()

Auto calling PluginWebFilterUtil.registerFilter to register the filter when installed.

beforeUnregister
public void beforeUnregister()

Auto calling PluginWebFilterUtil.unregisterFilter to unregister the filter when uninstalling.

isPositionAfterSecurityFilter
public boolean isPositionAfterSecurityFilter()

Default to return true.

getOrder
public int getOrder()

Default to return 0.

Sample Plugins