@heroku/plugin-compute 0.2.0 → 0.3.1

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.
Files changed (63) hide show
  1. package/lib/commands/compute/create/telemetry-drain.d.ts +20 -0
  2. package/lib/commands/compute/create/telemetry-drain.js +81 -0
  3. package/lib/commands/compute/create/telemetry-drain.js.map +1 -0
  4. package/lib/commands/compute/display/telemetry-drain.d.ts +26 -0
  5. package/lib/commands/compute/display/telemetry-drain.js +77 -0
  6. package/lib/commands/compute/display/telemetry-drain.js.map +1 -0
  7. package/lib/commands/compute/generate.d.ts +5 -0
  8. package/lib/commands/compute/generate.js +6 -0
  9. package/lib/commands/compute/generate.js.map +1 -1
  10. package/lib/commands/compute/{config/get.d.ts → get/config.d.ts} +2 -0
  11. package/lib/commands/compute/{config/get.js → get/config.js} +9 -2
  12. package/lib/commands/compute/get/config.js.map +1 -0
  13. package/lib/commands/compute/{config/list.d.ts → list/config.d.ts} +2 -0
  14. package/lib/commands/compute/{config/list.js → list/config.js} +9 -2
  15. package/lib/commands/compute/list/config.js.map +1 -0
  16. package/lib/commands/compute/list/telemetry-drain.d.ts +20 -0
  17. package/lib/commands/compute/list/telemetry-drain.js +89 -0
  18. package/lib/commands/compute/list/telemetry-drain.js.map +1 -0
  19. package/lib/commands/compute/{config/set.d.ts → set/config.d.ts} +2 -0
  20. package/lib/commands/compute/{config/set.js → set/config.js} +9 -2
  21. package/lib/commands/compute/set/config.js.map +1 -0
  22. package/lib/commands/compute/{config/unset.d.ts → unset/config.d.ts} +2 -0
  23. package/lib/commands/compute/{config/unset.js → unset/config.js} +9 -2
  24. package/lib/commands/compute/unset/config.js.map +1 -0
  25. package/lib/commands/compute/update/telemetry-drain.d.ts +20 -0
  26. package/lib/commands/compute/update/telemetry-drain.js +69 -0
  27. package/lib/commands/compute/update/telemetry-drain.js.map +1 -0
  28. package/lib/shared/computeConfig.js +2 -2
  29. package/lib/shared/computeConfig.js.map +1 -1
  30. package/lib/shared/computeQuery.d.ts +1 -0
  31. package/lib/shared/computeQuery.js +37 -42
  32. package/lib/shared/computeQuery.js.map +1 -1
  33. package/lib/shared/computeTelemetryDrain.d.ts +22 -0
  34. package/lib/shared/computeTelemetryDrain.js +115 -0
  35. package/lib/shared/computeTelemetryDrain.js.map +1 -0
  36. package/lib/shared/herokuProxyApi.d.ts +30 -0
  37. package/lib/shared/herokuProxyApi.js +104 -4
  38. package/lib/shared/herokuProxyApi.js.map +1 -1
  39. package/messages/compute.create.telemetry-drain.md +53 -0
  40. package/messages/compute.display.telemetry-drain.md +19 -0
  41. package/messages/compute.errors.md +43 -1
  42. package/messages/compute.generate.md +8 -0
  43. package/messages/{compute.config.list.md → compute.list.config.md} +3 -3
  44. package/messages/compute.list.telemetry-drain.md +26 -0
  45. package/messages/compute.update.telemetry-drain.md +57 -0
  46. package/npm-shrinkwrap.json +258 -116
  47. package/oclif.manifest.json +484 -128
  48. package/package.json +10 -4
  49. package/schemas/compute-create-telemetry__drain.json +44 -0
  50. package/schemas/compute-display-telemetry__drain.json +54 -0
  51. package/schemas/compute-list-telemetry__drain.json +43 -0
  52. package/schemas/compute-update-telemetry__drain.json +43 -0
  53. package/lib/commands/compute/config/get.js.map +0 -1
  54. package/lib/commands/compute/config/list.js.map +0 -1
  55. package/lib/commands/compute/config/set.js.map +0 -1
  56. package/lib/commands/compute/config/unset.js.map +0 -1
  57. /package/messages/{compute.config.get.md → compute.get.config.md} +0 -0
  58. /package/messages/{compute.config.set.md → compute.set.config.md} +0 -0
  59. /package/messages/{compute.config.unset.md → compute.unset.config.md} +0 -0
  60. /package/schemas/{compute-config-get.json → compute-get-config.json} +0 -0
  61. /package/schemas/{compute-config-list.json → compute-list-config.json} +0 -0
  62. /package/schemas/{compute-config-set.json → compute-set-config.json} +0 -0
  63. /package/schemas/{compute-config-unset.json → compute-unset-config.json} +0 -0
