Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Anybody out there interested in talking about MS multitier dev issues? 7

Status
Not open for further replies.

johnk

MIS
Jun 3, 1999
217
US
I have a small group (6 of us) of business software developers. Since VB4 we have done nothing but OOP & DCOM. There does not seem to be a large number of folks doing this, yet it may well be the most important technology (along with CORBA) to come along in a while. Now that Microsoft has published its certification specs for Win2000 Distributed Applications it is clear that COM+ is the MS way of the future.<br>
<br>
We have learned much about DCOM, OOP & multitier - most of it the hard way. I'd love to find some more of you to exchange info and experience with.<br>
<br>
John K
 
I'm trying to start learning about COM and VB6 (the hard way), so if you want to talk about this I have many questions...<br>
<br>
- What tools do you use to work with COM?<br>
- What type of applications have you developed this way?<br>
- What is the methodology that you have developed? For example what type of elements do you put in each tier?<br>
<br>
I hope not to be too general.<br>
<br>
TIA
 
A class or tutorial or at least a good book is necessary to get started. Unlike anything else in my 40 years of programming, OOP requires a fresh start.<br>
<br>
We do everything with VB6 and ADO. We build our Client Interface with VB as well as our Business Services (2nd tier). You must program in classes in the 2nd tier. The top tier (UI) instantiates objects in the 2nd tier through COM, or DCOM if on another machine.<br>
<br>
Our 3rd tier is our Data Access tier. It is used by our 2nd tier through COM or DCOM. It contains our ADO code. It is a common executable used by all 2nd tier modules.<br>
<br>
Our 4th tier contains the database.<br>
<br>
So the 1st tier contains all of the VB forms and whatever validation can be done without reference to the database (only numerics in number fields, etc.). The 2nd tier contains all of the business application logic including all communication with the 3rd tier for database reads and updates. Our application programmers write 1st and 2nd tier programs using the normal VB6 Development Environment. Much of our code is inserted through custom IDE Add-Ins we developed (code generators).<br>
<br>
Our 3rd tier was written by a senior developer with heavy experience with OOP and databases. Through ADO Providers, our programs run equally well with Access, MSDE, SQL Server 7.0, Oracle and others.<br>
<br>
Our 4th tier contains the DBMS. Although each tier could be installed on a dirrerent computer, our 4th tier always resides on the network server and the 1st is always on the desk top. The deployment of the other two depends on performance requirements and other factors. All 4 reside on one machine frequently in developement and testing.<br>
<br>
Good luck, and don't get overwhelmed by it all. Nor should you underestimate what it takes to get cranking with this stuff.<br>
<br>
jlk <br>
<br>

 
Thanks for your info,<br>
<br>
-do you use modeling tools (like Rational Rose)?<br>
-what are the limitations you have found in your methodology?<br>
-VB is enough for 2nd and 3rd tiers? Don't you need C++ or Java?<br>
<br>
I work in a big south american corporation in a support area. We have been developing in SQLWindows (yuk) and Informix. But it's almost definitive that we'll change toward VB and maybe SQL Server.<br>
<br>
We are evaluating it and want to know if VB is a tool that could allow us implement 3 (or 4) tier development with reuse and OOP.<br>
<br>
I'm currently migrating a SQLWindows application to VB6, using ADO, but since it's the first approach the application is 2 tier (C/S) and not enough OOP. (The project started before knowing VB could be the corporative development tool).<br>
<br>
Would you recommend the approach your company is using to us?
 
