chainlesschain 0.145.0 → 0.152.0
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/package.json +1 -1
- package/src/commands/activitypub.js +207 -0
- package/src/commands/agent-network.js +217 -0
- package/src/commands/automation.js +201 -0
- package/src/commands/bi.js +203 -0
- package/src/commands/browse.js +213 -0
- package/src/commands/codegen.js +207 -0
- package/src/commands/collab.js +211 -0
- package/src/commands/compliance.js +410 -0
- package/src/commands/cowork.js +203 -0
- package/src/commands/dbevo.js +227 -0
- package/src/commands/dev.js +207 -0
- package/src/commands/did-v2.js +217 -0
- package/src/commands/did.js +221 -0
- package/src/commands/dlp.js +213 -0
- package/src/commands/evomap.js +205 -0
- package/src/commands/export.js +213 -0
- package/src/commands/federation.js +209 -0
- package/src/commands/fusion.js +205 -0
- package/src/commands/governance.js +209 -0
- package/src/commands/hook.js +209 -0
- package/src/commands/import.js +209 -0
- package/src/commands/infra.js +203 -0
- package/src/commands/instinct.js +209 -0
- package/src/commands/ipfs.js +207 -0
- package/src/commands/llm.js +217 -0
- package/src/commands/matrix.js +207 -0
- package/src/commands/mcp.js +217 -0
- package/src/commands/memory.js +209 -0
- package/src/commands/multimodal.js +203 -0
- package/src/commands/nlprog.js +225 -0
- package/src/commands/nostr.js +209 -0
- package/src/commands/note.js +205 -0
- package/src/commands/ops.js +219 -0
- package/src/commands/org.js +209 -0
- package/src/commands/p2p.js +209 -0
- package/src/commands/perception.js +209 -0
- package/src/commands/permmem.js +203 -0
- package/src/commands/plugin-ecosystem.js +209 -0
- package/src/commands/pqc.js +213 -0
- package/src/commands/quantization.js +207 -0
- package/src/commands/rcache.js +205 -0
- package/src/commands/recommend.js +233 -0
- package/src/commands/runtime.js +205 -0
- package/src/commands/scim.js +209 -0
- package/src/commands/session.js +209 -0
- package/src/commands/skill.js +207 -0
- package/src/commands/social.js +201 -0
- package/src/commands/sso.js +209 -0
- package/src/commands/sync.js +209 -0
- package/src/commands/tech.js +209 -0
- package/src/commands/tenant.js +217 -0
- package/src/commands/tokens.js +209 -0
- package/src/commands/trust.js +217 -0
- package/src/commands/wallet.js +209 -0
- package/src/commands/workflow.js +203 -0
- package/src/index.js +140 -0
- package/src/lib/activitypub-bridge.js +334 -0
- package/src/lib/agent-network.js +341 -0
- package/src/lib/aiops.js +346 -0
- package/src/lib/automation-engine.js +335 -0
- package/src/lib/autonomous-developer.js +332 -0
- package/src/lib/bi-engine.js +333 -0
- package/src/lib/browser-automation.js +334 -0
- package/src/lib/code-agent.js +339 -0
- package/src/lib/collaboration-governance.js +334 -0
- package/src/lib/community-governance.js +346 -0
- package/src/lib/content-recommendation.js +351 -0
- package/src/lib/cowork-share.js +338 -0
- package/src/lib/dbevo.js +351 -0
- package/src/lib/decentral-infra.js +330 -0
- package/src/lib/did-manager.js +341 -0
- package/src/lib/did-v2-manager.js +341 -0
- package/src/lib/dlp-engine.js +339 -0
- package/src/lib/evomap-governance.js +334 -0
- package/src/lib/federation-hardening.js +340 -0
- package/src/lib/hook-manager.js +341 -0
- package/src/lib/instinct-manager.js +346 -0
- package/src/lib/ipfs-storage.js +334 -0
- package/src/lib/knowledge-exporter.js +341 -0
- package/src/lib/knowledge-importer.js +341 -0
- package/src/lib/llm-providers.js +346 -0
- package/src/lib/matrix-bridge.js +339 -0
- package/src/lib/mcp-registry.js +346 -0
- package/src/lib/memory-manager.js +336 -0
- package/src/lib/multimodal.js +330 -0
- package/src/lib/nl-programming.js +341 -0
- package/src/lib/nostr-bridge.js +336 -0
- package/src/lib/note-versioning.js +339 -0
- package/src/lib/org-manager.js +336 -0
- package/src/lib/p2p-manager.js +341 -0
- package/src/lib/perception.js +346 -0
- package/src/lib/permanent-memory.js +327 -0
- package/src/lib/plugin-ecosystem.js +346 -0
- package/src/lib/pqc-manager.js +346 -0
- package/src/lib/protocol-fusion.js +338 -0
- package/src/lib/quantization.js +337 -0
- package/src/lib/response-cache.js +333 -0
- package/src/lib/scim-manager.js +346 -0
- package/src/lib/session-manager.js +334 -0
- package/src/lib/skill-loader.js +334 -0
- package/src/lib/social-manager.js +330 -0
- package/src/lib/sso-manager.js +340 -0
- package/src/lib/sync-manager.js +336 -0
- package/src/lib/tech-learning-engine.js +341 -0
- package/src/lib/tenant-saas.js +341 -0
- package/src/lib/threat-intel.js +330 -0
- package/src/lib/token-tracker.js +336 -0
- package/src/lib/trust-security.js +343 -0
- package/src/lib/ueba.js +340 -0
- package/src/lib/universal-runtime.js +330 -0
- package/src/lib/wallet-manager.js +336 -0
- package/src/lib/workflow-engine.js +330 -0
|
@@ -607,3 +607,333 @@ export function _resetStateSocialManagerV2() {
|
|
|
607
607
|
_relationshipIdleMsV2 = SOCIAL_DEFAULT_RELATIONSHIP_IDLE_MS;
|
|
608
608
|
_threadStuckMsV2 = SOCIAL_DEFAULT_THREAD_STUCK_MS;
|
|
609
609
|
}
|
|
610
|
+
|
|
611
|
+
// =====================================================================
|
|
612
|
+
// social-manager V2 governance overlay (iter22)
|
|
613
|
+
// =====================================================================
|
|
614
|
+
export const SMGOV_PROFILE_MATURITY_V2 = Object.freeze({
|
|
615
|
+
PENDING: "pending",
|
|
616
|
+
ACTIVE: "active",
|
|
617
|
+
MUTED: "muted",
|
|
618
|
+
ARCHIVED: "archived",
|
|
619
|
+
});
|
|
620
|
+
export const SMGOV_POST_LIFECYCLE_V2 = Object.freeze({
|
|
621
|
+
QUEUED: "queued",
|
|
622
|
+
POSTING: "posting",
|
|
623
|
+
POSTED: "posted",
|
|
624
|
+
FAILED: "failed",
|
|
625
|
+
CANCELLED: "cancelled",
|
|
626
|
+
});
|
|
627
|
+
const _smgovPTrans = new Map([
|
|
628
|
+
[
|
|
629
|
+
SMGOV_PROFILE_MATURITY_V2.PENDING,
|
|
630
|
+
new Set([
|
|
631
|
+
SMGOV_PROFILE_MATURITY_V2.ACTIVE,
|
|
632
|
+
SMGOV_PROFILE_MATURITY_V2.ARCHIVED,
|
|
633
|
+
]),
|
|
634
|
+
],
|
|
635
|
+
[
|
|
636
|
+
SMGOV_PROFILE_MATURITY_V2.ACTIVE,
|
|
637
|
+
new Set([
|
|
638
|
+
SMGOV_PROFILE_MATURITY_V2.MUTED,
|
|
639
|
+
SMGOV_PROFILE_MATURITY_V2.ARCHIVED,
|
|
640
|
+
]),
|
|
641
|
+
],
|
|
642
|
+
[
|
|
643
|
+
SMGOV_PROFILE_MATURITY_V2.MUTED,
|
|
644
|
+
new Set([
|
|
645
|
+
SMGOV_PROFILE_MATURITY_V2.ACTIVE,
|
|
646
|
+
SMGOV_PROFILE_MATURITY_V2.ARCHIVED,
|
|
647
|
+
]),
|
|
648
|
+
],
|
|
649
|
+
[SMGOV_PROFILE_MATURITY_V2.ARCHIVED, new Set()],
|
|
650
|
+
]);
|
|
651
|
+
const _smgovPTerminal = new Set([SMGOV_PROFILE_MATURITY_V2.ARCHIVED]);
|
|
652
|
+
const _smgovJTrans = new Map([
|
|
653
|
+
[
|
|
654
|
+
SMGOV_POST_LIFECYCLE_V2.QUEUED,
|
|
655
|
+
new Set([
|
|
656
|
+
SMGOV_POST_LIFECYCLE_V2.POSTING,
|
|
657
|
+
SMGOV_POST_LIFECYCLE_V2.CANCELLED,
|
|
658
|
+
]),
|
|
659
|
+
],
|
|
660
|
+
[
|
|
661
|
+
SMGOV_POST_LIFECYCLE_V2.POSTING,
|
|
662
|
+
new Set([
|
|
663
|
+
SMGOV_POST_LIFECYCLE_V2.POSTED,
|
|
664
|
+
SMGOV_POST_LIFECYCLE_V2.FAILED,
|
|
665
|
+
SMGOV_POST_LIFECYCLE_V2.CANCELLED,
|
|
666
|
+
]),
|
|
667
|
+
],
|
|
668
|
+
[SMGOV_POST_LIFECYCLE_V2.POSTED, new Set()],
|
|
669
|
+
[SMGOV_POST_LIFECYCLE_V2.FAILED, new Set()],
|
|
670
|
+
[SMGOV_POST_LIFECYCLE_V2.CANCELLED, new Set()],
|
|
671
|
+
]);
|
|
672
|
+
const _smgovPsV2 = new Map();
|
|
673
|
+
const _smgovJsV2 = new Map();
|
|
674
|
+
let _smgovMaxActive = 10,
|
|
675
|
+
_smgovMaxPending = 30,
|
|
676
|
+
_smgovIdleMs = 30 * 24 * 60 * 60 * 1000,
|
|
677
|
+
_smgovStuckMs = 60 * 1000;
|
|
678
|
+
function _smgovPos(n, label) {
|
|
679
|
+
const v = Math.floor(Number(n));
|
|
680
|
+
if (!Number.isFinite(v) || v <= 0)
|
|
681
|
+
throw new Error(`${label} must be positive integer`);
|
|
682
|
+
return v;
|
|
683
|
+
}
|
|
684
|
+
function _smgovCheckP(from, to) {
|
|
685
|
+
const a = _smgovPTrans.get(from);
|
|
686
|
+
if (!a || !a.has(to))
|
|
687
|
+
throw new Error(`invalid smgov profile transition ${from} → ${to}`);
|
|
688
|
+
}
|
|
689
|
+
function _smgovCheckJ(from, to) {
|
|
690
|
+
const a = _smgovJTrans.get(from);
|
|
691
|
+
if (!a || !a.has(to))
|
|
692
|
+
throw new Error(`invalid smgov post transition ${from} → ${to}`);
|
|
693
|
+
}
|
|
694
|
+
function _smgovCountActive(owner) {
|
|
695
|
+
let c = 0;
|
|
696
|
+
for (const p of _smgovPsV2.values())
|
|
697
|
+
if (p.owner === owner && p.status === SMGOV_PROFILE_MATURITY_V2.ACTIVE) c++;
|
|
698
|
+
return c;
|
|
699
|
+
}
|
|
700
|
+
function _smgovCountPending(profileId) {
|
|
701
|
+
let c = 0;
|
|
702
|
+
for (const j of _smgovJsV2.values())
|
|
703
|
+
if (
|
|
704
|
+
j.profileId === profileId &&
|
|
705
|
+
(j.status === SMGOV_POST_LIFECYCLE_V2.QUEUED ||
|
|
706
|
+
j.status === SMGOV_POST_LIFECYCLE_V2.POSTING)
|
|
707
|
+
)
|
|
708
|
+
c++;
|
|
709
|
+
return c;
|
|
710
|
+
}
|
|
711
|
+
export function setMaxActiveSmgovProfilesPerOwnerV2(n) {
|
|
712
|
+
_smgovMaxActive = _smgovPos(n, "maxActiveSmgovProfilesPerOwner");
|
|
713
|
+
}
|
|
714
|
+
export function getMaxActiveSmgovProfilesPerOwnerV2() {
|
|
715
|
+
return _smgovMaxActive;
|
|
716
|
+
}
|
|
717
|
+
export function setMaxPendingSmgovPostsPerProfileV2(n) {
|
|
718
|
+
_smgovMaxPending = _smgovPos(n, "maxPendingSmgovPostsPerProfile");
|
|
719
|
+
}
|
|
720
|
+
export function getMaxPendingSmgovPostsPerProfileV2() {
|
|
721
|
+
return _smgovMaxPending;
|
|
722
|
+
}
|
|
723
|
+
export function setSmgovProfileIdleMsV2(n) {
|
|
724
|
+
_smgovIdleMs = _smgovPos(n, "smgovProfileIdleMs");
|
|
725
|
+
}
|
|
726
|
+
export function getSmgovProfileIdleMsV2() {
|
|
727
|
+
return _smgovIdleMs;
|
|
728
|
+
}
|
|
729
|
+
export function setSmgovPostStuckMsV2(n) {
|
|
730
|
+
_smgovStuckMs = _smgovPos(n, "smgovPostStuckMs");
|
|
731
|
+
}
|
|
732
|
+
export function getSmgovPostStuckMsV2() {
|
|
733
|
+
return _smgovStuckMs;
|
|
734
|
+
}
|
|
735
|
+
export function _resetStateSocialManagerGovV2() {
|
|
736
|
+
_smgovPsV2.clear();
|
|
737
|
+
_smgovJsV2.clear();
|
|
738
|
+
_smgovMaxActive = 10;
|
|
739
|
+
_smgovMaxPending = 30;
|
|
740
|
+
_smgovIdleMs = 30 * 24 * 60 * 60 * 1000;
|
|
741
|
+
_smgovStuckMs = 60 * 1000;
|
|
742
|
+
}
|
|
743
|
+
export function registerSmgovProfileV2({ id, owner, channel, metadata } = {}) {
|
|
744
|
+
if (!id || !owner) throw new Error("id and owner required");
|
|
745
|
+
if (_smgovPsV2.has(id)) throw new Error(`smgov profile ${id} already exists`);
|
|
746
|
+
const now = Date.now();
|
|
747
|
+
const p = {
|
|
748
|
+
id,
|
|
749
|
+
owner,
|
|
750
|
+
channel: channel || "timeline",
|
|
751
|
+
status: SMGOV_PROFILE_MATURITY_V2.PENDING,
|
|
752
|
+
createdAt: now,
|
|
753
|
+
updatedAt: now,
|
|
754
|
+
lastTouchedAt: now,
|
|
755
|
+
activatedAt: null,
|
|
756
|
+
archivedAt: null,
|
|
757
|
+
metadata: { ...(metadata || {}) },
|
|
758
|
+
};
|
|
759
|
+
_smgovPsV2.set(id, p);
|
|
760
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
761
|
+
}
|
|
762
|
+
export function activateSmgovProfileV2(id) {
|
|
763
|
+
const p = _smgovPsV2.get(id);
|
|
764
|
+
if (!p) throw new Error(`smgov profile ${id} not found`);
|
|
765
|
+
const isInitial = p.status === SMGOV_PROFILE_MATURITY_V2.PENDING;
|
|
766
|
+
_smgovCheckP(p.status, SMGOV_PROFILE_MATURITY_V2.ACTIVE);
|
|
767
|
+
if (isInitial && _smgovCountActive(p.owner) >= _smgovMaxActive)
|
|
768
|
+
throw new Error(`max active smgov profiles for owner ${p.owner} reached`);
|
|
769
|
+
const now = Date.now();
|
|
770
|
+
p.status = SMGOV_PROFILE_MATURITY_V2.ACTIVE;
|
|
771
|
+
p.updatedAt = now;
|
|
772
|
+
p.lastTouchedAt = now;
|
|
773
|
+
if (!p.activatedAt) p.activatedAt = now;
|
|
774
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
775
|
+
}
|
|
776
|
+
export function muteSmgovProfileV2(id) {
|
|
777
|
+
const p = _smgovPsV2.get(id);
|
|
778
|
+
if (!p) throw new Error(`smgov profile ${id} not found`);
|
|
779
|
+
_smgovCheckP(p.status, SMGOV_PROFILE_MATURITY_V2.MUTED);
|
|
780
|
+
p.status = SMGOV_PROFILE_MATURITY_V2.MUTED;
|
|
781
|
+
p.updatedAt = Date.now();
|
|
782
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
783
|
+
}
|
|
784
|
+
export function archiveSmgovProfileV2(id) {
|
|
785
|
+
const p = _smgovPsV2.get(id);
|
|
786
|
+
if (!p) throw new Error(`smgov profile ${id} not found`);
|
|
787
|
+
_smgovCheckP(p.status, SMGOV_PROFILE_MATURITY_V2.ARCHIVED);
|
|
788
|
+
const now = Date.now();
|
|
789
|
+
p.status = SMGOV_PROFILE_MATURITY_V2.ARCHIVED;
|
|
790
|
+
p.updatedAt = now;
|
|
791
|
+
if (!p.archivedAt) p.archivedAt = now;
|
|
792
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
793
|
+
}
|
|
794
|
+
export function touchSmgovProfileV2(id) {
|
|
795
|
+
const p = _smgovPsV2.get(id);
|
|
796
|
+
if (!p) throw new Error(`smgov profile ${id} not found`);
|
|
797
|
+
if (_smgovPTerminal.has(p.status))
|
|
798
|
+
throw new Error(`cannot touch terminal smgov profile ${id}`);
|
|
799
|
+
const now = Date.now();
|
|
800
|
+
p.lastTouchedAt = now;
|
|
801
|
+
p.updatedAt = now;
|
|
802
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
803
|
+
}
|
|
804
|
+
export function getSmgovProfileV2(id) {
|
|
805
|
+
const p = _smgovPsV2.get(id);
|
|
806
|
+
if (!p) return null;
|
|
807
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
808
|
+
}
|
|
809
|
+
export function listSmgovProfilesV2() {
|
|
810
|
+
return [..._smgovPsV2.values()].map((p) => ({
|
|
811
|
+
...p,
|
|
812
|
+
metadata: { ...p.metadata },
|
|
813
|
+
}));
|
|
814
|
+
}
|
|
815
|
+
export function createSmgovPostV2({ id, profileId, author, metadata } = {}) {
|
|
816
|
+
if (!id || !profileId) throw new Error("id and profileId required");
|
|
817
|
+
if (_smgovJsV2.has(id)) throw new Error(`smgov post ${id} already exists`);
|
|
818
|
+
if (!_smgovPsV2.has(profileId))
|
|
819
|
+
throw new Error(`smgov profile ${profileId} not found`);
|
|
820
|
+
if (_smgovCountPending(profileId) >= _smgovMaxPending)
|
|
821
|
+
throw new Error(`max pending smgov posts for profile ${profileId} reached`);
|
|
822
|
+
const now = Date.now();
|
|
823
|
+
const j = {
|
|
824
|
+
id,
|
|
825
|
+
profileId,
|
|
826
|
+
author: author || "",
|
|
827
|
+
status: SMGOV_POST_LIFECYCLE_V2.QUEUED,
|
|
828
|
+
createdAt: now,
|
|
829
|
+
updatedAt: now,
|
|
830
|
+
startedAt: null,
|
|
831
|
+
settledAt: null,
|
|
832
|
+
metadata: { ...(metadata || {}) },
|
|
833
|
+
};
|
|
834
|
+
_smgovJsV2.set(id, j);
|
|
835
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
836
|
+
}
|
|
837
|
+
export function postingSmgovPostV2(id) {
|
|
838
|
+
const j = _smgovJsV2.get(id);
|
|
839
|
+
if (!j) throw new Error(`smgov post ${id} not found`);
|
|
840
|
+
_smgovCheckJ(j.status, SMGOV_POST_LIFECYCLE_V2.POSTING);
|
|
841
|
+
const now = Date.now();
|
|
842
|
+
j.status = SMGOV_POST_LIFECYCLE_V2.POSTING;
|
|
843
|
+
j.updatedAt = now;
|
|
844
|
+
if (!j.startedAt) j.startedAt = now;
|
|
845
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
846
|
+
}
|
|
847
|
+
export function completePostSmgovV2(id) {
|
|
848
|
+
const j = _smgovJsV2.get(id);
|
|
849
|
+
if (!j) throw new Error(`smgov post ${id} not found`);
|
|
850
|
+
_smgovCheckJ(j.status, SMGOV_POST_LIFECYCLE_V2.POSTED);
|
|
851
|
+
const now = Date.now();
|
|
852
|
+
j.status = SMGOV_POST_LIFECYCLE_V2.POSTED;
|
|
853
|
+
j.updatedAt = now;
|
|
854
|
+
if (!j.settledAt) j.settledAt = now;
|
|
855
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
856
|
+
}
|
|
857
|
+
export function failSmgovPostV2(id, reason) {
|
|
858
|
+
const j = _smgovJsV2.get(id);
|
|
859
|
+
if (!j) throw new Error(`smgov post ${id} not found`);
|
|
860
|
+
_smgovCheckJ(j.status, SMGOV_POST_LIFECYCLE_V2.FAILED);
|
|
861
|
+
const now = Date.now();
|
|
862
|
+
j.status = SMGOV_POST_LIFECYCLE_V2.FAILED;
|
|
863
|
+
j.updatedAt = now;
|
|
864
|
+
if (!j.settledAt) j.settledAt = now;
|
|
865
|
+
if (reason) j.metadata.failReason = String(reason);
|
|
866
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
867
|
+
}
|
|
868
|
+
export function cancelSmgovPostV2(id, reason) {
|
|
869
|
+
const j = _smgovJsV2.get(id);
|
|
870
|
+
if (!j) throw new Error(`smgov post ${id} not found`);
|
|
871
|
+
_smgovCheckJ(j.status, SMGOV_POST_LIFECYCLE_V2.CANCELLED);
|
|
872
|
+
const now = Date.now();
|
|
873
|
+
j.status = SMGOV_POST_LIFECYCLE_V2.CANCELLED;
|
|
874
|
+
j.updatedAt = now;
|
|
875
|
+
if (!j.settledAt) j.settledAt = now;
|
|
876
|
+
if (reason) j.metadata.cancelReason = String(reason);
|
|
877
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
878
|
+
}
|
|
879
|
+
export function getSmgovPostV2(id) {
|
|
880
|
+
const j = _smgovJsV2.get(id);
|
|
881
|
+
if (!j) return null;
|
|
882
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
883
|
+
}
|
|
884
|
+
export function listSmgovPostsV2() {
|
|
885
|
+
return [..._smgovJsV2.values()].map((j) => ({
|
|
886
|
+
...j,
|
|
887
|
+
metadata: { ...j.metadata },
|
|
888
|
+
}));
|
|
889
|
+
}
|
|
890
|
+
export function autoMuteIdleSmgovProfilesV2({ now } = {}) {
|
|
891
|
+
const t = now ?? Date.now();
|
|
892
|
+
const flipped = [];
|
|
893
|
+
for (const p of _smgovPsV2.values())
|
|
894
|
+
if (
|
|
895
|
+
p.status === SMGOV_PROFILE_MATURITY_V2.ACTIVE &&
|
|
896
|
+
t - p.lastTouchedAt >= _smgovIdleMs
|
|
897
|
+
) {
|
|
898
|
+
p.status = SMGOV_PROFILE_MATURITY_V2.MUTED;
|
|
899
|
+
p.updatedAt = t;
|
|
900
|
+
flipped.push(p.id);
|
|
901
|
+
}
|
|
902
|
+
return { flipped, count: flipped.length };
|
|
903
|
+
}
|
|
904
|
+
export function autoFailStuckSmgovPostsV2({ now } = {}) {
|
|
905
|
+
const t = now ?? Date.now();
|
|
906
|
+
const flipped = [];
|
|
907
|
+
for (const j of _smgovJsV2.values())
|
|
908
|
+
if (
|
|
909
|
+
j.status === SMGOV_POST_LIFECYCLE_V2.POSTING &&
|
|
910
|
+
j.startedAt != null &&
|
|
911
|
+
t - j.startedAt >= _smgovStuckMs
|
|
912
|
+
) {
|
|
913
|
+
j.status = SMGOV_POST_LIFECYCLE_V2.FAILED;
|
|
914
|
+
j.updatedAt = t;
|
|
915
|
+
if (!j.settledAt) j.settledAt = t;
|
|
916
|
+
j.metadata.failReason = "auto-fail-stuck";
|
|
917
|
+
flipped.push(j.id);
|
|
918
|
+
}
|
|
919
|
+
return { flipped, count: flipped.length };
|
|
920
|
+
}
|
|
921
|
+
export function getSocialManagerGovStatsV2() {
|
|
922
|
+
const profilesByStatus = {};
|
|
923
|
+
for (const v of Object.values(SMGOV_PROFILE_MATURITY_V2))
|
|
924
|
+
profilesByStatus[v] = 0;
|
|
925
|
+
for (const p of _smgovPsV2.values()) profilesByStatus[p.status]++;
|
|
926
|
+
const postsByStatus = {};
|
|
927
|
+
for (const v of Object.values(SMGOV_POST_LIFECYCLE_V2)) postsByStatus[v] = 0;
|
|
928
|
+
for (const j of _smgovJsV2.values()) postsByStatus[j.status]++;
|
|
929
|
+
return {
|
|
930
|
+
totalSmgovProfilesV2: _smgovPsV2.size,
|
|
931
|
+
totalSmgovPostsV2: _smgovJsV2.size,
|
|
932
|
+
maxActiveSmgovProfilesPerOwner: _smgovMaxActive,
|
|
933
|
+
maxPendingSmgovPostsPerProfile: _smgovMaxPending,
|
|
934
|
+
smgovProfileIdleMs: _smgovIdleMs,
|
|
935
|
+
smgovPostStuckMs: _smgovStuckMs,
|
|
936
|
+
profilesByStatus,
|
|
937
|
+
postsByStatus,
|
|
938
|
+
};
|
|
939
|
+
}
|
package/src/lib/sso-manager.js
CHANGED
|
@@ -1171,3 +1171,343 @@ export function getSsoManagerStatsV2() {
|
|
|
1171
1171
|
loginsByStatus,
|
|
1172
1172
|
};
|
|
1173
1173
|
}
|
|
1174
|
+
|
|
1175
|
+
// =====================================================================
|
|
1176
|
+
// sso-manager V2 governance overlay (iter19)
|
|
1177
|
+
// =====================================================================
|
|
1178
|
+
export const SSOGOV_PROFILE_MATURITY_V2 = Object.freeze({
|
|
1179
|
+
PENDING: "pending",
|
|
1180
|
+
ACTIVE: "active",
|
|
1181
|
+
SUSPENDED: "suspended",
|
|
1182
|
+
ARCHIVED: "archived",
|
|
1183
|
+
});
|
|
1184
|
+
export const SSOGOV_LOGIN_LIFECYCLE_V2 = Object.freeze({
|
|
1185
|
+
QUEUED: "queued",
|
|
1186
|
+
AUTHENTICATING: "authenticating",
|
|
1187
|
+
AUTHENTICATED: "authenticated",
|
|
1188
|
+
FAILED: "failed",
|
|
1189
|
+
CANCELLED: "cancelled",
|
|
1190
|
+
});
|
|
1191
|
+
const _ssogovPTrans = new Map([
|
|
1192
|
+
[
|
|
1193
|
+
SSOGOV_PROFILE_MATURITY_V2.PENDING,
|
|
1194
|
+
new Set([
|
|
1195
|
+
SSOGOV_PROFILE_MATURITY_V2.ACTIVE,
|
|
1196
|
+
SSOGOV_PROFILE_MATURITY_V2.ARCHIVED,
|
|
1197
|
+
]),
|
|
1198
|
+
],
|
|
1199
|
+
[
|
|
1200
|
+
SSOGOV_PROFILE_MATURITY_V2.ACTIVE,
|
|
1201
|
+
new Set([
|
|
1202
|
+
SSOGOV_PROFILE_MATURITY_V2.SUSPENDED,
|
|
1203
|
+
SSOGOV_PROFILE_MATURITY_V2.ARCHIVED,
|
|
1204
|
+
]),
|
|
1205
|
+
],
|
|
1206
|
+
[
|
|
1207
|
+
SSOGOV_PROFILE_MATURITY_V2.SUSPENDED,
|
|
1208
|
+
new Set([
|
|
1209
|
+
SSOGOV_PROFILE_MATURITY_V2.ACTIVE,
|
|
1210
|
+
SSOGOV_PROFILE_MATURITY_V2.ARCHIVED,
|
|
1211
|
+
]),
|
|
1212
|
+
],
|
|
1213
|
+
[SSOGOV_PROFILE_MATURITY_V2.ARCHIVED, new Set()],
|
|
1214
|
+
]);
|
|
1215
|
+
const _ssogovPTerminal = new Set([SSOGOV_PROFILE_MATURITY_V2.ARCHIVED]);
|
|
1216
|
+
const _ssogovJTrans = new Map([
|
|
1217
|
+
[
|
|
1218
|
+
SSOGOV_LOGIN_LIFECYCLE_V2.QUEUED,
|
|
1219
|
+
new Set([
|
|
1220
|
+
SSOGOV_LOGIN_LIFECYCLE_V2.AUTHENTICATING,
|
|
1221
|
+
SSOGOV_LOGIN_LIFECYCLE_V2.CANCELLED,
|
|
1222
|
+
]),
|
|
1223
|
+
],
|
|
1224
|
+
[
|
|
1225
|
+
SSOGOV_LOGIN_LIFECYCLE_V2.AUTHENTICATING,
|
|
1226
|
+
new Set([
|
|
1227
|
+
SSOGOV_LOGIN_LIFECYCLE_V2.AUTHENTICATED,
|
|
1228
|
+
SSOGOV_LOGIN_LIFECYCLE_V2.FAILED,
|
|
1229
|
+
SSOGOV_LOGIN_LIFECYCLE_V2.CANCELLED,
|
|
1230
|
+
]),
|
|
1231
|
+
],
|
|
1232
|
+
[SSOGOV_LOGIN_LIFECYCLE_V2.AUTHENTICATED, new Set()],
|
|
1233
|
+
[SSOGOV_LOGIN_LIFECYCLE_V2.FAILED, new Set()],
|
|
1234
|
+
[SSOGOV_LOGIN_LIFECYCLE_V2.CANCELLED, new Set()],
|
|
1235
|
+
]);
|
|
1236
|
+
const _ssogovPsV2 = new Map();
|
|
1237
|
+
const _ssogovJsV2 = new Map();
|
|
1238
|
+
let _ssogovMaxActive = 8,
|
|
1239
|
+
_ssogovMaxPending = 30,
|
|
1240
|
+
_ssogovIdleMs = 30 * 24 * 60 * 60 * 1000,
|
|
1241
|
+
_ssogovStuckMs = 60 * 1000;
|
|
1242
|
+
function _ssogovPos(n, label) {
|
|
1243
|
+
const v = Math.floor(Number(n));
|
|
1244
|
+
if (!Number.isFinite(v) || v <= 0)
|
|
1245
|
+
throw new Error(`${label} must be positive integer`);
|
|
1246
|
+
return v;
|
|
1247
|
+
}
|
|
1248
|
+
function _ssogovCheckP(from, to) {
|
|
1249
|
+
const a = _ssogovPTrans.get(from);
|
|
1250
|
+
if (!a || !a.has(to))
|
|
1251
|
+
throw new Error(`invalid ssogov profile transition ${from} → ${to}`);
|
|
1252
|
+
}
|
|
1253
|
+
function _ssogovCheckJ(from, to) {
|
|
1254
|
+
const a = _ssogovJTrans.get(from);
|
|
1255
|
+
if (!a || !a.has(to))
|
|
1256
|
+
throw new Error(`invalid ssogov login transition ${from} → ${to}`);
|
|
1257
|
+
}
|
|
1258
|
+
function _ssogovCountActive(owner) {
|
|
1259
|
+
let c = 0;
|
|
1260
|
+
for (const p of _ssogovPsV2.values())
|
|
1261
|
+
if (p.owner === owner && p.status === SSOGOV_PROFILE_MATURITY_V2.ACTIVE)
|
|
1262
|
+
c++;
|
|
1263
|
+
return c;
|
|
1264
|
+
}
|
|
1265
|
+
function _ssogovCountPending(profileId) {
|
|
1266
|
+
let c = 0;
|
|
1267
|
+
for (const j of _ssogovJsV2.values())
|
|
1268
|
+
if (
|
|
1269
|
+
j.profileId === profileId &&
|
|
1270
|
+
(j.status === SSOGOV_LOGIN_LIFECYCLE_V2.QUEUED ||
|
|
1271
|
+
j.status === SSOGOV_LOGIN_LIFECYCLE_V2.AUTHENTICATING)
|
|
1272
|
+
)
|
|
1273
|
+
c++;
|
|
1274
|
+
return c;
|
|
1275
|
+
}
|
|
1276
|
+
export function setMaxActiveSsogovProfilesPerOwnerV2(n) {
|
|
1277
|
+
_ssogovMaxActive = _ssogovPos(n, "maxActiveSsogovProfilesPerOwner");
|
|
1278
|
+
}
|
|
1279
|
+
export function getMaxActiveSsogovProfilesPerOwnerV2() {
|
|
1280
|
+
return _ssogovMaxActive;
|
|
1281
|
+
}
|
|
1282
|
+
export function setMaxPendingSsogovLoginsPerProfileV2(n) {
|
|
1283
|
+
_ssogovMaxPending = _ssogovPos(n, "maxPendingSsogovLoginsPerProfile");
|
|
1284
|
+
}
|
|
1285
|
+
export function getMaxPendingSsogovLoginsPerProfileV2() {
|
|
1286
|
+
return _ssogovMaxPending;
|
|
1287
|
+
}
|
|
1288
|
+
export function setSsogovProfileIdleMsV2(n) {
|
|
1289
|
+
_ssogovIdleMs = _ssogovPos(n, "ssogovProfileIdleMs");
|
|
1290
|
+
}
|
|
1291
|
+
export function getSsogovProfileIdleMsV2() {
|
|
1292
|
+
return _ssogovIdleMs;
|
|
1293
|
+
}
|
|
1294
|
+
export function setSsogovLoginStuckMsV2(n) {
|
|
1295
|
+
_ssogovStuckMs = _ssogovPos(n, "ssogovLoginStuckMs");
|
|
1296
|
+
}
|
|
1297
|
+
export function getSsogovLoginStuckMsV2() {
|
|
1298
|
+
return _ssogovStuckMs;
|
|
1299
|
+
}
|
|
1300
|
+
export function _resetStateSsoManagerGovV2() {
|
|
1301
|
+
_ssogovPsV2.clear();
|
|
1302
|
+
_ssogovJsV2.clear();
|
|
1303
|
+
_ssogovMaxActive = 8;
|
|
1304
|
+
_ssogovMaxPending = 30;
|
|
1305
|
+
_ssogovIdleMs = 30 * 24 * 60 * 60 * 1000;
|
|
1306
|
+
_ssogovStuckMs = 60 * 1000;
|
|
1307
|
+
}
|
|
1308
|
+
export function registerSsogovProfileV2({
|
|
1309
|
+
id,
|
|
1310
|
+
owner,
|
|
1311
|
+
protocol,
|
|
1312
|
+
metadata,
|
|
1313
|
+
} = {}) {
|
|
1314
|
+
if (!id || !owner) throw new Error("id and owner required");
|
|
1315
|
+
if (_ssogovPsV2.has(id))
|
|
1316
|
+
throw new Error(`ssogov profile ${id} already exists`);
|
|
1317
|
+
const now = Date.now();
|
|
1318
|
+
const p = {
|
|
1319
|
+
id,
|
|
1320
|
+
owner,
|
|
1321
|
+
protocol: protocol || "oidc",
|
|
1322
|
+
status: SSOGOV_PROFILE_MATURITY_V2.PENDING,
|
|
1323
|
+
createdAt: now,
|
|
1324
|
+
updatedAt: now,
|
|
1325
|
+
lastTouchedAt: now,
|
|
1326
|
+
activatedAt: null,
|
|
1327
|
+
archivedAt: null,
|
|
1328
|
+
metadata: { ...(metadata || {}) },
|
|
1329
|
+
};
|
|
1330
|
+
_ssogovPsV2.set(id, p);
|
|
1331
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
1332
|
+
}
|
|
1333
|
+
export function activateSsogovProfileV2(id) {
|
|
1334
|
+
const p = _ssogovPsV2.get(id);
|
|
1335
|
+
if (!p) throw new Error(`ssogov profile ${id} not found`);
|
|
1336
|
+
const isInitial = p.status === SSOGOV_PROFILE_MATURITY_V2.PENDING;
|
|
1337
|
+
_ssogovCheckP(p.status, SSOGOV_PROFILE_MATURITY_V2.ACTIVE);
|
|
1338
|
+
if (isInitial && _ssogovCountActive(p.owner) >= _ssogovMaxActive)
|
|
1339
|
+
throw new Error(`max active ssogov profiles for owner ${p.owner} reached`);
|
|
1340
|
+
const now = Date.now();
|
|
1341
|
+
p.status = SSOGOV_PROFILE_MATURITY_V2.ACTIVE;
|
|
1342
|
+
p.updatedAt = now;
|
|
1343
|
+
p.lastTouchedAt = now;
|
|
1344
|
+
if (!p.activatedAt) p.activatedAt = now;
|
|
1345
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
1346
|
+
}
|
|
1347
|
+
export function suspendSsogovProfileV2(id) {
|
|
1348
|
+
const p = _ssogovPsV2.get(id);
|
|
1349
|
+
if (!p) throw new Error(`ssogov profile ${id} not found`);
|
|
1350
|
+
_ssogovCheckP(p.status, SSOGOV_PROFILE_MATURITY_V2.SUSPENDED);
|
|
1351
|
+
p.status = SSOGOV_PROFILE_MATURITY_V2.SUSPENDED;
|
|
1352
|
+
p.updatedAt = Date.now();
|
|
1353
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
1354
|
+
}
|
|
1355
|
+
export function archiveSsogovProfileV2(id) {
|
|
1356
|
+
const p = _ssogovPsV2.get(id);
|
|
1357
|
+
if (!p) throw new Error(`ssogov profile ${id} not found`);
|
|
1358
|
+
_ssogovCheckP(p.status, SSOGOV_PROFILE_MATURITY_V2.ARCHIVED);
|
|
1359
|
+
const now = Date.now();
|
|
1360
|
+
p.status = SSOGOV_PROFILE_MATURITY_V2.ARCHIVED;
|
|
1361
|
+
p.updatedAt = now;
|
|
1362
|
+
if (!p.archivedAt) p.archivedAt = now;
|
|
1363
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
1364
|
+
}
|
|
1365
|
+
export function touchSsogovProfileV2(id) {
|
|
1366
|
+
const p = _ssogovPsV2.get(id);
|
|
1367
|
+
if (!p) throw new Error(`ssogov profile ${id} not found`);
|
|
1368
|
+
if (_ssogovPTerminal.has(p.status))
|
|
1369
|
+
throw new Error(`cannot touch terminal ssogov profile ${id}`);
|
|
1370
|
+
const now = Date.now();
|
|
1371
|
+
p.lastTouchedAt = now;
|
|
1372
|
+
p.updatedAt = now;
|
|
1373
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
1374
|
+
}
|
|
1375
|
+
export function getSsogovProfileV2(id) {
|
|
1376
|
+
const p = _ssogovPsV2.get(id);
|
|
1377
|
+
if (!p) return null;
|
|
1378
|
+
return { ...p, metadata: { ...p.metadata } };
|
|
1379
|
+
}
|
|
1380
|
+
export function listSsogovProfilesV2() {
|
|
1381
|
+
return [..._ssogovPsV2.values()].map((p) => ({
|
|
1382
|
+
...p,
|
|
1383
|
+
metadata: { ...p.metadata },
|
|
1384
|
+
}));
|
|
1385
|
+
}
|
|
1386
|
+
export function createSsogovLoginV2({ id, profileId, subject, metadata } = {}) {
|
|
1387
|
+
if (!id || !profileId) throw new Error("id and profileId required");
|
|
1388
|
+
if (_ssogovJsV2.has(id)) throw new Error(`ssogov login ${id} already exists`);
|
|
1389
|
+
if (!_ssogovPsV2.has(profileId))
|
|
1390
|
+
throw new Error(`ssogov profile ${profileId} not found`);
|
|
1391
|
+
if (_ssogovCountPending(profileId) >= _ssogovMaxPending)
|
|
1392
|
+
throw new Error(
|
|
1393
|
+
`max pending ssogov logins for profile ${profileId} reached`,
|
|
1394
|
+
);
|
|
1395
|
+
const now = Date.now();
|
|
1396
|
+
const j = {
|
|
1397
|
+
id,
|
|
1398
|
+
profileId,
|
|
1399
|
+
subject: subject || "",
|
|
1400
|
+
status: SSOGOV_LOGIN_LIFECYCLE_V2.QUEUED,
|
|
1401
|
+
createdAt: now,
|
|
1402
|
+
updatedAt: now,
|
|
1403
|
+
startedAt: null,
|
|
1404
|
+
settledAt: null,
|
|
1405
|
+
metadata: { ...(metadata || {}) },
|
|
1406
|
+
};
|
|
1407
|
+
_ssogovJsV2.set(id, j);
|
|
1408
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
1409
|
+
}
|
|
1410
|
+
export function authenticatingSsogovLoginV2(id) {
|
|
1411
|
+
const j = _ssogovJsV2.get(id);
|
|
1412
|
+
if (!j) throw new Error(`ssogov login ${id} not found`);
|
|
1413
|
+
_ssogovCheckJ(j.status, SSOGOV_LOGIN_LIFECYCLE_V2.AUTHENTICATING);
|
|
1414
|
+
const now = Date.now();
|
|
1415
|
+
j.status = SSOGOV_LOGIN_LIFECYCLE_V2.AUTHENTICATING;
|
|
1416
|
+
j.updatedAt = now;
|
|
1417
|
+
if (!j.startedAt) j.startedAt = now;
|
|
1418
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
1419
|
+
}
|
|
1420
|
+
export function completeLoginSsogovV2(id) {
|
|
1421
|
+
const j = _ssogovJsV2.get(id);
|
|
1422
|
+
if (!j) throw new Error(`ssogov login ${id} not found`);
|
|
1423
|
+
_ssogovCheckJ(j.status, SSOGOV_LOGIN_LIFECYCLE_V2.AUTHENTICATED);
|
|
1424
|
+
const now = Date.now();
|
|
1425
|
+
j.status = SSOGOV_LOGIN_LIFECYCLE_V2.AUTHENTICATED;
|
|
1426
|
+
j.updatedAt = now;
|
|
1427
|
+
if (!j.settledAt) j.settledAt = now;
|
|
1428
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
1429
|
+
}
|
|
1430
|
+
export function failSsogovLoginV2(id, reason) {
|
|
1431
|
+
const j = _ssogovJsV2.get(id);
|
|
1432
|
+
if (!j) throw new Error(`ssogov login ${id} not found`);
|
|
1433
|
+
_ssogovCheckJ(j.status, SSOGOV_LOGIN_LIFECYCLE_V2.FAILED);
|
|
1434
|
+
const now = Date.now();
|
|
1435
|
+
j.status = SSOGOV_LOGIN_LIFECYCLE_V2.FAILED;
|
|
1436
|
+
j.updatedAt = now;
|
|
1437
|
+
if (!j.settledAt) j.settledAt = now;
|
|
1438
|
+
if (reason) j.metadata.failReason = String(reason);
|
|
1439
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
1440
|
+
}
|
|
1441
|
+
export function cancelSsogovLoginV2(id, reason) {
|
|
1442
|
+
const j = _ssogovJsV2.get(id);
|
|
1443
|
+
if (!j) throw new Error(`ssogov login ${id} not found`);
|
|
1444
|
+
_ssogovCheckJ(j.status, SSOGOV_LOGIN_LIFECYCLE_V2.CANCELLED);
|
|
1445
|
+
const now = Date.now();
|
|
1446
|
+
j.status = SSOGOV_LOGIN_LIFECYCLE_V2.CANCELLED;
|
|
1447
|
+
j.updatedAt = now;
|
|
1448
|
+
if (!j.settledAt) j.settledAt = now;
|
|
1449
|
+
if (reason) j.metadata.cancelReason = String(reason);
|
|
1450
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
1451
|
+
}
|
|
1452
|
+
export function getSsogovLoginV2(id) {
|
|
1453
|
+
const j = _ssogovJsV2.get(id);
|
|
1454
|
+
if (!j) return null;
|
|
1455
|
+
return { ...j, metadata: { ...j.metadata } };
|
|
1456
|
+
}
|
|
1457
|
+
export function listSsogovLoginsV2() {
|
|
1458
|
+
return [..._ssogovJsV2.values()].map((j) => ({
|
|
1459
|
+
...j,
|
|
1460
|
+
metadata: { ...j.metadata },
|
|
1461
|
+
}));
|
|
1462
|
+
}
|
|
1463
|
+
export function autoSuspendIdleSsogovProfilesV2({ now } = {}) {
|
|
1464
|
+
const t = now ?? Date.now();
|
|
1465
|
+
const flipped = [];
|
|
1466
|
+
for (const p of _ssogovPsV2.values())
|
|
1467
|
+
if (
|
|
1468
|
+
p.status === SSOGOV_PROFILE_MATURITY_V2.ACTIVE &&
|
|
1469
|
+
t - p.lastTouchedAt >= _ssogovIdleMs
|
|
1470
|
+
) {
|
|
1471
|
+
p.status = SSOGOV_PROFILE_MATURITY_V2.SUSPENDED;
|
|
1472
|
+
p.updatedAt = t;
|
|
1473
|
+
flipped.push(p.id);
|
|
1474
|
+
}
|
|
1475
|
+
return { flipped, count: flipped.length };
|
|
1476
|
+
}
|
|
1477
|
+
export function autoFailStuckSsogovLoginsV2({ now } = {}) {
|
|
1478
|
+
const t = now ?? Date.now();
|
|
1479
|
+
const flipped = [];
|
|
1480
|
+
for (const j of _ssogovJsV2.values())
|
|
1481
|
+
if (
|
|
1482
|
+
j.status === SSOGOV_LOGIN_LIFECYCLE_V2.AUTHENTICATING &&
|
|
1483
|
+
j.startedAt != null &&
|
|
1484
|
+
t - j.startedAt >= _ssogovStuckMs
|
|
1485
|
+
) {
|
|
1486
|
+
j.status = SSOGOV_LOGIN_LIFECYCLE_V2.FAILED;
|
|
1487
|
+
j.updatedAt = t;
|
|
1488
|
+
if (!j.settledAt) j.settledAt = t;
|
|
1489
|
+
j.metadata.failReason = "auto-fail-stuck";
|
|
1490
|
+
flipped.push(j.id);
|
|
1491
|
+
}
|
|
1492
|
+
return { flipped, count: flipped.length };
|
|
1493
|
+
}
|
|
1494
|
+
export function getSsoManagerGovStatsV2() {
|
|
1495
|
+
const profilesByStatus = {};
|
|
1496
|
+
for (const v of Object.values(SSOGOV_PROFILE_MATURITY_V2))
|
|
1497
|
+
profilesByStatus[v] = 0;
|
|
1498
|
+
for (const p of _ssogovPsV2.values()) profilesByStatus[p.status]++;
|
|
1499
|
+
const loginsByStatus = {};
|
|
1500
|
+
for (const v of Object.values(SSOGOV_LOGIN_LIFECYCLE_V2))
|
|
1501
|
+
loginsByStatus[v] = 0;
|
|
1502
|
+
for (const j of _ssogovJsV2.values()) loginsByStatus[j.status]++;
|
|
1503
|
+
return {
|
|
1504
|
+
totalSsogovProfilesV2: _ssogovPsV2.size,
|
|
1505
|
+
totalSsogovLoginsV2: _ssogovJsV2.size,
|
|
1506
|
+
maxActiveSsogovProfilesPerOwner: _ssogovMaxActive,
|
|
1507
|
+
maxPendingSsogovLoginsPerProfile: _ssogovMaxPending,
|
|
1508
|
+
ssogovProfileIdleMs: _ssogovIdleMs,
|
|
1509
|
+
ssogovLoginStuckMs: _ssogovStuckMs,
|
|
1510
|
+
profilesByStatus,
|
|
1511
|
+
loginsByStatus,
|
|
1512
|
+
};
|
|
1513
|
+
}
|