@@ -144,7 +144,11 @@
144
144
  "compute:generate": {
145
145
  "aliases": [],
146
146
  "args": {},
147
- "description": "Creates the app directory under force-app/main/default/platformComputeApps/<name>/ (or\n--output-dir) with a compute metadata file, a Procfile, a project.toml, and\nstarter source in the language you choose with --language. No org is\ncontacted, but this command does fetch the starter source for the chosen\nlanguage from its Heroku AppLink reference app on GitHub, so it requires\noutbound network access.",
147
+ "deprecationOptions": {
148
+ "to": "template generate project",
149
+ "message": "This command will be available as sf template generate project --template compute in version 1.0.0 of plugin-compute."
150
+ },
151
+ "description": "Creates the app directory under force-app/main/default/platformComputeApps/<name>/ (or\n--output-dir) with a compute metadata file, a Procfile, a project.toml, and\nstarter source in the language you choose with --language. No org is\ncontacted, but this command does fetch the starter source for the chosen\nlanguage from its Heroku AppLink reference app on GitHub, so it requires\noutbound network access.\n\nThis command is deprecated but still works. When you move to sf template generate\nproject --template compute, note that --language no longer defaults to node: the\nreplacement's --compute-language flag makes the language an explicit choice.",
148
152
  "examples": [
149
153
  "Scaffold a Node.js compute app named CreditRatingScorer:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer",
150
154
  "Scaffold a Python compute app into a custom directory:\n<%= config.bin %> <%= command.id %> --name ReceiptOcr --language python --output-dir force-app/main/default/platformComputeApps/scorers"
@@ -205,6 +209,7 @@
205
209
  "pluginAlias": "@heroku/plugin-compute",
206
210
  "pluginName": "@heroku/plugin-compute",
207
211
  "pluginType": "core",
212
+ "state": "deprecated",
208
213
  "strict": true,
209
214
  "summary": "Scaffold a new compute app into your Salesforce DX project.",
210
215
  "enableJsonFlag": true,
@@ -370,7 +375,249 @@
370
375
  "scale:compute"
371
376
  ]
372
377
  },