My experience with multi-tier architecture using only VB does not yet extend to systems beyond 2 or 3 dozen concurrent users. And we feel like pioneers in this technology as it is hrd to find others. However, with my 40 years in application design and programming and my 3 years in this technology, this all has the feel of really good stuff. Also, Microsoft say they have "bet the company" on it.<br>
<br>
I recommend strongly that you get a copy of "Application Specification for Microsoft Windows 2000 for distributed applications" at <br>
To your questions: We do not use application flow modeling. We do use an Erwin product in designing database schema.<br>
The only limitation we have has been self imposed. We did not use MTS (Microsoft Transaction Server) for our 2nd tier and this may have some limitation with scalability. However, with Win2000 and COM+ we will incorporate MTS functionality for its object pooling.<br>
<br>
We are pleased with our decision to use only one language. We made the decision simply to conserve training and startup resources when new languages are adopted. VB itself was new to us. We decided to use outside programmers for C++ if we needed for execution efficiency. So far this has not been needed. Our apps are not now web enabled. We anticipate the possibility of the need for Java when we do, however VB may work there also. It's a matter of whether your users need to use browsers. Our apps are designed to be used in house, so we have a choice.<br>
<br>
As to using our approach for your company, our approach is Microsoft's approach. Also, we have developed code generators which create about 80% of the lines of VB code for both the UI tier and the 2nd tier. We gain much code reuse in UI and 2nd tiers. Our 3rd tier is used without change by all or our programs and can connect efficiently with almost all databases, and even that is coded completely in VB. We are very happy with the results, particularly with the universal flexbility for the user to find data with every single data form using full query by forms, and the VB code to do that is inserted by our generators. But we are very small and our work has not been tested in a large network environment. You would be welcome to take a look.<br>
<br>
A key to our use of ADO is the full use of Parameterized Command Objects. Much faster than ODBC and our application programmers do not have to code SQL statements. SQL Server7.0 appears to be the real thing. We have used it for about 4 months with nothing but good results. We do not now work with Informix, but did for several years and expect our stuff to run well with it.<br>
<br>
OOP and multi-tier is great stuff, particularly when we have Windows2000 and COM+. But poorly designed and implemented applications turn into major headaches.<br>
<br>
Good luck with your new technology. Just don't expect the concepts of OOP and multi-tier to come to you easily. It was not all intuitive for me, and that cause a slow learning curve. A good consultant may be hard to find, but may be well worth it.<br>
<br>
John K.
 
John, I would like to take a look on some of your work. It will be very usefull to me if you send me some class examples (if it was what you meant).<br>
<br>
My email is byronmayorga@yahoo.com<br>
<br>
TIA
 
This may be off the subject a bit, but Ive been working with Vb for a while and the last year or so using vb and access as a front end for Oracle databases, and some asp for providing data to web browsers and I end up spending most of my time trying to keep clients, odbc, mdac components etc. working. What IS the secret to really using vb in a production environment? I still dont dare put normal users on a vb front end. I create utilities and apps for myself and "power" users, but they are not reliable enough to consider for general, production useage. I like ADO, but today the ADO app may work...tomorrow it might just inexplicably NOT work. Had the same problem with vb4 and 5, DAO, ODBC, and stability at the client still eludes me.<br>
<br>
The client tier is the BIG challenge. Browser based applications/front ends have a great appeal when you find yourself with a couple hundred clients scattered all over a spread out MAN/WAN. <br>
<br>
While I enjoy using the microsoft tools I find myself tied to Oracle Developer tools which I do NOT enjoy working with because of the simple reliability of the Oracle native connection. <br>
<br>
Can COM apps be made reliable? Will win2000 solve some of the reliability problems?<br>
<br>

 
Responding to bookor. Our 6 person development firm has spent the past 3 years completing development tasks with VB, COM, DCOM and now ADO. They would have taken maybe 1 year with our old Informix/4GL and/or IBM/RPG technology. Much frustration. We were simply too early with this new technology to avoid pioneer woes.<br>
<br>
In spite of that, I have become a strong advocate of this new technology. We had the "luxury" of starting clean without much legacy code to maintain. Also we did not have the pressure of upper management calling for quick results.<br>
<br>
We now have a suite of applications that can indeed be deployed with stability, reliability, and excellant response times in LAN environments (but not yet WAN). We now use only VB for all tiers (DBMS resides in its own tier). We are delighted with ADO. It enables our object modules to work equally well with multiple DBMS's and at native speeds. Our next phase will be to enable our 2nd tier to work with browsers as well as VB code in the UI tier.<br>
<br>
Our issues of apps working, and then not working have mostly been traced to the miserable situation withh registry problems. A combination of a 3rd party installation tool, care in preparing distribution modules, and carefull checking after installation has brought us to a manageble point. It still canbe a mess and that's one place where we expect help from Win2000.<br>
<br>
A very big issue with us was the large amount of code line required of the programmer as compared with non COM. We have built code generators, 1 for the UI tier and 1 for the 2nd tier, and much of our success is due to them. They create about 80% of the lines of code for us.<br>
<br>
As to Win2000 improving things, we are expecting big time improvements in foundational OS reliability including DOM functions. However, we found that application development of COM apps requires radically different design, project management and deployment approaches and tools. I'd expect this would be equally true for CORBA architecture.<br>
<br>
An MS VP recently said publically that MS had "bet the company" on this stuff. I see it as the only way wintel will ever crack the large system market.<br>
<br>
I'd sure like to hear from other pioneers in COM & COM+.
 
