Introduction to CSP

The CSP introduction contains the examples for the online Barracuda introduction whitepaper. We suggest that you first read the online whitepaper and try the online examples. You can then compile and run this example, but you must first configure the Barracuda Platform, if not configured by the installation program.

After configuring and building the example, start the generated demo executable. The shared examples/misc/OpenSocketCon.h helper reports the selected HTTP port through HttpTrace when tracing is enabled. Open http://127.0.0.1:PORT/ on the same computer, using that port. An unmodified debug build starts with port 9357. Other builds first try the configured HTTP_PORT, or port 80 if it is not defined. If the first attempt fails, the helper tries ports 9357 through 9369. Test the supplied pages in the browser before adapting them.

Terminate the demo program and start the demo program again in your debugger after you have become familiar with the examples. Set a breakpoint inside one of the CSP resources. Use your browser to navigate to the resource and step through the CSP code. Please note that for VC++ users, VC++ 6.0 does not allow you to step through the CSP code -- you must upgrade to the VC++ .NET IDE.

You should now try to change and experiment with the CSP code. You can do this directly from within an IDE environment. Change one of the CSP resources, rebuild, and run the CSP code from your debugger.

We suggest that you try the HttpResMgr example after you have familiarized yourself with the CSP code in this example. The HttpResMgr example gives you a broader understanding of the Barracuda Virtual File System.