373
- "compute:config:get": {
378
+ "compute:create:telemetry-drain": {
379
+ "aliases": [],
380
+ "args": {},
381
+ "description": "Creates an OpenTelemetry drain that forwards the compute app's logs, metrics,\nand traces to the endpoint you give with --url. Choose which signals to\nforward with --signals and the wire protocol with --transport. Use\nsf compute update telemetry-drain to change a drain later.",
382
+ "examples": [
383
+ "Forward all signals from a compute app to an OTLP/HTTP collector:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --url https://collector.example.com:4318 --target-org my-org",
384
+ "Forward only traces and logs over gRPC, with an auth header:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --url https://collector.example.com:4317 --transport grpc --signals traces,logs --header \"x-api-key=my-key\" --target-org my-org"
385
+ ],
386
+ "flags": {
387
+ "json": {
388
+ "description": "Format output as json.",
389
+ "helpGroup": "GLOBAL",
390
+ "name": "json",
391
+ "allowNo": false,
392
+ "type": "boolean"
393
+ },
394
+ "flags-dir": {
395
+ "helpGroup": "GLOBAL",
396
+ "name": "flags-dir",
397
+ "summary": "Import flag values from a directory.",
398
+ "hasDynamicHelp": false,
399
+ "multiple": false,
400
+ "type": "option"
401
+ },
402
+ "name": {
403
+ "char": "n",
404
+ "env": "COMPUTE_APP_NAME",
405
+ "name": "name",
406
+ "summary": "DeveloperName of the compute app to add the drain to (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
407
+ "hasDynamicHelp": false,
408
+ "multiple": false,
409
+ "type": "option"
410
+ },
411
+ "url": {
412
+ "name": "url",
413
+ "required": true,
414
+ "summary": "Endpoint to forward telemetry to.",
415
+ "hasDynamicHelp": false,
416
+ "multiple": false,
417
+ "type": "option"
418
+ },
419
+ "signals": {
420
+ "name": "signals",
421
+ "summary": "Comma-separated signals to forward: traces, metrics, logs, or all.",
422
+ "default": "all",
423
+ "hasDynamicHelp": false,
424
+ "multiple": false,
425
+ "type": "option"
426
+ },
427
+ "transport": {
428
+ "name": "transport",
429
+ "summary": "Wire protocol to use: http (OTLP over HTTP) or grpc (OTLP over gRPC).",
430
+ "default": "http",
431
+ "hasDynamicHelp": false,
432
+ "multiple": false,
433
+ "type": "option"
434
+ },
435
+ "header": {
436
+ "description": "Repeat the flag to send more than one header. Header values often carry\ncredentials; they are sent to the endpoint and are never printed to the\nterminal, but are included in --json output.",
437
+ "name": "header",
438
+ "summary": "Header to send with each export, as key=value.",
439
+ "hasDynamicHelp": false,
440
+ "multiple": true,
441
+ "type": "option"
442
+ },
443
+ "target-org": {
444
+ "char": "o",
445
+ "name": "target-org",
446
+ "noCacheDefault": true,
447
+ "required": true,
448
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
449
+ "hasDynamicHelp": true,
450
+ "multiple": false,
451
+ "type": "option"
452
+ }
453
+ },
454
+ "hasDynamicHelp": true,
455
+ "hiddenAliases": [],
456
+ "id": "compute:create:telemetry-drain",
457
+ "pluginAlias": "@heroku/plugin-compute",
458
+ "pluginName": "@heroku/plugin-compute",
459
+ "pluginType": "core",
460
+ "strict": true,
461
+ "summary": "Add a telemetry drain to a compute app.",
462
+ "enableJsonFlag": true,
463
+ "requiresProject": false,
464
+ "isESM": true,
465
+ "relativePath": [
466
+ "lib",
467
+ "commands",
468
+ "compute",
469
+ "create",
470
+ "telemetry-drain.js"
471
+ ],
472
+ "aliasPermutations": [],
473
+ "permutations": [
474
+ "compute:create:telemetry-drain",
475
+ "create:compute:telemetry-drain",
476
+ "create:telemetry-drain:compute",
477
+ "compute:telemetry-drain:create",
478
+ "telemetry-drain:compute:create",
479
+ "telemetry-drain:create:compute"
480
+ ]
481
+ },
482
+ "compute:display:telemetry-drain": {
483
+ "aliases": [],
484
+ "args": {
485
+ "id": {
486
+ "name": "id",
487
+ "required": true
488
+ }
489
+ },
490
+ "description": "Shows a single OpenTelemetry drain in full: the compute app it belongs to,\nthe signals it forwards, and its exporter endpoint, transport, and headers.\nUse sf compute list telemetry-drain to find a drain's ID.",
491
+ "examples": [
492
+ "Show the detail of a telemetry drain by its ID:\n<%= config.bin %> <%= command.id %> 01234567-89ab-cdef-0123-456789abcdef --target-org my-org"
493
+ ],
494
+ "flags": {
495
+ "json": {
496
+ "description": "Format output as json.",
497
+ "helpGroup": "GLOBAL",
498
+ "name": "json",
499
+ "allowNo": false,
500
+ "type": "boolean"
501
+ },
502
+ "flags-dir": {
503
+ "helpGroup": "GLOBAL",
504
+ "name": "flags-dir",
505
+ "summary": "Import flag values from a directory.",
506
+ "hasDynamicHelp": false,
507
+ "multiple": false,
508
+ "type": "option"
509
+ },
510
+ "target-org": {
511
+ "char": "o",
512
+ "name": "target-org",
513
+ "noCacheDefault": true,
514
+ "required": true,
515
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
516
+ "hasDynamicHelp": true,
517
+ "multiple": false,
518
+ "type": "option"
519
+ }
520
+ },
521
+ "hasDynamicHelp": true,
522
+ "hiddenAliases": [],
523
+ "id": "compute:display:telemetry-drain",
524
+ "pluginAlias": "@heroku/plugin-compute",
525
+ "pluginName": "@heroku/plugin-compute",
526
+ "pluginType": "core",
527
+ "strict": true,
528
+ "summary": "Show the full detail of a single compute telemetry drain.",
529
+ "enableJsonFlag": true,
530
+ "requiresProject": false,
531
+ "isESM": true,
532
+ "relativePath": [
533
+ "lib",
534
+ "commands",
535
+ "compute",
536
+ "display",
537
+ "telemetry-drain.js"
538
+ ],
539
+ "aliasPermutations": [],
540
+ "permutations": [
541
+ "compute:display:telemetry-drain",
542
+ "display:compute:telemetry-drain",
543
+ "display:telemetry-drain:compute",
544
+ "compute:telemetry-drain:display",
545
+ "telemetry-drain:compute:display",
546
+ "telemetry-drain:display:compute"
547
+ ]
548
+ },
549
+ "compute:get:build-log": {
550
+ "aliases": [],
551
+ "args": {},
552
+ "description": "Fetches the bounded build/compile log (dependency install, slug compile,\nrelease) for the most recent build of a compute app -- useful right after\ndeploy to confirm the build compiled. This is a one-shot fetch of a\nfinished-or-in-progress log, not a live stream; use compute tail runtime-log\nfor the ongoing runtime log.\n\nThis is a read-only, org-mediated lookup by --name (the app's DeveloperName)\n-- the org calls Heroku's Build Info API on your behalf. It doesn't read from\nor require a local Salesforce DX project.",
553
+ "examples": [
554
+ "Print the latest build's log:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --target-org my-org"
555
+ ],
556
+ "flags": {
557
+ "json": {
558
+ "description": "Format output as json.",
559
+ "helpGroup": "GLOBAL",
560
+ "name": "json",
561
+ "allowNo": false,
562
+ "type": "boolean"
563
+ },
564
+ "flags-dir": {
565
+ "helpGroup": "GLOBAL",
566
+ "name": "flags-dir",
567
+ "summary": "Import flag values from a directory.",
568
+ "hasDynamicHelp": false,
569
+ "multiple": false,
570
+ "type": "option"
571
+ },
572
+ "name": {
573
+ "char": "n",
574
+ "env": "COMPUTE_APP_NAME",
575
+ "name": "name",
576
+ "summary": "DeveloperName of the compute app to fetch build output for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
577
+ "hasDynamicHelp": false,
578
+ "multiple": false,
579
+ "type": "option"
580
+ },
581
+ "target-org": {
582
+ "char": "o",
583
+ "name": "target-org",
584
+ "noCacheDefault": true,
585
+ "required": true,
586
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
587
+ "hasDynamicHelp": true,
588
+ "multiple": false,
589
+ "type": "option"
590
+ }
591
+ },
592
+ "hasDynamicHelp": true,
593
+ "hiddenAliases": [],
594
+ "id": "compute:get:build-log",
595
+ "pluginAlias": "@heroku/plugin-compute",
596
+ "pluginName": "@heroku/plugin-compute",
597
+ "pluginType": "core",
598
+ "strict": true,
599
+ "summary": "Print the build/compile log for a compute app's latest build.",
600
+ "enableJsonFlag": true,
601
+ "requiresProject": false,
602
+ "isESM": true,
603
+ "relativePath": [
604
+ "lib",
605
+ "commands",
606
+ "compute",
607
+ "get",
608
+ "build-log.js"
609
+ ],
610
+ "aliasPermutations": [],
611
+ "permutations": [
612
+ "compute:get:build-log",
613
+ "get:compute:build-log",
614
+ "get:build-log:compute",
615
+ "compute:build-log:get",
616
+ "build-log:compute:get",
617
+ "build-log:get:compute"
618
+ ]
619
+ },
620
+ "compute:get:config": {
374
621
  "aliases": [],
375
622
  "args": {
376
623
  "key": {
@@ -378,6 +625,7 @@
378
625
  "name": "key"
379
626
  }
380
627
  },
628
+ "deprecateAliases": true,
381
629
  "description": "Goes through the target org's Salesforce Connect API, which calls Heroku on\nyour behalf. Pass a single key to print its bare value, or more than one to\nprint each as key: value. Fails if any requested key isn't currently set.",
382
630
  "examples": [
383
631
  "Print a single config var's value:\n<%= config.bin %> <%= command.id %> STRIPE_KEY --name CreditRatingScorer --target-org my-org",
@@ -420,8 +668,10 @@
420
668
  }
421
669
  },
422
670
  "hasDynamicHelp": true,
423
- "hiddenAliases": [],
424
- "id": "compute:config:get",
671
+ "hiddenAliases": [
672
+ "compute:config:get"
673
+ ],
674
+ "id": "compute:get:config",
425
675
  "pluginAlias": "@heroku/plugin-compute",
426
676
  "pluginName": "@heroku/plugin-compute",
427
677
  "pluginType": "core",
@@ -434,25 +684,26 @@
434
684
  "lib",
435
685
  "commands",
436
686
  "compute",
437
- "config",
438
- "get.js"
687
+ "get",
688
+ "config.js"
439
689
  ],
