Posts

Showing posts from November, 2004

MSMQ 3.0 and Multicast

Amazing what you can learn when you RTFM, ya know? From the Message Queueing in Windowx XP: New Features : MSMQ 3.0 in Windows XP extends the regular MSMQ programming model from one-to-one to one-to-many. The traditional MSMQ model allows a single message to be sent to a single queue. However, the one-to-many messaging model enables clients to send the same message to multiple recipient queues. MSMQ 3.0 offers multiple ways to implement this model: " Real-time messaging multicast " Distribution lists and multiple-element format names In MSMQ 3.0, one-to-many mechanisms provide the application developer with the fundamental tools required to build sophisticated publish and subscribe systems. These kinds of systems are useful for addressing reliable information dissemination scenarios. Real-Time Messaging Multicast MSMQ 3.0 provides a mechanism to send messages on top of IP multicast. Specifically, MSMQ 3.0 uses the Pragmatic General Multicast (PGM) protocol (see http://www

Another Believer! (EXEC sp_name param, 'param') -Not!

Vis-a-vis my last number on why not to use "Exec spname paramvalue" etc. -- my friend figured out that all the places he was doing new SqlDataAdapter("exec mysp 1,5 'hello'"); are open to SQL injection attack (he thought they were immune to it). Why? Simple- if an attacker can get access to the SQL string they can just add ";DELETE TABLENAME". DOH! So now he is happily rewriting everything to use SqlHelper and turning all those inline text strings into object[] parms={1,5,'hello'}; object arrays. You see that? You are only dumb when you think you know everything....

ADO.NET and SQL Server Optimization

Recently a compatriot and I got into this diatribe over the use of CommandType.Text and "EXEC spName param, param, ..." to make SQL Server stored procedure calls. I had chimed in on his answer to a poster who was having difficulty with a sproc call, and he suggested "you don't need to use the Command Object" and proceeded to show an illustration like the above. Even after I had provided some pretty good background material on why this is not a good idea, he continued to hammer on little pieces of the subject, in effect missing the big picture. There have been many times I've been corrected. As I've grown older (and hopefully wiser) I've learned to put my ego in my back pocket and thank the person for the education. And you? I guess what I am trying to say is this; you have two MVPs who didn't know about this. The only reason I found out about it is because I was lucky enough to attend Tech-Ed 2004 and sit in Gert Drapers' presentation. So

SWIG - Creating Managed Wrappers

Today I discovered SWIG - which makes writing managed C# wrappers for unmanaged C++ libraries and DLLs hugely easier. I am in the process of studying managed C++ wrapper code, "It Just Works" and P/Invoke to handle some needs related to exporting methods from telephony board APIs. Although I haven't gotten very deep into it, one look at all the C# code SWIG generated from a single imported *.h header file has me convinced!

To Deficit - or Not To Deficit? (Don't believe everything you hear):

Image
One of the biggest Bush-bashers during the 2004 Presidential Campaign was the "Huge Deficits" that Pres Dubya recklessly ran up, right? Not! Drops in revenues and increases in outlays occur automatically during a cyclical downturn and then reverse themselves during a cyclical upturn. There is also a "cyclically adjusted deficit". The cyclically adjusted surplus or deficit is calculated to show the underlying outcome of the federal budget when those automatic movements are removed. Policy actions by the Congress and the President, such as tax or spending legislation, create changes in the total budget surplus or deficit that are distinct from the automatic cyclical movements. The cyclically adjusted surplus or deficit includes the effects of those legislated changes. The CBO calculates a different measure, the standardized-budget surplus or deficit, that attempts to remove those factors as well as the effects of the business cycle. As a result, the standardized-bu

Did the Republicans have a Gamma Ray Burst?

or was it just crappy exit polling? At any rate, the popular vote was representative of the largest voter turnout in American history, and George Soros is probably looking for a monastery he can move into. If I sound partisan, it's because I have become so, with America becoming so incredibly polarized. Now maybe the Bush-hating left wing elite media establishment will shut up f or the next four years and we can get on with business! These people have become so arrogant over the years, they have really become out of touch with mainstream America, as the election has proven. And the exit polls - boy that's just a whole 'nuther issue entirely ! Q: What is 50,000 Liberals at the Canadian Border? A: A good start....

Telephone Pet Peeve

Don't you just LOVE these people that leave answering machine messages like they are gonna give you the history of the world, or something? I do most of my business work with my cell phone, leaving the main phone free for the Significant Other. Calls come in all the time when she's out, and since that phone is just off my office and I don't bother answering it, I get to hear all the dumb messages people leave. I mean, "Hello, this is who I am , this is why I am calling, and here's my phone number", right? Oh, NO! They gotta tell you everything and take up 10 minutes of time with all their B.S., when all that can ever happen is you are either gonna call them back or not, right?