Visual Basic

Benchmark-Driven Design

Benchmarking is critical to successful physical design. You should carry it out early using representative models of the system to determine what strategies you should employ for different classes of problems (for example, moving large amounts of data from the front end to the back end or locking). Testing with models should include stress testing in such areas as high transaction rates, multiuser testing, and impacts on other systems. Designing the system incorrectly for these types of problems is expensive once the system has been written. With representative benchmarking carried out early, you should be able to upgrade servers and networks if required. Benchmarking will also give you an early indication of whether the application should be distributed over multiple servers or whether the design can remain simple. Where benchmarks show potential problems, you should evaluate alternative solutions. A set of solutions with varying performance characteristics, costs, and complexities will emerge. This process will enable the designer to select the most appropriate solution from a menu of solutions. These solutions are design patterns.

Benchmark-driven design is essential in Visual Basic 6 distributed applications in which there is a mix of technologies and a large potential for bottlenecks. The aim is to ensure that the technical infrastructure and the approach to using the infrastructure in the application will meet business needs for performance and reliability. To do this, you'll need to develop a model of the system. The performance characteristics and options for Visual Basic 6 (and Visual Basic 5) are very different from Visual Basic 3 or Visual Basic 4. On the whole, versions 5 and 6 have great improvements-improvements that provide opportunities.

Understanding Objects

Visual Basic has gradually become more and more object oriented, and Visual Basic 6 has continued this trend. Whether Visual Basic 6 is fully object-oriented according to some academic's definition is irrelevant. However, it is vital to recognize that the only way to build successful systems using Visual Basic 6 is to develop them from an object-oriented design. An object-oriented design can be developed successfully only from an object-oriented analysis. Object-oriented analysis revolves around the identification of business objects. Identifying business objects responsible for data and function eliminates duplication of data and function.

Using business objects allows you to design incrementally. It also forms a basis for reuse. Using business objects in analysis and design provides traceability and allows the specification to evolve seamlessly by the addition of implementation detail rather than by going through translations from one form of model to another.

Business objects encapsulate data and function and form a natural basis for identifying business-oriented components. Analysis approaches that separate function and data make it more difficult to build a comprehensive component architecture. You will want to package the classes that are developed into larger components-ActiveX servers. These can be considered large objects. The message is that if you are to adopt Visual Basic 6 successfully, you must adopt object orientation.

Business objects are inherently traceable to business concepts and requirements. Implementing business objects through Visual Basic 6 class modules carries through this traceability into applications. Using a business-object-based application architecture allows the design and coding of objects to be carried out independently of the design and coding of the application. This allows a large amount of flexibility in developing project plans and is the basis of high levels of reuse.