440
690
  "aliasPermutations": [],
441
691
  "permutations": [
442
- "compute:config:get",
443
- "config:compute:get",
444
- "config:get:compute",
445
692
  "compute:get:config",
446
693
  "get:compute:config",
447
- "get:config:compute"
694
+ "get:config:compute",
695
+ "compute:config:get",
696
+ "config:compute:get",
697
+ "config:get:compute"
448
698
  ]
449
699
  },
450
- "compute:config:list": {
700
+ "compute:get:runtime-log": {
451
701
  "aliases": [],
452
702
  "args": {},
453
- "description": "Shows every config var (environment variable) currently set for a deployed\ncompute app, sorted alphabetically. Goes through the target org's Salesforce\nConnect API, which calls Heroku on your behalf. Use sf compute config get to\nread a single var's value, sf compute config set to add or change vars, or\nsf compute config unset to remove them.",
703
+ "description": "Fetches a compute app's runtime log -- the app's ongoing output (request\nhandling, application logs), not the build/compile log; use compute get\nbuild-log for that.\n\nThis prints the most recent log lines and exits. To keep the session open and\nstream new lines as they arrive, use compute tail runtime-log.\n\nThis is an org-mediated operation by --name (the app's DeveloperName) -- the\norg creates a log session with Heroku on your behalf and hands back a\nshort-lived, pre-authorized URL that the CLI reads from directly. It doesn't\nread from or require a local Salesforce DX project.",
454
704
  "examples": [
455
- "List all config vars for a compute app:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --target-org my-org"
705
+ "Print the most recent log lines:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --target-org my-org",
706
+ "Print the most recent 500 log lines:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --num 500 --target-org my-org"
456
707
  ],
457
708
  "flags": {
458
709
  "json": {
@@ -474,7 +725,7 @@
474
725
  "char": "n",
475
726
  "env": "COMPUTE_APP_NAME",
476
727
  "name": "name",
477
- "summary": "DeveloperName of the compute app to list config vars for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
728
+ "summary": "DeveloperName of the compute app to fetch logs for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
478
729
  "hasDynamicHelp": false,
479
730
  "multiple": false,
480
731
  "type": "option"
@@ -488,16 +739,24 @@
488
739
  "hasDynamicHelp": true,
489
740
  "multiple": false,
490
741
  "type": "option"
742
+ },
743
+ "num": {
744
+ "name": "num",
745
+ "summary": "Number of recent log lines to print.",
746
+ "default": 100,
747
+ "hasDynamicHelp": false,
748
+ "multiple": false,
749
+ "type": "option"
491
750
  }
492
751
  },
493
752
  "hasDynamicHelp": true,
494
753
  "hiddenAliases": [],
495
- "id": "compute:config:list",
754
+ "id": "compute:get:runtime-log",
496
755
  "pluginAlias": "@heroku/plugin-compute",
497
756
  "pluginName": "@heroku/plugin-compute",
498
757
  "pluginType": "core",
499
758
  "strict": true,
500
- "summary": "List a compute app's config vars.",
759
+ "summary": "Print the recent runtime log for a compute app.",
501
760
  "enableJsonFlag": true,
502
761
  "requiresProject": false,
503
762
  "isESM": true,
@@ -505,31 +764,26 @@
505
764
  "lib",
506
765
  "commands",
507
766
  "compute",
508
- "config",
509
- "list.js"
767
+ "get",
768
+ "runtime-log.js"
510
769
  ],
511
770
  "aliasPermutations": [],
512
771
  "permutations": [
513
- "compute:config:list",
514
- "config:compute:list",
515
- "config:list:compute",
516
- "compute:list:config",
517
- "list:compute:config",
518
- "list:config:compute"
772
+ "compute:get:runtime-log",
773
+ "get:compute:runtime-log",
774
+ "get:runtime-log:compute",
775
+ "compute:runtime-log:get",
776
+ "runtime-log:compute:get",
777
+ "runtime-log:get:compute"
519
778
  ]
520
779
  },
