To use the HTTP Monitor to assist with debugging a web module, perform the following configuration steps.
![]() |
If you are using a server that is managed by a plugin that is bundled with the IDE, you do not need to perform these steps. However, you should ensure that the HTTP Monitor is enabled for the server by right-clicking the server from the Runtime window and choosing Properties from the contextual menu. The Enable HTTP Monitor checkbox in the property sheet must be selected. |
To use the HTTP Monitor:
<filter> <filter-name>HTTPMonitorFilter</filter-name> <filter-class>org.netbeans.modules.web.monitor.server.MonitorFilter</filter-class> <init-param> <param-name>netbeans.monitor.ide</param-name> <param-value>name-of-host-that-runs-IDE:port-of-internal-HTTP-server </param-value> </init-param> </filter> <filter-mapping> <filter-name>HTTPMonitorFilter</filter-name> <url-pattern>/*</url-pattern> <dispatcher>REQUEST</dispatcher> <dispatcher>FORWARD</dispatcher> <dispatcher>INCLUDE</dispatcher> <dispatcher>ERROR</dispatcher> </filter-mapping>
<filter> <filter-name>HTTPMonitorFilter</filter-name> <filter-class>org.netbeans.modules.web.monitor.server.MonitorFilter</filter-class> <init-param> <param-name>netbeans.monitor.ide</param-name> <param-value>name-of-host-that-runs-IDE:port-of-internal-HTTP-server </param-value> </init-param> </filter> <filter-mapping> <filter-name>HTTPMonitorFilter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping>
Your web module is now ready to use the HTTP Monitor for development and debugging purposes.
![]() |
You can have more than one IDE monitoring the data
records from a web module by adding a second init-param entry as
follows:
<init-param> <param-name>netbeans.monitor.register</param-name> <param-value> other-IDE-host:other-HTTP-server-port, another-IDE-host:another-HTTP-server-port</param-value> </init-param> |
![]() |
When you deploy the web module to a production server, remember to remove the jar files from your WEB-INF/lib directory and remove the filter and filter mapping declarations from the web module's deployment descriptor. |
See Also | |
---|---|
Viewing HTTP Monitor Data Records Saving HTTP Monitor Data Records Deleting HTTP Monitor Data Records Editing and Replaying Requests |