Skip to content

Commit aee8be5

Browse files
authored
refactor: inline SessionResources type and remove backend-ai-console.d.ts (#5451)
1 parent fc3ff54 commit aee8be5

2 files changed

Lines changed: 37 additions & 39 deletions

File tree

src/lib/backend.ai-client-esm.ts

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,43 @@ Licensed under MIT
99
import CryptoES from 'crypto-es';
1010
//var CryptoES = require("crypto-js"); /* Exclude for ES6 */
1111
import { comparePEP440Versions, isCompatibleMultipleConditions} from './pep440';
12-
import { SessionResources } from '../types/backend-ai-console';
12+
13+
export interface SessionResources {
14+
group_name?: string;
15+
domain?: string;
16+
type?: 'interactive' | 'batch' | 'inference' | 'system';
17+
cluster_mode: 'single-node' | 'multi-node';
18+
cluster_size: number;
19+
maxWaitSeconds: number;
20+
starts_at?: string;
21+
startupCommand?: string;
22+
bootstrap_script?: string;
23+
owner_access_key?: string;
24+
reuseIfExists?: boolean;
25+
config?: {
26+
resources?: {
27+
cpu: number;
28+
mem: string;
29+
[key: string]: number | string;
30+
};
31+
resource_opts?: {
32+
shmem?: string;
33+
allow_fractional_resource_fragmentation?: boolean;
34+
};
35+
mounts?: string[];
36+
mount_ids?: string[];
37+
mount_map?: {
38+
[key: string]: string;
39+
};
40+
environ?: {
41+
[key: string]: string;
42+
};
43+
scaling_group?: string;
44+
preopen_ports?: number[];
45+
agent_list?: string[];
46+
};
47+
}
48+
1349
type requestInfo = {
1450
method: string;
1551
headers: Headers;

src/types/backend-ai-console.d.ts

Lines changed: 0 additions & 38 deletions
This file was deleted.

0 commit comments

Comments
 (0)