521
- "compute:config:set": {
780
+ "compute:list:config": {
522
781
  "aliases": [],
523
- "args": {
524
- "pair": {
525
- "multiple": true,
526
- "name": "pair"
527
- }
528
- },
529
- "description": "Goes through the target org's Salesforce Connect API, which calls Heroku on\nyour behalf. Setting a config var restarts the app's dynos so the new value\ntakes effect. Pass one or more KEY=VALUE pairs; a key that doesn't already\nexist is created.",
782
+ "args": {},
783
+ "deprecateAliases": true,
784
+ "description": "Shows every config var (environment variable) currently set for a deployed\ncompute app, sorted alphabetically. Goes through the target org's Salesforce\nConnect API, which calls Heroku on your behalf. Use sf compute get config to\nread a single var's value, sf compute set config to add or change vars, or\nsf compute unset config to remove them.",
530
785
  "examples": [
531
- "Set a single config var:\n<%= config.bin %> <%= command.id %> STRIPE_KEY=sk_live_xyz789 --name CreditRatingScorer --target-org my-org",
532
- "Set more than one config var in one command:\n<%= config.bin %> <%= command.id %> STRIPE_KEY=sk_live_xyz789 LOG_LEVEL=debug --name CreditRatingScorer --target-org my-org"
786
+ "List all config vars for a compute app:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --target-org my-org"
533
787
  ],
534
788
  "flags": {
535
789
  "json": {
@@ -551,7 +805,7 @@
551
805
  "char": "n",
552
806
  "env": "COMPUTE_APP_NAME",
553
807
  "name": "name",
554
- "summary": "DeveloperName of the compute app to change config for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
808
+ "summary": "DeveloperName of the compute app to list config vars for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
555
809
  "hasDynamicHelp": false,
556
810
  "multiple": false,
557
811
  "type": "option"
@@ -568,13 +822,15 @@
568
822
  }
569
823
  },
570
824
  "hasDynamicHelp": true,
571
- "hiddenAliases": [],
572
- "id": "compute:config:set",
825
+ "hiddenAliases": [
826
+ "compute:config:list"
827
+ ],
828
+ "id": "compute:list:config",
573
829
  "pluginAlias": "@heroku/plugin-compute",
574
830
  "pluginName": "@heroku/plugin-compute",
575
831
  "pluginType": "core",
576
832
  "strict": true,
577
- "summary": "Set one or more of a compute app's config vars.",
833
+ "summary": "List a compute app's config vars.",
578
834
  "enableJsonFlag": true,
579
835
  "requiresProject": false,
580
836
  "isESM": true,
@@ -582,31 +838,25 @@
582
838
  "lib",
583
839
  "commands",
584
840
  "compute",
585
- "config",
586
- "set.js"
841
+ "list",
842
+ "config.js"
587
843
  ],
588
844
  "aliasPermutations": [],
589
845
  "permutations": [
590
- "compute:config:set",
591
- "config:compute:set",
592
- "config:set:compute",
593
- "compute:set:config",
594
- "set:compute:config",
595
- "set:config:compute"
846
+ "compute:list:config",
847
+ "list:compute:config",
848
+ "list:config:compute",
849
+ "compute:config:list",
850
+ "config:compute:list",
851
+ "config:list:compute"
596
852
  ]
597
853
  },
