exam questions

Exam 70-483 All Questions

View all questions & answers for the 70-483 exam

Exam 70-483 topic 1 question 30 discussion

Actual exam question from Microsoft's 70-483
Question #: 30
Topic #: 1
[All 70-483 Questions]

You are developing a method named CreateCounters that will create performance counters for an application.
The method includes the following code. (Line numbers are included for reference only.)

You need to ensure that Counter1 is available for use in Windows Performance Monitor (PerfMon).
Which code segment should you insert at line 16?

  • A. CounterType = PerformanccCounterType.RawBase
  • B. CounterType = PerformanceCounterType.AverageBase
  • C. CounterType = PerformanceCounterType.SampleBase
  • D. CounterType = PerformanceCounterType.CounterMultiBase
Show Suggested Answer Hide Answer
Suggested Answer: C 🗳️
PerformanceCounterType.SampleBase - A base counter that stores the number of sampling interrupts taken and is used as a denominator in the sampling fraction. The sampling fraction is the number of samples that were 1 (or true) for a sample interrupt. Check that this value is greater than zero before using it as the denominator in a calculation of SampleFraction.
PerformanceCounterType.SampleFraction - A percentage counter that shows the average ratio of hits to all operations during the last two sample intervals.
Formula: ((N 1 - N 0) / (D 1 - D 0)) x 100, where the numerator represents the number of successful operations during the last sample interval, and the denominator represents the change in the number of all operations (of the type measured) completed during the sample interval, using counters of type
SampleBase. Counters of this type include Cache\Pin Read Hits %.
References: http://msdn.microsoft.com/en-us/library/system.diagnostics.performancecountertype.aspx

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
tanujgyan
Highly Voted 5 years, 2 months ago
The correct answer is C. The logic is that when you add a counter than you have to add a matching base counter for that. You can refer to sample program similar to this question and table here https://docs.microsoft.com/en-us/dotnet/api/system.diagnostics.performancecountertype?view=netframework-4.8
upvoted 6 times
...
thiemamd
Most Recent 4 years, 10 months ago
I don't understand this choice. Can someone explain more please?
upvoted 2 times
Kilsimon
4 years, 8 months ago
SampleBase: "A base counter that stores the number of sampling interrupts taken and is used as a denominator in the sampling fraction. The sampling fraction is the number of samples that were 1 (or true) for a sample interrupt. Check that this value is greater than zero before using it as the denominator in a calculation of SampleFraction." - https://docs.microsoft.com/en-us/dotnet/api/system.diagnostics.performancecountertype?view=netframework-4.8
upvoted 2 times
...
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...