zynor 0.0.97 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +3 -3
- package/dist/index.d.ts +35 -2
- package/dist/index.js +3 -3
- package/dist/native.cjs +3 -3
- package/dist/native.d.ts +60 -2
- package/dist/native.js +3 -3
- package/package.json +1 -1
- package/rust/zynor-native.darwin-arm64.node +0 -0
package/dist/index.d.ts
CHANGED
|
@@ -724,6 +724,15 @@ declare class NativeProvider {
|
|
|
724
724
|
resolveCaa(hostname: string, options?: AbortOptions): Promise<CaaRecord[]>;
|
|
725
725
|
resolveCname(hostname: string, options?: AbortOptions): Promise<string[]>;
|
|
726
726
|
resolveMx(hostname: string, options?: AbortOptions): Promise<MxRecord[]>;
|
|
727
|
+
/**
|
|
728
|
+
* @internal Resolve MX for many hostnames at once. With the Rust binding
|
|
729
|
+
* this is a SINGLE FFI call for the whole array (concurrency handled inside
|
|
730
|
+
* Rust) — the lever that collapses per-email boundary crossings. Without
|
|
731
|
+
* the binding it falls back to parallel libuv calls (same shape, no FFI
|
|
732
|
+
* win). Per-host failures yield `[]` in that slot; never rejects wholesale.
|
|
733
|
+
* Not queued — the caller governs concurrency at the page level.
|
|
734
|
+
*/
|
|
735
|
+
resolveMxBatch(hostnames: string[], options?: AbortOptions): Promise<MxRecord[][]>;
|
|
727
736
|
resolveNaptr(hostname: string, options?: AbortOptions): Promise<NaptrRecord[]>;
|
|
728
737
|
resolveNs(hostname: string, options?: AbortOptions): Promise<string[]>;
|
|
729
738
|
resolvePtr(hostname: string, options?: AbortOptions): Promise<string[]>;
|
|
@@ -2158,6 +2167,10 @@ declare const records: readonly [
|
|
|
2158
2167
|
readonly name: "Turbify";
|
|
2159
2168
|
readonly mx: "mx-biz.mail.am0.yahoodns.net";
|
|
2160
2169
|
},
|
|
2170
|
+
{
|
|
2171
|
+
readonly name: "Turbify";
|
|
2172
|
+
readonly mx: "mx-van.mail.am0.yahoodns.net";
|
|
2173
|
+
},
|
|
2161
2174
|
{
|
|
2162
2175
|
readonly name: "Turbify";
|
|
2163
2176
|
readonly mx: "mx-biz.mail.am.yahoodns.net";
|
|
@@ -2233,7 +2246,7 @@ declare const records: readonly [
|
|
|
2233
2246
|
readonly mx: ".office365.com";
|
|
2234
2247
|
},
|
|
2235
2248
|
{
|
|
2236
|
-
readonly name: "
|
|
2249
|
+
readonly name: "Google Workspace";
|
|
2237
2250
|
readonly mx: ".google.com";
|
|
2238
2251
|
},
|
|
2239
2252
|
{
|
|
@@ -2544,6 +2557,10 @@ declare const records: readonly [
|
|
|
2544
2557
|
readonly name: "cPanel Webmail";
|
|
2545
2558
|
readonly mx: "..................";
|
|
2546
2559
|
},
|
|
2560
|
+
{
|
|
2561
|
+
readonly name: "Office (OWA)";
|
|
2562
|
+
readonly mx: "..................";
|
|
2563
|
+
},
|
|
2547
2564
|
{
|
|
2548
2565
|
readonly name: "Disposable";
|
|
2549
2566
|
readonly mx: "..................";
|
|
@@ -2646,7 +2663,7 @@ export declare class EmailValidator {
|
|
|
2646
2663
|
private yahooList;
|
|
2647
2664
|
private domain;
|
|
2648
2665
|
private static instance;
|
|
2649
|
-
|
|
2666
|
+
protected dns: Zynor;
|
|
2650
2667
|
private validateCache;
|
|
2651
2668
|
private ipCache;
|
|
2652
2669
|
private inflight;
|
|
@@ -3298,6 +3315,9 @@ export interface RustAnyRecord {
|
|
|
3298
3315
|
}
|
|
3299
3316
|
export interface RustBinding {
|
|
3300
3317
|
resolveMx(hostname: string, options?: RustResolveOptions | null): Promise<RustMxRecord[]>;
|
|
3318
|
+
/** Resolve MX for many hostnames in one FFI call. `out[i]` ↔ `hostnames[i]`;
|
|
3319
|
+
* a per-host failure yields `[]` for that slot (never rejects wholesale). */
|
|
3320
|
+
resolveMxBatch(hostnames: string[], options?: RustResolveOptions | null): Promise<RustMxRecord[][]>;
|
|
3301
3321
|
resolveA(hostname: string, options?: RustResolveOptions | null): Promise<string[]>;
|
|
3302
3322
|
resolveAaaa(hostname: string, options?: RustResolveOptions | null): Promise<string[]>;
|
|
3303
3323
|
resolveCname(hostname: string, options?: RustResolveOptions | null): Promise<string[]>;
|
|
@@ -3666,6 +3686,19 @@ export declare class Zynor {
|
|
|
3666
3686
|
* consumers must continue to use the queued resolve* methods.
|
|
3667
3687
|
*/
|
|
3668
3688
|
_resolveDirect<T>(hostname: string, type: RecordType, options?: AbortOptions): Promise<T>;
|
|
3689
|
+
/**
|
|
3690
|
+
* @internal Validator-only (native `each`). Resolve MX for many hostnames in
|
|
3691
|
+
* a SINGLE batched call and seed the DNS LRU cache under the same `MX:<host>`
|
|
3692
|
+
* keys that {@link _resolveDirect} reads. After warming, each per-email MX
|
|
3693
|
+
* lookup is a cache hit — zero FFI per email. This is what collapses millions
|
|
3694
|
+
* of per-email native crossings into one batched call per page.
|
|
3695
|
+
*
|
|
3696
|
+
* No-op when the cache is disabled (the default `zynor` validator runs with
|
|
3697
|
+
* `cache: { enabled: false }`, so this is only effective for the native
|
|
3698
|
+
* entry, which enables it). Never throws — a batch failure just leaves the
|
|
3699
|
+
* cache cold and validation falls back to per-email resolution.
|
|
3700
|
+
*/
|
|
3701
|
+
_warmMxCache(hostnames: string[], options?: AbortOptions): Promise<void>;
|
|
3669
3702
|
/**
|
|
3670
3703
|
* Returns the sum of concurrency limits across all enabled DNS providers.
|
|
3671
3704
|
* Used by `validateBulk` to determine default parallelism.
|