598
- "compute:config:unset": {
854
+ "compute:list:telemetry-drain": {
599
855
  "aliases": [],
600
- "args": {
601
- "key": {
602
- "multiple": true,
603
- "name": "key"
604
- }
605
- },
606
- "description": "Goes through the target org's Salesforce Connect API, which calls Heroku on\nyour behalf. Unsetting a config var restarts the app's dynos so the removal\ntakes effect. Fails if any requested key isn't currently set.",
856
+ "args": {},
857
+ "description": "Shows every OpenTelemetry drain forwarding the compute app's logs, metrics,\nand traces, with each drain's ID, signals, and endpoint. Use\nsf compute display telemetry-drain to see the full detail of a single drain.",
607
858
  "examples": [
608
- "Unset a single config var:\n<%= config.bin %> <%= command.id %> LOG_LEVEL --name CreditRatingScorer --target-org my-org",
609
- "Unset more than one config var in one command:\n<%= config.bin %> <%= command.id %> LOG_LEVEL DEBUG_MODE --name CreditRatingScorer --target-org my-org"
859
+ "List the telemetry drains for a compute app:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --target-org my-org"
610
860
  ],
611
861
  "flags": {
612
862
  "json": {
@@ -628,7 +878,7 @@
628
878
  "char": "n",
629
879
  "env": "COMPUTE_APP_NAME",
630
880
  "name": "name",
631
- "summary": "DeveloperName of the compute app to change config for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
881
+ "summary": "DeveloperName of the compute app to list telemetry drains for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
632
882
  "hasDynamicHelp": false,
633
883
  "multiple": false,
634
884
  "type": "option"
@@ -646,12 +896,12 @@
646
896
  },
647
897
  "hasDynamicHelp": true,
648
898
  "hiddenAliases": [],
649
- "id": "compute:config:unset",
899
+ "id": "compute:list:telemetry-drain",
650
900
  "pluginAlias": "@heroku/plugin-compute",
651
901
  "pluginName": "@heroku/plugin-compute",
652
902
  "pluginType": "core",
653
903
  "strict": true,
654
- "summary": "Unset one or more of a compute app's config vars.",
904
+ "summary": "List the telemetry drains configured for a compute app.",
655
905
  "enableJsonFlag": true,
656
906
  "requiresProject": false,
657
907
  "isESM": true,
@@ -659,25 +909,32 @@
659
909
  "lib",
660
910
  "commands",
661
911
  "compute",
662
- "config",
663
- "unset.js"
912
+ "list",
913
+ "telemetry-drain.js"
664
914
  ],
665
915
  "aliasPermutations": [],
666
916
  "permutations": [
667
- "compute:config:unset",
668
- "config:compute:unset",
669
- "config:unset:compute",
670
- "compute:unset:config",
671
- "unset:compute:config",
672
- "unset:config:compute"
917
+ "compute:list:telemetry-drain",
918
+ "list:compute:telemetry-drain",
919
+ "list:telemetry-drain:compute",
920
+ "compute:telemetry-drain:list",
921
+ "telemetry-drain:compute:list",
922
+ "telemetry-drain:list:compute"
673
923
  ]
674
924
  },
675
- "compute:get:build-log": {
925
+ "compute:set:config": {
676
926
  "aliases": [],
677
- "args": {},
678
- "description": "Fetches the bounded build/compile log (dependency install, slug compile,\nrelease) for the most recent build of a compute app -- useful right after\ndeploy to confirm the build compiled. This is a one-shot fetch of a\nfinished-or-in-progress log, not a live stream; use compute tail runtime-log\nfor the ongoing runtime log.\n\nThis is a read-only, org-mediated lookup by --name (the app's DeveloperName)\n-- the org calls Heroku's Build Info API on your behalf. It doesn't read from\nor require a local Salesforce DX project.",
927
+ "args": {
928
+ "pair": {
929
+ "multiple": true,
930
+ "name": "pair"
931
+ }
932
+ },
933
+ "deprecateAliases": true,
934
+ "description": "Goes through the target org's Salesforce Connect API, which calls Heroku on\nyour behalf. Setting a config var restarts the app's dynos so the new value\ntakes effect. Pass one or more KEY=VALUE pairs; a key that doesn't already\nexist is created.",
679
935
  "examples": [
680
- "Print the latest build's log:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --target-org my-org"
936
+ "Set a single config var:\n<%= config.bin %> <%= command.id %> STRIPE_KEY=sk_live_xyz789 --name CreditRatingScorer --target-org my-org",
937
+ "Set more than one config var in one command:\n<%= config.bin %> <%= command.id %> STRIPE_KEY=sk_live_xyz789 LOG_LEVEL=debug --name CreditRatingScorer --target-org my-org"
681
938
  ],
682
939
  "flags": {
683
940
  "json": {
@@ -699,7 +956,7 @@
699
956
  "char": "n",
700
957
  "env": "COMPUTE_APP_NAME",
701
958
  "name": "name",
702
- "summary": "DeveloperName of the compute app to fetch build output for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
959
+ "summary": "DeveloperName of the compute app to change config for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
703
960
  "hasDynamicHelp": false,
704
961
  "multiple": false,
705
962
  "type": "option"
@@ -716,13 +973,15 @@
716
973
  }
717
974
  },
718
975
  "hasDynamicHelp": true,
719
- "hiddenAliases": [],
720
- "id": "compute:get:build-log",
976
+ "hiddenAliases": [
977
+ "compute:config:set"
978
+ ],
979
+ "id": "compute:set:config",
721
980
  "pluginAlias": "@heroku/plugin-compute",
722
981
  "pluginName": "@heroku/plugin-compute",
723
982
  "pluginType": "core",
724
983
  "strict": true,
725
- "summary": "Print the build/compile log for a compute app's latest build.",
984
+ "summary": "Set one or more of a compute app's config vars.",
726
985
  "enableJsonFlag": true,
727
986
  "requiresProject": false,
728
987
  "isESM": true,
@@ -730,26 +989,25 @@
730
989
  "lib",
731
990
  "commands",
732
991
  "compute",
733
- "get",
734
- "build-log.js"
992
+ "set",
993
+ "config.js"
735
994
  ],
736
995
  "aliasPermutations": [],
737
996
  "permutations": [
738
- "compute:get:build-log",
739
- "get:compute:build-log",
740
- "get:build-log:compute",
741
- "compute:build-log:get",
742
- "build-log:compute:get",
743
- "build-log:get:compute"
997
+ "compute:set:config",
998
+ "set:compute:config",
999
+ "set:config:compute",
1000
+ "compute:config:set",
1001
+ "config:compute:set",
1002
+ "config:set:compute"
744
1003
  ]
745
1004
  },
746
- "compute:get:runtime-log": {
1005
+ "compute:source:retrieve": {
747
1006
  "aliases": [],
748
1007
  "args": {},
749
- "description": "Fetches a compute app's runtime log -- the app's ongoing output (request\nhandling, application logs), not the build/compile log; use compute get\nbuild-log for that.\n\nThis prints the most recent log lines and exits. To keep the session open and\nstream new lines as they arrive, use compute tail runtime-log.\n\nThis is an org-mediated operation by --name (the app's DeveloperName) -- the\norg creates a log session with Heroku on your behalf and hands back a\nshort-lived, pre-authorized URL that the CLI reads from directly. It doesn't\nread from or require a local Salesforce DX project.",
1008
+ "description": "Creates the compute app's directory under force-app/main/default/platformComputeApps/<name>/\n(or --output-dir), retrieves its <name>.compute-meta.xml through the Metadata\nAPI, then downloads its source code through the Connect API and extracts it\ninto that same directory. This is the inverse of sf compute deploy.",
750
1009
  "examples": [
751
- "Print the most recent log lines:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --target-org my-org",
752
- "Print the most recent 500 log lines:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --num 500 --target-org my-org"
1010
+ "Retrieve a compute app's source and metadata from an org:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --target-org my-org"
753
1011
  ],
754
1012
  "flags": {
755
1013
  "json": {
@@ -769,9 +1027,9 @@
769
1027
  },
770
1028
  "name": {
771
1029
  "char": "n",
772
- "env": "COMPUTE_APP_NAME",
773
1030
  "name": "name",
774
- "summary": "DeveloperName of the compute app to fetch logs for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
1031
+ "required": true,
1032
+ "summary": "DeveloperName of the compute app to retrieve (or <namespace>\\_\\_<developerName>\nif it was deployed under a namespace).",
775
1033
  "hasDynamicHelp": false,
776
1034
  "multiple": false,
777
1035
  "type": "option"
@@ -786,10 +1044,12 @@
786
1044
  "multiple": false,
787
1045
  "type": "option"
788
1046
  },
789
- "num": {
790
- "name": "num",
791
- "summary": "Number of recent log lines to print.",
792
- "default": 100,
1047
+ "output-dir": {
1048
+ "char": "d",
1049
+ "description": "Defaults to force-app/main/default/platformComputeApps. The app itself is created in a\nsubdirectory named after --name.",
1050
+ "name": "output-dir",
1051
+ "summary": "Directory to create the app in.",
1052
+ "default": "force-app/main/default/platformComputeApps",
793
1053
  "hasDynamicHelp": false,
794
1054
  "multiple": false,
795
1055
  "type": "option"
@@ -797,30 +1057,30 @@
797
1057
  },
798
1058
  "hasDynamicHelp": true,
799
1059
  "hiddenAliases": [],
800
- "id": "compute:get:runtime-log",
1060
+ "id": "compute:source:retrieve",
801
1061
  "pluginAlias": "@heroku/plugin-compute",
802
1062
  "pluginName": "@heroku/plugin-compute",
803
1063
  "pluginType": "core",
804
1064
  "strict": true,
805
- "summary": "Print the recent runtime log for a compute app.",
1065
+ "summary": "Retrieve a compute app's source and metadata from an org into your local Salesforce DX project.",
806
1066
  "enableJsonFlag": true,
807
- "requiresProject": false,
1067
+ "requiresProject": true,
808
1068
  "isESM": true,
809
1069
  "relativePath": [
810
1070
  "lib",
811
1071
  "commands",
812
1072
  "compute",
813
- "get",
814
- "runtime-log.js"
1073
+ "source",
1074
+ "retrieve.js"
815
1075
  ],
816
1076
  "aliasPermutations": [],
817
1077
  "permutations": [
818
- "compute:get:runtime-log",
819
- "get:compute:runtime-log",
820
- "get:runtime-log:compute",
821
- "compute:runtime-log:get",
822
- "runtime-log:compute:get",
823
- "runtime-log:get:compute"
1078
+ "compute:source:retrieve",
1079
+ "source:compute:retrieve",
1080
+ "source:retrieve:compute",
1081
+ "compute:retrieve:source",
1082
+ "retrieve:compute:source",
1083
+ "retrieve:source:compute"
824
1084
  ]
825
1085
  },
826
1086
  "compute:tail:runtime-log": {
@@ -896,12 +1156,19 @@
896
1156
  "runtime-log:tail:compute"
897
1157
  ]
898
1158
  },
899
- "compute:source:retrieve": {
1159
+ "compute:unset:config": {
900
1160
  "aliases": [],
901
- "args": {},
902
- "description": "Creates the compute app's directory under force-app/main/default/platformComputeApps/<name>/\n(or --output-dir), retrieves its <name>.compute-meta.xml through the Metadata\nAPI, then downloads its source code through the Connect API and extracts it\ninto that same directory. This is the inverse of sf compute deploy.",
1161
+ "args": {
1162
+ "key": {
1163
+ "multiple": true,
1164
+ "name": "key"
1165
+ }
1166
+ },
1167
+ "deprecateAliases": true,
1168
+ "description": "Goes through the target org's Salesforce Connect API, which calls Heroku on\nyour behalf. Unsetting a config var restarts the app's dynos so the removal\ntakes effect. Fails if any requested key isn't currently set.",
903
1169
  "examples": [
904
- "Retrieve a compute app's source and metadata from an org:\n<%= config.bin %> <%= command.id %> --name CreditRatingScorer --target-org my-org"
1170
+ "Unset a single config var:\n<%= config.bin %> <%= command.id %> LOG_LEVEL --name CreditRatingScorer --target-org my-org",
1171
+ "Unset more than one config var in one command:\n<%= config.bin %> <%= command.id %> LOG_LEVEL DEBUG_MODE --name CreditRatingScorer --target-org my-org"
905
1172
  ],
906
1173
  "flags": {
907
1174
  "json": {
@@ -921,9 +1188,9 @@
921
1188
  },
922
1189
  "name": {
923
1190
  "char": "n",
1191
+ "env": "COMPUTE_APP_NAME",
924
1192
  "name": "name",
925
- "required": true,
926
- "summary": "DeveloperName of the compute app to retrieve (or <namespace>\\_\\_<developerName>\nif it was deployed under a namespace).",
1193
+ "summary": "DeveloperName of the compute app to change config for (or\n<namespace>\\_\\_<developerName> if it was deployed under a namespace).\nDefaults to the COMPUTE_APP_NAME environment variable, or the current\ndirectory's app name if that isn't set either.",
927
1194
  "hasDynamicHelp": false,
928
1195
  "multiple": false,
929
1196
  "type": "option"
@@ -937,46 +1204,135 @@
937
1204
  "hasDynamicHelp": true,
938
1205
  "multiple": false,
939
1206
  "type": "option"
1207
+ }
1208
+ },
1209
+ "hasDynamicHelp": true,
1210
+ "hiddenAliases": [
1211
+ "compute:config:unset"
1212
+ ],
1213
+ "id": "compute:unset:config",
1214
+ "pluginAlias": "@heroku/plugin-compute",
1215
+ "pluginName": "@heroku/plugin-compute",
1216
+ "pluginType": "core",
1217
+ "strict": true,
1218
+ "summary": "Unset one or more of a compute app's config vars.",
1219
+ "enableJsonFlag": true,
1220
+ "requiresProject": false,
1221
+ "isESM": true,
1222
+ "relativePath": [
1223
+ "lib",
1224
+ "commands",
1225
+ "compute",
1226
+ "unset",
1227
+ "config.js"
1228
+ ],
1229
+ "aliasPermutations": [],
1230
+ "permutations": [
1231
+ "compute:unset:config",
1232
+ "unset:compute:config",
1233
+ "unset:config:compute",
1234
+ "compute:config:unset",
1235
+ "config:compute:unset",
1236
+ "config:unset:compute"
1237
+ ]
1238
+ },
1239
+ "compute:update:telemetry-drain": {
1240
+ "aliases": [],
1241
+ "args": {
1242
+ "id": {
1243
+ "name": "id",
1244
+ "required": true
1245
+ }
1246
+ },
1247
+ "description": "Updates only the attributes you pass and leaves the rest of the drain as it\nis. Passing --header adds or overwrites the headers you give and keeps the\ndrain's other headers. Use sf compute list telemetry-drain to find a drain's ID.",
1248
+ "examples": [
1249
+ "Point a drain at a new endpoint:\n<%= config.bin %> <%= command.id %> 01234567-89ab-cdef-0123-456789abcdef --url https://collector.example.com:4318 --target-org my-org",
1250
+ "Forward only logs over gRPC:\n<%= config.bin %> <%= command.id %> 01234567-89ab-cdef-0123-456789abcdef --signals logs --transport grpc --target-org my-org"
1251
+ ],
1252
+ "flags": {
1253
+ "json": {
1254
+ "description": "Format output as json.",
1255
+ "helpGroup": "GLOBAL",
1256
+ "name": "json",
1257
+ "allowNo": false,
1258
+ "type": "boolean"
940
1259
  },
941
- "output-dir": {
942
- "char": "d",
943
- "description": "Defaults to force-app/main/default/platformComputeApps. The app itself is created in a\nsubdirectory named after --name.",
944
- "name": "output-dir",
945
- "summary": "Directory to create the app in.",
946
- "default": "force-app/main/default/platformComputeApps",
1260
+ "flags-dir": {
1261
+ "helpGroup": "GLOBAL",
1262
+ "name": "flags-dir",
1263
+ "summary": "Import flag values from a directory.",
1264
+ "hasDynamicHelp": false,
1265
+ "multiple": false,
1266
+ "type": "option"
1267
+ },
1268
+ "url": {
1269
+ "name": "url",
1270
+ "summary": "New endpoint to forward telemetry to.",
1271
+ "hasDynamicHelp": false,
1272
+ "multiple": false,
1273
+ "type": "option"
1274
+ },
1275
+ "signals": {
1276
+ "name": "signals",
1277
+ "summary": "New comma-separated signals to forward: traces, metrics, logs, or all.",
1278
+ "hasDynamicHelp": false,
1279
+ "multiple": false,
1280
+ "type": "option"
1281
+ },
1282
+ "transport": {
1283
+ "name": "transport",
1284
+ "summary": "New wire protocol: http (OTLP over HTTP) or grpc (OTLP over gRPC).",
947
1285
  "hasDynamicHelp": false,
948
1286
  "multiple": false,
949
1287
  "type": "option"
1288
+ },
1289
+ "header": {
1290
+ "description": "Repeat the flag to send more than one header. A header you pass adds\nor overwrites the one with the same name; the drain's other headers are kept. Header values often carry credentials; they are\nnever printed to the terminal, but are included in --json output.",
1291
+ "name": "header",
1292
+ "summary": "Header to send with each export, as key=value.",
1293
+ "hasDynamicHelp": false,
1294
+ "multiple": true,
1295
+ "type": "option"
1296
+ },
1297
+ "target-org": {
1298
+ "char": "o",
1299
+ "name": "target-org",
1300
+ "noCacheDefault": true,
1301
+ "required": true,
1302
+ "summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
1303
+ "hasDynamicHelp": true,
1304
+ "multiple": false,
1305
+ "type": "option"
950
1306
  }
951
1307
  },
952
1308
  "hasDynamicHelp": true,
953
1309
  "hiddenAliases": [],
954
- "id": "compute:source:retrieve",
1310
+ "id": "compute:update:telemetry-drain",
955
1311
  "pluginAlias": "@heroku/plugin-compute",
956
1312
  "pluginName": "@heroku/plugin-compute",
957
1313
  "pluginType": "core",
958
1314
  "strict": true,
959
- "summary": "Retrieve a compute app's source and metadata from an org into your local Salesforce DX project.",
1315
+ "summary": "Change the configuration of a compute telemetry drain.",
960
1316
  "enableJsonFlag": true,
961
- "requiresProject": true,
1317
+ "requiresProject": false,
962
1318
  "isESM": true,
963
1319
  "relativePath": [
964
1320
  "lib",
965
1321
  "commands",
966
1322
  "compute",
967
- "source",
968
- "retrieve.js"
1323
+ "update",
1324
+ "telemetry-drain.js"
969
1325
  ],
970
1326
  "aliasPermutations": [],
971
1327
  "permutations": [
972
- "compute:source:retrieve",
973
- "source:compute:retrieve",
974
- "source:retrieve:compute",
975
- "compute:retrieve:source",
976
- "retrieve:compute:source",
977
- "retrieve:source:compute"
1328
+ "compute:update:telemetry-drain",
1329
+ "update:compute:telemetry-drain",
1330
+ "update:telemetry-drain:compute",
1331
+ "compute:telemetry-drain:update",
1332
+ "telemetry-drain:compute:update",
1333
+ "telemetry-drain:update:compute"
978
1334
  ]
979
1335
  }
980
1336
  },
981
- "version": "0.2.0"
1337
+ "version": "0.3.1"
982
1338
  }