31733

Where can I find documentation for publishing data to perfmon in C++?

Years ago I wrote some code to "publish" data for perfmon to consume. Using those counters is pretty well documented, but I found it challenging to find (at the time) good documentation and sample code to publish the data for perfmon.

Does anyone know where I can get this documentation? I also seem to recall some class wrappers, but I may be mistaken.

<hr>

EDIT:

I did find this, and I will keep looking for "custom application performance counters".

Answer1:

You're bringing back old memories!

From 1998, Jeffrey Richter wrote an article in Microsoft Systems Journal describing how to create your own perfmon counters, its very easy (after cutting and pasting his template code just add shared-memory variables in a dll, and update them as needed).

Answer2:

Are you looking for Managed or native wrappers? The link you posted is managed, but your question is native (c++). In managed world things are fairly easy and straight forward to publish counters using the PerformanceCounter and it relatives http://msdn.microsoft.com/en-us/library/system.diagnostics.performancecounter.aspx. For moderate volumes they can also be used for reading counters, for high volumes though you must use the PDH.DLL as the overhead of the managed counters reading one counter at a time will be overwhelming in my experience. Personally I developed XSLT transformations to generate all prfmon counters in my apps, I blogged about this here: http://rusanu.com/2009/04/11/using-xslt-to-generate-performance-counters-code/ and I have more upcoming material to blog down the pipe. If your question is about the unmanaged API, I don't have any pointer handy, but me personally I would go down the path of using again XSLT to generate all my perfmon code, as so much of it is repetitive.

Recommend

  • using python regex to extract certain URLs from text
  • Escape characters in jQuery variables not working
  • Does the CUDA TCC driver work with geforce cards on windows?
  • CSS div position overlay images
  • How to sum distinct values of a field in a MongoDB collection (utilizing mongoose)
  • Inheritance breaking encapsulation?
  • Where can I find documentation for publishing data to perfmon in C++?
  • Solr DataImportHandler doesn't work with XML Files
  • Select distinct pairs joining a table to itself in sql
  • How to loop list value of a specific column in pandas?
  • how to extract text from a html element by id and assign to a php variable?
  • How do encryption algorithms know if they have the right key
  • difference between three development modes in rails
  • Best match using MySQL and PHP
  • Reading comments from .proto files using a Protocol Buffers descriptor object
  • Retrieve List of Cells in Excel Where Column Equals Something
  • Should I be using OAuth to pass data across servers, from JavaScript to C#?
  • How can I count unique terms in a plaintext file case-insensitively?
  • Does the Azure table storage API cache results?
  • powershell Get-Counter -ComputerName parameter on Windows 7
  • Xamarin MonoAndroid Azure mobile service InsertAsync
  • Private IP address in reserved subnet range
  • How To Customize ASP.NET Chart Databound To SqlDataSource
  • Overlapping controls in Windows XP
  • Android changing fragment order inside FragmentPagerAdapter
  • Jquery popup on mouse over of calendar control
  • Ensure fsync did its job
  • How do I get HTML corresponding to current DOM tree?
  • How to create a file in java without a extension
  • Comma separated Values
  • Error creating VM instance in Google Compute Engine
  • Hits per day in Google Big Query
  • how does django model after text[] in postgresql [duplicate]