johnk,<br>
<br>
This may be a "lead off the track," however, I have noticed quite a few developers posting questions and discussing COM and DCOM on the VB forum at &lt;codeguru.com&gt; You may enter this forum as an anonymous user to check it out. <br>
<br>
Also, I noticed that MS is scheduling some day lectures on COM+. The lecturer is a Roger Sessions. If you are interested, they gave me &lt; for more information and an e-mail contact &lt;janet@objectwatch.com&gt;<br>
<br>
Hope you find what you are looking for. <br>
<br>
Vienna
 
John,<br>
<br>
I agree - this is the way forward and the only way we'll ever crack the CICS boys.<br>
<br>
I've been looking at, and backing away from in a worried sort of fashion, multi-tiered apps for a while now.<br>
<br>
We develop in a very small team - 3 or 4 people depending on how many I get for a particular project - and the learning curve for this seems to be almost vertical; never mind the fact that we don't do anything OO right now.<br>
<br>
Where the (*&&^ do I start?<br>
<br>
It seems to me that OO is a prerequisite and that just that step will be a huge expense spread over a number of projects with no guarantee of a payback (if we did it badly for instance).<br>
<br>
What did you do?<br>
<br>
Mike<br>
---<br>
Open Systems Engineer/Project Manager<br>
Cargill UK PLC<br>
Mike_Lacey@Cargill.Com<br>

 
Mike,<br>
<br>
Wish I had some comforting input for you. As the owner of a small (6 person) app development firm I had the opportunity (foolishness) to commit my resources to a one year development project with no assurance of pay back. And that 1 year turned into 3 years, mostly because we were too (*&&* early and had to "invent" so many solutions to what seemed like an unending string of new obstacles.<br>
<br>
Our key turned out to be changing our design approaches, even attitudes. It's hard for me to look back and understand, let alone explain. OOP requires the ability to forget much of what we have grown up with, then learn again. Those on my staff who did not grow up with other technology pick up OOP and run with it from the beginning.<br>
<br>
A majority of the few attempts at OOP projects that I know of (except Microsoft company projects) have not been successful. I am told that the word is out among IT directors to avoid it. No wonder to me, for it takes dedication from top management for the long run and a delayed payback. But the payback possibilities are nothing short of revolutionary. From genuinely opening up info availability at speeds and formats not practical before, to serious long term reductions in both equipment and project costs. But, at least for now, the entry fee of patience is more than most can justify paying.<br>
<br>
If you want to "stick you toe in" I have 2 suggestions: (1)Get a copy of "Doing Objects in Microsoft Visual Basic" by Deborah Kurata, Ziff-Davis Press, and (2) take a look at the Duwamish Books project on the MSDN Library site. (We are a VB shop).<br>
<br>
I'm willing to exchange info and ideas with anyone who decides to take the plunge. Good luck.<br>

 
Thx John, I'm going to get "Doing Objects in Microsoft Visual Basic" for a start.<br>
<br>
Mike<br>
---<br>
Mike_Lacey@Cargill.Com<br>

 
Hi John,<br>
<br>
Seems your the only one out there who seems to have knowledge of this.....<br>
<br>
I was wondering, do you use MTS? We are looking to start using COM/DCOM and I have to research it. Is MTS part of this whole area? Is this something to be approached if management are not wholly bought into it???<br>
<br>
Thanks,<br>
<br>
Cal
 
Cal, Remember, I'm an obsolete techie now trying to manage real techies. Check with your personal physician before taking any of this advice.<br>
<br>
MTS is important in multi-tier, particularly if you are designing for large numbers of workstations - say over 50 or 75. Certainly for 100+. It could have more accurately been named MCL for Microsoft Class Broker. It provides for pooling objects so new instantiations don't need to be made for each new user activity. We don't use MTS because we design for about 20 or 30 concurrent users. However, we do use a homemade way to avoid creating new DB connections all the time. MTS would pool several connection objects for reuse, we simply provide 2 connections for each user & keep them until user signs off.<br>
<br>
In summary, use MTS for sure for larger numbers of users. Otherwise is optional. MTS can actually slow things down for small numbers of users.<br>
<br>
Also, Win2000 has rolled COM, DCOM & MTS together into COM+.<br>
<br>
Active management support is an absolute must for this stuff. The learning curve is steep and visible results are delayed. They will have to be investment minded or, in my opinion, you would be headed for disapointment all around. The other side of it is that heros will be made of some who can make it happen 'cause this is the real thing.<br>
<br>
Good luck, John
 
John K.,<br>
<br>
I have been working on an n-tier application for a few weeks now. I have based my approach on the techniques described in Rockford Lhotka's Visual Basic 6 Business Objects. The first tier is the UI (Standard exe), the second tier is the UI-centric business objects (ActiveX dll), the third tier is the data services tier (ActiveX exe), and the fourth is the DBMS (SQL Server 7). Things have been going very well, and I have been very pleased with the design and efficiency of this process.<br>
<br>
However, I have recently run into a problem. When I am running all tiers from the IDE (Interactive Development Environment), the application runs very fast. However, when I compile at least the data services tier, speed is greatly reduced. We have tried many things to figure out why this is so. It appears that whatever is happening is either happening in the data services tier, or in the communication between the UI-centric business objects tier and the data services tier.<br>
<br>
Do you have any ideas why this would occur, or do you know of any specific settings that would need to be changed when running as ActiveX exe vs. running within the IDE? Any help or suggestions would be greatly appreciated.<br>
<br>
Thanks,<br>
Steven Taylor<br>

 
Steven T. and my office have been exchanging useful ideas and experiences related to the above post.<br>
<br>
Anyone else developing in a multi-tier structure is welcome to join in. General interest issues will be posted.<br>
<br>
John Kisner
 
John,<br>
<br>
I remain very interested in n-tier programming - the more you post -- the better as far as I'm concerned.<br>
<br>
<p>Mike Lacey<br><a href=mailto:Mike_Lacey@Cargill.Com>Mike_Lacey@Cargill.Com</a><br><a href= > </a><br>
 
For those interested in our continuing new experiences.<br>
<br>
n-tier for very small systems. We are well into a successful beta experience with a deployment on single user systems. While the total size of the executables is larger because of n-tier, performance is not a problem.<br>
<br>
For small LAN's. Deployment continues to turn up problems. We recently began using InstallMaster from Wise and it has helped quite a bit. I think we will have this one nailed when we resolve the remaining issues with MDAC and DCOM versions.<br>
<br>
We are now to the point that our development cycle time is about what it was before n-tier. The good news is that we see the way clear to substantial continued reduction in dev time. However, it has been a long and hard time to get to this point. Those starting now should get there much quicker - but don't expect an entirely smooth experience.<br>
<br>
Our use of ADO and providers has been quite successful. We develop entirely with the Jet engine, then deploy (with no source code changes - or even recompile) for SQL Server or Jet. We just had an inquiry about Oracle and theoretically can easily accomodate.<br>
<br>
I'd be happy to hear of your experiences or questions.<br>
<br>
John
 
John,<br>
<br>
If you have to work with an Oracle DB - what tiers will you need to change - and how much?<br>
<br>
Mike<br>
<p>Mike Lacey<br><a href=mailto:Mike_Lacey@Cargill.Com>Mike_Lacey@Cargill.Com</a><br><a href= > </a><br>
 
Mike,<br>
<br>
It's hard to generalize on what it takes to change from one database to another. We set that as a design objective in the beginning and made allowances in each tier.<br>
<br>
In general, we code no SQL in the UI or BS tiers. There are some unavoidable exceptions, in our case we do create WHERE clauses. We pass all requests for database interaction to the 3rd tier (Data Access tier) in the form of parameters. The data access tier has knowledge of the database type and path. Our use of ADO and parameterized Command Objects was very important in this process.<br>
<br>
Hope this helps some.<br>
<br>
John
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top