Michael Rozlog

Static Analysis - Metrics - Volumns

20
Nov

As many of you know, I really like Metrics and Audits for helping build better code.  One thing to remember when doing Metrics, make sure to compare apples to apples and not apple to oranges to steak!

Many metrics are based on the following:

  • Methods; a sub routine of an object
  • Objects;
  • Classes;
  • Files
  • Lines

If you try to compare or make assumptions with metrics that focus on a Method level like Cyclomatic Complexity (CC) and try to relate that to Lines of Code (LOC), the observations are going to be off, really off!

Because having a high or low Cyclomatic complexity has nothing to really do with how many lines of code make up a class or file.  I could have a million lines of code and have a perfectly defined class that has very optimized methods and so Cyclomatic Complexity never gets above 8.

However, looking at Cyclomatic Complexity (CC) and working with Maximum Size of Operation (MSOO) can help determine if there are long methods that have high complexity, which then can be used to help determine a refactoring plan.

Always try to keep data grouped together.

Mike

More to come…

Migration Webinar follow-up…

18
Nov

All,

Thanks for putting up with my voice yesterday.  I hope some of the information was worth the time!  As I stated yesterday, the Parser.exe created by Ander’s is available on his blog:  http://blogs.embarcadero.com/ao/ and the actual Code Central location is:  http://cc.embarcadero.com/item/27398

I was also thinking about doing a part II to the session, where we go through the entire Sanctuary program that we only hit on for about 5 minutes (no slides, just code).  I think there are a few things that I could show that may help other people.  Let me know your thoughts of if you think it would be worth it.

Again, thanks all for coming!

Mike

More to come…

New UML whitepaper for RAD Studio 2010 (Delphi and C++Builder 2010)

11
Sep

All,

As promised last night during my CodeRage 4 session, I have just published a quick whitepaper on the features of the UML, Audits, Metrics, and Doc Generation features for RAD Studio, Delphi, and C++Builder 2010.

The article can be found here:  http://edn.embarcadero.com/article/39931

Hope you enjoy and please let me know what you think.

More to come…

Resources for static analysis: Code Metrics and Code Audits

What would you like to learn about RAD Studio 2010?

31
Aug

If you could have one or two things explained about RAD Studio 2010 or it sub products; Delphi, C++Builder, or Prism… what would it be?

Need ideas?  Here is the link to what is new in RAD Studio 2010 link

In the comment box below, tell me what you want to learn.

I will then work to get a webinar scheduled to go over the top things.

More to come…

Mike

DataSnap the fastest multi-tier development, period – this is the good stuff!

19
May

While many of the diehard Delphi and C++Builder aficionados are familiar with the old MIDAS technology based on COM/DCOM, many at the Delphi Live conference last week learned the current and future underpinnings of the new DataSnap technologies.

If you are not familiar with the new DataSnap technology, you owe it to yourself to find out more about this impressive approach to building multi-tiered applications.

http://edn.embarcadero.com/article/38682 - DataSnap 2009 Overview

http://edn.embarcadero.com/article/38685 - DataSnap 2009 Memory Management

http://edn.embarcadero.com/article/38686 - DataSnap 2009 Threading Model

The new approach was introduced with RAD Studio 2009 (including Delphi & C++Builder) and was based on a NON-COM/DCOM approach. The new approach used JSON (JavaScript Object Notation) http://www.json.org/ housed on a TCP/IP message layer wrapped in the DataSnap technology.

What makes this approach great is that it is simple to implement:

  1. Create a DataSnap Server
    1. Create a VCL Form application
    2. Add the 3 DataSnap Server components
    3. Connect the Server components
    4. Add a ServerModule (this is where the developer exposes business logic and data from the backend storage)
    5. Connect the ServerModule to the Server components for the wire protocol and transfer of information
  2. Create a client (generic client)
    1. Create a VCL form application, Web application, ASP.NET (Prism) application
    2. Drop a TSQLConnection component
    3. Set the connection properties (3 in all)
    4. Right-mouse click on the TSQLConnection and generate Client Proxy
    5. Use Proxy to connect to the remote server and call logic at will
    6. Expose information on client
  3. Done

This is a nine minute demo with explanations, 5 without… at best and IMO, it is the fastest multi-tier approach out there compared to JEE, CORBA, RMI, COM/DCOM, or plain old RPC.

This approach isolates the database layer to the middle tier; there is no reason for the client to know that you are even connecting to a backend database. The exposure of business logic is as simple as writing public functions and the building of the actual server is a form and three (3) components. There are no 7 helper files like with Java’s EJB, or 3 helper files with CORBA, or IDL/RIDL with COM/DCOM, and you surely don’t have to define each side of the communication like with RPC.

So there must be a downside to the technology… there always is… isn’t there? As far as I can see today, there are no advert downsides. There is no royalty to use it, it is simple to understand, it helps to reduce database connections, it very fast, it scales well, and it uses open protocols. What is not to like?

Now could there be more features added or could it even become simpler to use in future releases of the feature/functionality? Sure, but then again, if you are a diehard Delphi/C++Builder developer you already know that we don’t rest on the past implementation we are always trying to push the technology to the next level.

