-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathpackage.json
659 lines (659 loc) · 27.9 KB
/
package.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
{
"name": "mlxprs",
"displayName": "MLXPRS: MarkLogic Extension for VS Code",
"description": "Simplifies and automates common development tasks for creating applications on MarkLogic.",
"version": "3.9.1",
"publisher": "mlxprs",
"engines": {
"vscode": "^1.78.0"
},
"icon": "images/ProgressMarkLogic_PrimaryLogo_StackedAlternate.png",
"galleryBanner": {
"color": "#1D252D",
"theme": "dark"
},
"categories": [
"Debuggers",
"Programming Languages",
"Snippets",
"Other"
],
"repository": "https://github.com/marklogic/mlxprs",
"license": "(Apache-2.0 AND MIT)",
"activationEvents": [
"onCommand:extension.getQuery",
"onCommand:extension.sendXQuery",
"onCommand:extension.sendJSQuery",
"onCommand:extension.sendSql",
"onCommand:extension.sendSparqlQuery",
"onCommand:extension.showModule",
"onCommand:extension.runTestModule",
"onDebug",
"onLanguage:xquery-ml",
"onLanguage:javascript",
"onLanguage:sparql",
"mlxprs.showConnectedServers"
],
"main": "./dist/extension",
"contributes": {
"viewsContainers": {
"panel": [
{
"id": "mlxprsContainer",
"title": "MLXPRS",
"icon": "images/ProgressMarkLogic_PrimaryLogo_StackedAlternate.png"
}
],
"activitybar": [
{
"id": "marklogic-activity-bar",
"title": "MarkLogic Server Explorer",
"icon": "media/Progress_PrimarySymbol.svg"
}
]
},
"views": {
"marklogic-activity-bar": [
{
"id": "markLogicServerStatus",
"name": "MarkLogic Server Configuration",
"icon": "media/Progress_PrimarySymbol.svg",
"contextualTitle": "MarkLogic Server Explorer"
},
{
"id": "markLogicDebugStatus",
"name": "MarkLogic App Server Debug Status",
"icon": "media/Progress_PrimarySymbol.svg",
"contextualTitle": "MarkLogic App Server Debug Status"
}
],
"mlxprsContainer": [
{
"type": "webview",
"id": "mlxprs.ResultsView",
"name": "Results"
}
]
},
"commands": [
{
"command": "extension.sendXQuery",
"title": "MarkLogic: Eval XQuery"
},
{
"command": "extension.sendJSQuery",
"title": "MarkLogic: Eval JS"
},
{
"command": "extension.sendSqlQuery",
"title": "MarkLogic: Eval SQL"
},
{
"command": "extension.sendSparqlQuery",
"title": "MarkLogic: Eval SPARQL"
},
{
"command": "extension.sendRowsJsonQuery",
"title": "MarkLogic: Submit Optic Query - Return JSON"
},
{
"command": "extension.sendRowsCsvQuery",
"title": "MarkLogic: Submit Optic Query - Return CSV"
},
{
"command": "extension.sendRowsXmlQuery",
"title": "MarkLogic: Submit Optic Query - Return XML"
},
{
"command": "extension.sendGraphQlQuery",
"title": "MarkLogic: Submit GraphQL Query"
},
{
"command": "extension.connectJsServer",
"title": "MarkLogic: Connect JavaScript Debug Server"
},
{
"command": "extension.disconnectJsServer",
"title": "MarkLogic: Disconnect JavaScript Debug Server"
},
{
"command": "extension.connectXqyServer",
"title": "MarkLogic: Connect XQuery Debug Server"
},
{
"command": "extension.disconnectXqyServer",
"title": "MarkLogic: Disconnect XQuery Debug Server"
},
{
"command": "extension.showModule",
"title": "MarkLogic: Show Module"
},
{
"command": "extension.runTestModule",
"title": "MarkLogic: Run marklogic-unit-test Module"
},
{
"command": "extension.validateTdeTemplate",
"title": "MarkLogic: Validate TDE Template"
},
{
"command": "extension.tdeExtractNodes",
"title": "MarkLogic: Extract Data Via TDE"
}
],
"breakpoints": [
{
"language": "javascript"
},
{
"language": "xquery-ml"
}
],
"debuggers": [
{
"type": "ml-jsdebugger",
"label": "MarkLogic JS Debugger",
"program": "./dist/jsDebug.js",
"runtime": "node",
"configurationAttributes": {
"launch": {
"required": [ ],
"properties": {
"path": {
"type": "string",
"description": "DEPRECATED: please use 'program'. 'path' will be removed in a future version",
"default": ""
},
"program": {
"type": "string",
"description": "path to main module to launch in debugging mode.",
"default": ""
},
"txnId": {
"type": "string",
"description": "Transaction ID to use with launch.",
"default": ""
},
"root": {
"type": "string",
"description": "local path corresponding to the root directory for the modules deployed on MarkLogic.",
"default": "${workspaceFolder}/src/main/ml-modules/root"
}
}
},
"attach": {
"required": [
"root",
"debugServerName"
],
"properties": {
"path": {
"type": "string",
"description": "DEPRECATED: please use 'root'. 'path' will be removed in a future version.",
"default": ""
},
"root": {
"type": "string",
"description": "local path corresponding to the root directory for the modules deployed on MarkLogic.",
"default": "${workspaceFolder}/src/main/ml-modules/root"
},
"debugServerName": {
"type": "string",
"description": "Debug server name, please connect the server before use",
"default": ""
},
"rid": {
"type": "string",
"description": "Request Id",
"default": ""
}
}
}
},
"initialConfigurations": [
{
"type": "ml-jsdebugger",
"request": "launch",
"name": "Evaluate Current JavaScript Module",
"root": "${workspaceFolder}/src/main/ml-modules/root"
},
{
"type": "ml-jsdebugger",
"request": "attach",
"name": "Attach to Remote JavaScript Request",
"path": "${workspaceFolder}/src/main/ml-modules/root",
"debugServerName": "Enter debug server name"
}
],
"configurationSnippets": [
{
"label": "MarkLogic: Evaluate Current JavaScript Module",
"description": "A new configuration for 'debugging' a user selected javascript file.",
"body": {
"type": "ml-jsdebugger",
"request": "launch",
"name": "Evaluate Current JavaScript Module",
"root": "^\"\\${workspaceFolder}/src/main/ml-modules/root\""
}
},
{
"label": "MarkLogic: Attach to Remote JavaScript Request",
"description": "A new configuration for 'debugging' a user selected javascript file.",
"body": {
"type": "ml-jsdebugger",
"request": "attach",
"name": "Attach to Remote JavaScript Request",
"root": "^\"\\${workspaceFolder}/src/main/ml-modules/root\"",
"debugServerName": "data-hub-STAGING"
}
}
],
"variables": { }
},
{
"type": "xquery-ml",
"label": "MarkLogic XQY Debugger",
"program": "./dist/xqyDebug.js",
"runtime": "node",
"configurationAttributes": {
"launch": {
"required": [
"root"
],
"properties": {
"program": {
"type": "string",
"description": "Absolute path to the local XQuery source code to evaluate in debug mode. If left blank, the current open buffer will be used.",
"default": ""
},
"root": {
"type": "string",
"description": "local path corresponding to the root directory for the modules deployed on MarkLogic.",
"default": "${workspaceFolder}/src/main/ml-modules/root"
}
}
},
"attach": {
"properties": {
"required": [
"root"
],
"program": {
"type": "string",
"description": "In attach mode, this will be the full path to a local source file representing the eval'd ad-hoc query (if present) in MarkLogic.",
"default": ""
},
"root": {
"type": "string",
"description": "local path corresponding to the root directory for the modules deployed on MarkLogic.",
"default": "${workspaceFolder}/src/main/ml-modules/root"
},
"rid": {
"type": "string",
"description": "Request Id to attach to. You will be prompted to choose one if none is provided.",
"default": ""
}
}
}
},
"initialConfigurations": [
{
"type": "xquery-ml",
"request": "launch",
"name": "Ask for file name: ",
"program": "",
"stopOnEntry": true
},
{
"type": "xquery-ml",
"request": "attach",
"name": "Ask for file name: ",
"stopOnEntry": true
}
],
"configurationSnippets": [
{
"label": "MarkLogic: Evaluate Current XQuery Module",
"description": "Launch an XQuery request in debug mode",
"body": {
"type": "xquery-ml",
"request": "launch",
"name": "Launch XQuery Debug Request",
"root": "^\"\\${workspaceFolder}/src/main/ml-modules/root\""
}
},
{
"label": "MarkLogic: Attach to Remote XQuery Request",
"description": "Attach to a request to debug on a connected app server",
"body": {
"type": "xquery-ml",
"request": "attach",
"name": "Attach XQuery Debug Request",
"root": "^\"\\${workspaceFolder}/src/main/ml-modules/root\""
}
}
],
"variables": {
"AskForUsername": "extension.mock-debug.getUsername",
"AskForPassword": "extension.mock-debug.getPassword"
}
}
],
"configuration": [
{
"id": "marklogicGeneral",
"order": 1,
"type": "object",
"title": "MarkLogic General Configuration",
"properties": {
"marklogic.host": {
"type": "string",
"order": 1,
"description": "hostname for MarkLogic instance",
"default": "localhost"
},
"marklogic.managePort": {
"order": 2,
"type": "integer",
"default": 8002,
"description": "MarkLogic Manage AppServer port"
},
"marklogic.manageBasePath": {
"order": 3,
"type": "string",
"default": "",
"description": "MarkLogic Manage AppServer path when using MarkLogic Cloud or behind a reverse proxy"
},
"marklogic.adminPort": {
"order": 4,
"type": "integer",
"default": 8001,
"description": "MarkLogic Admin AppServer port"
},
"marklogic.adminBasePath": {
"order": 5,
"type": "string",
"default": "",
"description": "MarkLogic Admin AppServer path when using MarkLogic Cloud or behind a reverse proxy"
},
"marklogic.port": {
"order": 6,
"type": "integer",
"default": 8000,
"description": "The port of a REST API app server to connect to"
},
"marklogic.restBasePath": {
"order": 7,
"type": "string",
"default": "",
"description": "The REST API app server path when using MarkLogic Cloud or behind a reverse proxy"
},
"marklogic.testPort": {
"order": 8,
"type": "integer",
"default": 8004,
"description": "Optional port for a REST API server that supports running marklogic-unit-test modules"
},
"marklogic.testBasePath": {
"order": 9,
"type": "string",
"default": "",
"description": "Optional, REST API server path that supports running marklogic-unit-test modules when using MarkLogic Cloud or behind a reverse proxy"
},
"marklogic.documentsDb": {
"order": 10,
"type": "string",
"default": "",
"description": "database against which to evaluate queries; required for debugging a local script"
},
"marklogic.modulesDb": {
"order": 11,
"type": "string",
"default": "",
"description": "modules database used in queries; default modules database for app server will be used if left unspecified"
},
"marklogic.modulesRoot": {
"order": 12,
"type": "string",
"default": "/",
"description": "modules root if using filesystem"
}
}
},
{
"id": "marklogicSecurity",
"order": 2,
"type": "object",
"title": "MarkLogic Security Configuration",
"properties": {
"marklogic.authType": {
"order": 1,
"type": "string",
"default": "DIGEST",
"description": "only DIGEST, BASIC, or CLOUD for now"
},
"marklogic.username": {
"order": 2,
"type": "string",
"default": "admin",
"description": "username for MarkLogic connection"
},
"marklogic.password": {
"order": 3,
"type": "string",
"default": "admin",
"description": "password for MarkLogic connection"
},
"marklogic.apiKey": {
"order": 4,
"type": "string",
"default": "",
"description": "API Key for a MarkLogic Cloud connection"
},
"marklogic.pathToCa": {
"order": 5,
"type": "string",
"default": "",
"description": "path to certificate authority (e.g. for self-signed certificates)"
},
"marklogic.ssl": {
"order": 6,
"type": "boolean",
"default": false,
"description": "whether to use ssl for the http connection"
},
"marklogic.rejectUnauthorized": {
"order": 7,
"type": "boolean",
"default": true,
"description": "whether the server's SSL certificate should be verified against the list of supplied certificate authories"
}
}
},
{
"id": "marklogicMiscellaneous",
"order": 3,
"type": "object",
"title": "MarkLogic Miscellaneous Configuration",
"properties": {
"marklogic.resultsInEditorTab": {
"order": 1,
"type": "boolean",
"default": false,
"description": "Display query results in a separate editor."
},
"marklogic.sparqlSelectResponseType": {
"order": 2,
"type": "string",
"enum": [
"application/sparql-results+json",
"application/sparql-results+xml",
"text/html",
"text/csv"
],
"default": "application/sparql-results+json",
"description": "How to format SPARQL SELECT query results"
},
"marklogic.sparqlGraphResponseType": {
"order": 3,
"type": "string",
"enum": [
"text/turtle",
"text/n3",
"application/n-triples",
"application/n-quads",
"application/rdf+json",
"application/rdf+xml"
],
"default": "text/turtle",
"description": "How to format SPARQL CONSTRUCT and DESCRIBE query results"
},
"marklogic.sparqlAskResponseType": {
"order": 4,
"type": "string",
"enum": [
"application/sparql-results+json",
"application/sparql-results+xml",
"text/html"
],
"default": "application/sparql-results+json",
"description": "How to format SPARQL ASK query results"
},
"marklogic.sql.optimize": {
"order": 5,
"type": "number",
"enum": [
0,
1,
2
],
"default": 1,
"description": "Optimization Levels of 0 (off), 1, and 2 are recognized."
},
"marklogic.sql.results": {
"order": 6,
"type": "string",
"markdownDescription": "How to present SQL results from 'Eval SQL'",
"enum": [
"array",
"format",
"map"
],
"markdownEnumDescriptions": [
"Return SQL results as a sequence of array values (`json:array`).",
"Return SQL results as formatted strings.",
"Return SQL result as a sequence of map values, where the key is the column name."
],
"default": "array"
}
}
}
],
"languages": [
{
"id": "xquery-ml",
"aliases": [
"XQuery (ML)",
"xquery-ml"
],
"extensions": [
".xq",
".xql",
".xqm",
".xqy",
".xquery"
],
"configuration": "./xquery-ml.configuration.json"
},
{
"id": "javascript",
"extensions": [
".sjs"
]
}
],
"grammars": [
{
"language": "xquery-ml",
"scopeName": "source.xquery-ml",
"path": "./syntaxes/xquery-ml.tmLanguage"
}
],
"snippets": [
{
"language": "xquery-ml",
"path": "./snippets/snippets.json"
}
]
},
"scripts": {
"cleanAll": "rimraf node_modules/ .vscode-test/ dist/ server/dist/ server/node_modules/ server/out/ coverage/ mlxprs-${version}.vsix",
"installAll": "npm install && cd server && npm install && cd ..",
"testAll": "npm run test && npm run testServer && npm run testIntegration",
"copy-files": "npm run copy-files --prefix server",
"clean": "rimraf dist out server/dist server/out",
"vscode:prepublish": "webpack --mode production && webpack --mode production --config ./server/webpack.config.js",
"compile": "npm run clean && webpack --mode none && webpack --mode none --config ./server/webpack.config.js",
"pretest": "rimraf dist && tsc -p tsconfig.json && webpack --mode development --config webpack.test.js",
"pretest-server": "tsc -p server/tsconfig.json && npm run copy-files",
"predebug": "npm run clean && npm run copy-files --prefix server && tsc -b server && tsc -b -w .",
"test": "node dist/test/runTest.js --full-trace",
"testIntegration": "node dist/test/runIntegrationTest.js --full-trace",
"testServer": "npm run pretest-server && node server/dist/test/runTest.js --full-trace",
"watch": "webpack --mode none --watch & webpack --mode none --watch --config ./server/webpack.config.js",
"lint": "eslint client/ server/ --ext .ts --ext .js --ext .sjs",
"lintFix": "eslint client/ server/ --ext .ts --ext .js --ext .sjs --fix",
"coverage": "c8 npm run testIntegration",
"coverageAll": "c8 npm run test && c8 npm run testServer && c8 npm run testIntegration"
},
"dependenciesComments": {
"webpackProblem": "Something with version 5.95.0 is breaking the integration tests (and other things?).",
"webpackFix": "I believe this will require upgrading the @types/node and will not be trivial.",
"@types/vscode": "This needs to match the value at the top of this file in 'engines.vscode`",
"possiblyUnused": {
"comment": "I'm not sure about these four packages. Without them, there seem to be problems when you attempt to 'attach' or 'launch'.",
"@types/estree": "1.0.5",
"https-proxy-agent": "7.0.4",
"js-yaml": "4.1.0",
"yargs-parser": "21.1.1"
}
},
"devDependencies": {
"@types/esprima": "4.0.6",
"@types/estree": "1.0.5",
"@types/mocha": "10.0.6",
"@types/node": "16.11.7",
"@types/sinon": "17.0.3",
"@types/vscode": "1.78.0",
"@types/webpack": "5.28.5",
"@types/xml2js": "0.4.14",
"@typescript-eslint/eslint-plugin": "7.1.1",
"@typescript-eslint/parser": "7.1.1",
"@vscode/debugadapter-testsupport": "1.65.0",
"@vscode/debugprotocol": "1.65.0",
"@vscode/test-cli": "^0.0.6",
"@vscode/test-electron": "2.3.9",
"c8": "^9.1.0",
"eslint": "8.57.0",
"https-proxy-agent": "7.0.4",
"js-yaml": "4.1.0",
"mocha": "10.3.0",
"rimraf": "5.0.5",
"sinon": "17.0.1",
"webpack": "5.76.1",
"webpack-cli": "5.1.4",
"yargs-parser": "21.1.1"
},
"dependencies": {
"@vscode/debugadapter": "1.65.0",
"await-notify": "1.0.1",
"esprima": "4.0.1",
"fast-xml-parser": "4.4.1",
"marklogic": "3.3.1",
"merge-options": "3.0.4",
"path-to-regexp": "6.3.0",
"ts-loader": "9.5.1",
"vscode-languageclient": "7.0.0",
"xml2js": "0.6.2"
}
}