Runtime Configuration of Servlet Filtering Using Dynamic Injection
AssigneeBrocade Communications Systems, Inc.
InventorRyan Goulding
Life of this patent
Estimating the term…
Abstract
Embodiments according to the present invention introduce a high-level abstraction for specifying and operating dynamic filtering at runtime without service interruption. A CustomFilterAdapter implementation of the javax.servlet.Filter interface is added to the target servlet's configuration. A configuration file and/or data structure are used to establish a chain of responsibility pattern and options for existing and for newly added or removed filters. When the chain of responsibility pattern changes, the filters are started and the CustomFilterAdapter reloads the chain of responsibility. When an HTTP request is received, CustomFilterAdapter processes the filters in the chain of responsibility in the chain order.
Claims20
A method comprising:
- executing a Java virtual machine (JVM);
- executing an Open Service Gateway Initiative (OSGi) environment in the JVM;
- executing a Java-based application in the OSGi environment, the Java-based application receiving Hypertext Transfer Protocol (HTTP) requests;
- providing and executing a filter servlet in conjunction with the Java-based application, the filter servlet receiving the HTTP requests prior to the Java-based application and executing to perform filter operations on the HTTP request based on a chain of responsibility;
- and
- providing and executing at least one filter for execution by the filter servlet, the at least one filter executing when the filter servlet is performing a filter operation,
- wherein at least one filter is dynamically inserted into the chain of responsibility of the filter servlet.
A non-transitory computer readable medium or media having computer-executable instructions stored thereon for operating a computer system to perform a method comprising:
- executing a filter servlet in conjunction with a Java-based application, the filter servlet receiving Hypertext Transfer Protocol (HTTP) requests prior to being provided to the Java-based application and performing filter operations on the HTTP request based on a chain of responsibility;
- and
- executing at least one filter for execution by the filter servlet when the filter servlet is performing a filter operation,
- wherein at least one filter is dynamically inserted into the chain of responsibility of the filter servlet.
A computer system comprising:
- a processor;
- a network interface coupled to the processor;
- and
- a non-transitory computer readable medium storing computer-executable instructions for operating a computer system to perform a method including:
- executing a filter servlet in conjunction with a Java-based application, the filter servlet receiving Hypertext Transfer Protocol (HTTP) requests prior to being provided to a Java-based application and performing filter operations on the HTTP request based on a chain of responsibility;
- and
- executing at least one filter for execution by the filter servlet when the filter servlet is performing a filter operation,
- wherein at least one filter is dynamically inserted into the chain of responsibility of the filter servlet.
Dependencies are inferred from the claim text.