This leads to the next item; I’m going to be publishing the roadmap for RAD Studio very soon and also an audio recording of the presentation. There will be more details about where the technology of DataSnap is going in the future and should give every Delphi/C++Builder/Prism developer some great piece of mind to see the investment being put into our beloved product with Embarcadero!

More to come…

Delphi Live - update

14
May

Technical discussions, Delphi lovers, Great content… it is all good at Delphi Live!

Just a quick update from the floor of Delphi Live, everybody appears to be having fun and the feedback so far has been really great.

This morning during the Product Address that Nick and I did, we covered the new public roadmap. So keep your eyes open for the new roadmap to be posted very soon for RAD Studio.

More to come…

Changes in the wind part II

17
Apr

As many of you may have read in Nick Hodges post (http://www.delphifeeds.com/go/f/55223) he has a new job for Embarcadero. You may be asking yourself “why is Mike going to comment on this new post?” Well, first because Nick really does deserve the new position and because I get to now work more closely with Nick and the Delphi team going forward as the new Product Manager for RAD Studio.

As many of you know, and for those people I’ve met in the past, I’ve been working with Delphi since 1.0. I have trained, introduced companies to Delphi as an employee, consulted on Delphi as a consultant before joining the company, and have been around Delphi ever since joining Borland back in August 1998. Some of you may remember BorCon 2000 where I was showing the ability for the AppServer and CORBA servers to connect to a simple Delphi GUI application (cutting edge at the time) during the Tech Preview session. Heck, just from a historical note, David I and I were talking during his recent visit to Columbus Ohio about how I was in the audience to see David I preview Delphi 1.0.

So like Nick, who is very excited about his new opportunity… I too, am very excited about the new opportunity to not only get to work with Nick more closely but also reconnect and work with many of the people I’ve known for a very long time. My only hope is that I can meet or exceed the excellent job Nick did as the product manager for RAD Studio and our community at large.

As you can imagine, I have a lot of ideas about the products and what could be introduced, enhanced, improved, and expanded. But, I’m always willing to listen, talk-to, and take advice from any and all who will give it. I’m excited about the ability to present to the community at Delphi Live (http://www.delphilive.com/) this year in San Jose CA and I hope to meet, talk, and discuss any and all issues with you during the conference.

As always if you have a concern, an issue, or you want to say you guys are kicking butt, please don’t hesitate to email me at michael.rozlog@embarcadero.com.

More to come…

Off topic: Will the Apple I-Phone become the next economy through micro-transactions?

26
Mar

Ever since I was a young individual, we have been fortunate to have a major “new” economy almost every decade.  If we think about it, in the 80’s we had the PC revolution with almost every company in the world making a personal computer.  Heck, I even had a Timex Sinclair 1000 with a massive 2 k of RAM and 2 k of ROM!  This was also a golden age of the 2nd generation gaming systems like the Atari 2600, Coleco Vision, and Intellevision.

As these markets faltered and diminished, the 3rd generation of gaming systems started to be introduced with Nintendo, Sega, and Sony releasing new consoles to invigorate the industry in the early to mid-90’s and by then the next big wave had hit called the Internet.  Who can forget the heady-times around the internet; no more brick and mortar, everything will be one web.  Who can forget the Super Bowl Ads that were almost 100% internet startup companies?  Heck, in my neck of the woods, at that time if you had the ability to spell the word “CPU” you could get a good paying programming job.  Couple that excitement with the year 2000 scare and it was a good time to be in the computer industry.  However, year 2000 came and went without much excitement, but I may add that there was an extreme amount of investment to ensure it worked that way… if companies would not have invested like they did, most likely the year 2000 and beyond would have had serious repercussions.  Then the Internet bubble popped and once again the industry was made to re-review the entire process.

In the U.S. after the Internet bubble popped, we moved toward housing, and we had an enormous bubble that also popped and we are in the throws of a massive reset.  However, like history before, there is usually something that will rise out of the ashes and start anew.  In the U.S. in the middle-to-late 70’s it was also a very bad time in the U.S., we had higher unemployment than today, inflation was at 13.5% annually, and interest rates were almost 20%.  Many things happened, but new industries were born and we moved to a time of relative calmness and growing prosperous markets.

So looking around the landscape today, are there any new technologies that are getting people, companies, and the world excited?  Could we be at the start of an entirely new market?  Could the Apple iPhone be the phone that finally brings the “mobile market” that I’ve been reading about and hearing about for the last 10 years?  Could one device really create an Economy?  Will the 3.0 SDK enable this micro-economy and could it be big enough to get us out of the market situations we are experiencing now?

As of this writing, Apple has shipped a little over 17,000,000 units and in over 80 countries.  If you add the iTouch to the mix, which ironically runs the same OS, the combined number of units is over 30,000,000.  This is since the middle of 2007.  It has single-handedly created a new game console, communication device, entertainment device, and business tool in a very short time, all in one device.  The iPhone has had over 800,000 downloads of its free developer SDK and had over 50,000 developers pay to join the development community. Plus, the AppStore has over 25,000 applications that can be added to the hardware and has already shipped or downloaded over 500,000,000 applications as of Jan 2009 and is increasing.  Oh, and one other thing, the iPhone is still not released in the largest market in the world… China!  It has spawned an industry of accessories, add-ins, and add-ons, but that is not all.  This device has in-my-opinion, brought smart phones to the forefront, not just for the iPhone but for all of the phones on the market today.

If you look at the phone market today, what are we reading about?  Of course the iPhone is most-likely at the top of the list, but we are also hearing about the Palm Pre, Blackberry Storm, and the Android based units.  Each of these companies is following in the footsteps of Apple, trying to tap in to the excitement that Apple has created.  The great news is that Apple is also updating the way business is done; they take a percentage of the selling application and handle the transaction for you.  If you already have a way to handle the transaction you can use your own, but for the small company, the 1 man shop, having a company that will be the credit-card provider, tracking, hosting, and management of the software for you is incredibly useful.  This has opened a whole new world to a market that 2 years ago was not there.  The new 3.0 API is also enabling a few features that will allow applications to be unlocked or enabled during the running of the application, thus, opening a new realm around the micro-transactions and the ability to enable pay as you go or as you need.

All of this leads me to believe that “YES” Apple has created a new economy, and it is that big; they have opened the doors on the mobile market promise, and they have revolutionized the way applications will be delivered in the future.  The only question that remains is will this new economy grow fast enough or become big enough to bring the entire world out of a market downturn?  Well, as Apple was part of the original PC revolution that spawned a new economy, they revolutionized the music industry, they solidified the vision of a mobile entertainment device, and now are on the edge of a new market in communications…  Whew… as my friend likes to say “it is all good” and you know what, that is either light at the end of the tunnel or it’s a train just about to run me over!  It’s all good!

Changes in the wind…

13
Feb

For those of you who read this blog regularly and nicely ping me to write more, I thank you for your support. As I mentioned in one of my last blog-postings, many things were changing and that I would fill you in as those changes became clearer.

The first bit of news; I’m now the Product Manager for both the JBuilder and also the 3rd Rail (Ruby on Rails) line of products. I’m very excited about the thrilling opportunities I see for both markets and in the same breath, excited about what “you” the readers of this blog will tell me. Trust me when I say, I really want to hear it. If you like things in the products let me know, if you hate things in the products let me know, if you want to see some ‘x’ functionality, let me know. As you can most likely imagine I have a lot of ideas when it comes to the products and how they should behave, react to changes in the software world, and how products can help developers build better software. But, I also know that there are a ton of great developers out there that need or want things that I may not know of or recognize as extremely important. For example, I have a very good friend that for the last 2 years has been excited about Groovy; YAWTFJ (yet another web technology for java I thought) and I listened, downloaded, played with, and started to understand his passion about its approach and now agree with him that Groovy is truly groovy when it comes to building Java based web applications. Without his insistence that I take a look at it, I would have never (most likely) been exposed to the power of the library / approach.

I also understand that there are great challenges before us in the market place, and not just from the general competition stand-point. I like competition; it means you have a vibrant market and it spurs innovation. I also like the fact that open source continues to put pressure on products to deliver more for less. But, I think the biggest challenge we as developers have before us is getting beyond the Edit, Compile, Debug syndrome that development of all-types has fallen under as of late. Maybe it is the down economy, maybe it is having too much on our plates, maybe we are getting bored, or maybe, just maybe we as developers don’t see the intrinsic value of delivering more with less. Usually in a down-economy it means more will be getting put on our plates, and if it is a lot of the same-old-same-old, then yes boredom is definitely a strong possibility. Some that I’ve talked to say “it does not matter how much I work, the company is going to pay me for doing work from 9 – 5, so if I write 50 lines of code or the IDE generates 50 lines of code, what is the difference?” That comment is scary on so many different levels that it warrants its own blog-posting later. What I’m more concerned about is that developers don’t think they have the time to look beyond the Edit, Compile, and Debug process. Here in lies in my opinion my greatest challenge, as an example, just running software audits on your existing code before it goes to unit testing or QA could save significant cycles because the audits will alert you that you have logic or approach errors in your code and if you fix it now, it will save significant time down the line. What is interesting is when I use that example out in the field, at a software development conference, or talking to a group of developers they all shake their heads in agreement and even comment “well-of-course, that makes sense,’ but when I then ask how many run audits, very few if any raise their hands! Is it the group / heard mentality, or not believing they have time to run the audits, or don’t understand what audits to run, or don’t know where to find the audit functionality in the software, or… a great number of other questions. I think it is all of the above and that is what has to get fixed. If you know about a feature that will save you time, resources, and ultimately money, but you don’t have a clue on how and when to use it or even where it is located, then do you really have that feature? If you don’t have the feature then you don’t have value and you really have Edit, Compile and Debug.

© 2009 Michael Rozlog | Entries (RSS) and Comments (RSS)

Your Index Web Directorywordpress logo

Bad Behavior has blocked 2 access attempts in the last 7 days.

Close