windows-wmi-com
STATUS: pre-alpha (0.1.0-dev). Windows-only. Local COM WMI. NOT production-ready.
In-process WMI queries via COM — CoInitializeEx + IWbemLocator::ConnectServer
IWbemServices::ExecQuery+IEnumWbemClassObject. Bypasses the DCOM/RPC overhead that hits any cross-process WMI client; roughly an order of magnitude faster for local queries.
Minimal usage
use Wmi;
let wmi = connect_local?;
for row in wmi.query_raw?
Scope right now
- Working: apartment init (MTA), locator/services connect,
ExecQuery, enumerator drain,VARIANT→WmiValuefor the common scalar cases and 1-DBSTRarrays. - Stubbed / partial: only a subset of
VARIANTtypes are mapped; anything else lands asWmiValue::Nullwith a comment.FromWbemderive helpers do not exist yet — implement the trait by hand. - Not yet: authenticated remote namespaces, method invocation, event
subscriptions,
IWbemContexttuning, async enumeration.
Everything above the "working" line is fair game to fail on non-toy queries.
License
MIT.