To continue with this content, please log in with your Data Access ID or create a new account.
Cancel Data Access ID
You may not be authorized to see this content. Please contact Data Access Europe for more information.
Cancel Data Access Europe
You are not authorized to see this content.
Cancel Data Access Europe
Next lesson:
Using Get and Set instead of WebGet and WebSet
Cancel

5 Common WebApp Mistakes

Lesson 2: Not testing outside of the debugger

The next mistake is one every DataFlex developer has encountered at least once when building a WebApp. It’s not testing your application outside of the debugger. The problem here has to do with a nifty little thing we call “Process Pooling”. The WebApp Server is stateless – meaning that every call is handled as a standalone, it has no recollection of any previous calls from the client. This means that you cannot rely on the WebApp Server to have the correct values ready from one call to the next and you have to build your application logic keeping this in mind.

When testing inside of the debugger, there is only 1 single process handling every call. This means that when testing in the debugger, process pooling is not an issue as it’s the same process handling every call from the client. In a test or production environment, you will most likely have multiple processes in a pool and this is where the problems start. Because you will randomly get a different process handling each call, you might see all manner of strange things occur. Examples are showing the wrong data, permissions being applied incorrectly, validation failing or succeeding where it shouldn’t, etcetera.

We have an entire course about Process Pooling specifically that goes through all the intricacies. For now, keep in mind that when testing your application to make sure to also do this outside of the debugger.