@madewithremy/admin 0.1.15 → 0.1.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +13 -7
- package/dist/index.js +8 -0
- package/dist/index.js.map +1 -1
- package/dist/prod.js +34 -0
- package/package.json +1 -1
package/dist/prod.js
CHANGED
|
@@ -3391,6 +3391,13 @@ function resume(ctx, params) {
|
|
|
3391
3391
|
controlBody(params)
|
|
3392
3392
|
);
|
|
3393
3393
|
}
|
|
3394
|
+
function retry(ctx, params) {
|
|
3395
|
+
return call(
|
|
3396
|
+
ctx,
|
|
3397
|
+
"POST",
|
|
3398
|
+
`${base2(ctx.appId)}/${encodeURIComponent(params.id)}/retry`
|
|
3399
|
+
);
|
|
3400
|
+
}
|
|
3394
3401
|
function cancel(ctx, params) {
|
|
3395
3402
|
return call(
|
|
3396
3403
|
ctx,
|
|
@@ -4542,6 +4549,14 @@ var dataSourceJobsSpecs = {
|
|
|
4542
4549
|
timeout: { type: "string" }
|
|
4543
4550
|
}
|
|
4544
4551
|
},
|
|
4552
|
+
"datasources jobs retry": {
|
|
4553
|
+
usage: "Usage: remy-admin datasources jobs retry <id> [--wait] [--timeout <sec>]",
|
|
4554
|
+
positionals: [{ name: "id", required: true }],
|
|
4555
|
+
flags: {
|
|
4556
|
+
wait: { type: "boolean" },
|
|
4557
|
+
timeout: { type: "string" }
|
|
4558
|
+
}
|
|
4559
|
+
},
|
|
4545
4560
|
"datasources jobs cancel": {
|
|
4546
4561
|
usage: "Usage: remy-admin datasources jobs cancel <id>",
|
|
4547
4562
|
positionals: [{ name: "id", required: true }]
|
|
@@ -4650,6 +4665,15 @@ async function jobsResume(ctx, a) {
|
|
|
4650
4665
|
}
|
|
4651
4666
|
await waitAndReport(ctx, a, id, "job", { action: "resume" });
|
|
4652
4667
|
}
|
|
4668
|
+
async function jobsRetry(ctx, a) {
|
|
4669
|
+
const id = a.req("id");
|
|
4670
|
+
const { job } = await retry(ctx, { id });
|
|
4671
|
+
if (!a.bool("wait")) {
|
|
4672
|
+
out({ job });
|
|
4673
|
+
return;
|
|
4674
|
+
}
|
|
4675
|
+
await waitAndReport(ctx, a, id, "job", { action: "retry" });
|
|
4676
|
+
}
|
|
4653
4677
|
async function jobsCancel(ctx, a) {
|
|
4654
4678
|
out(await cancel(ctx, { id: a.req("id") }));
|
|
4655
4679
|
}
|
|
@@ -4660,6 +4684,7 @@ var dataSourceJobsHandlers = {
|
|
|
4660
4684
|
"datasources jobs approve": jobsApprove,
|
|
4661
4685
|
"datasources jobs pause": jobsPause,
|
|
4662
4686
|
"datasources jobs resume": jobsResume,
|
|
4687
|
+
"datasources jobs retry": jobsRetry,
|
|
4663
4688
|
"datasources jobs cancel": jobsCancel
|
|
4664
4689
|
};
|
|
4665
4690
|
var dataSourceJobsHelp = `
|
|
@@ -4670,6 +4695,7 @@ Bulk ingestion (jobs):
|
|
|
4670
4695
|
remy-admin datasources jobs status <id> [--wait] [--timeout <sec>]
|
|
4671
4696
|
remy-admin datasources jobs approve <id> [--wait] [--timeout <sec>]
|
|
4672
4697
|
remy-admin datasources jobs pause|resume|cancel <id>
|
|
4698
|
+
remy-admin datasources jobs retry <id> [--wait] [--timeout <sec>]
|
|
4673
4699
|
|
|
4674
4700
|
A job loads a whole corpus at once. It reads either every object under a
|
|
4675
4701
|
prefix of one of the app's file stores (\`files put\` fills one; an app can
|
|
@@ -4707,6 +4733,14 @@ Bulk ingestion (jobs):
|
|
|
4707
4733
|
from the checkpoint and retries failed batches; \`jobs cancel\` stops it and
|
|
4708
4734
|
keeps what was indexed. Search works on the partial corpus throughout.
|
|
4709
4735
|
|
|
4736
|
+
A batch that fails five times stays failed and the job finishes without it,
|
|
4737
|
+
with its documents left mid-build; \`jobs status\` shows the batch's error.
|
|
4738
|
+
Once the cause is fixed (capacity that was restoring, a provider outage),
|
|
4739
|
+
\`jobs retry <id>\` puts the job back to running over just those batches and
|
|
4740
|
+
finishes it again. A source with documents mid-build refuses to move or
|
|
4741
|
+
re-vectorize (data_source_busy) until they finish, so retry is what clears
|
|
4742
|
+
that.
|
|
4743
|
+
|
|
4710
4744
|
One bulk operation per source: a job refuses to start during a move or while
|
|
4711
4745
|
a candidate version exists, and moves, re-vectorizes and deletes refuse while
|
|
4712
4746
|
a job is in flight (data_source_busy). Interactive \`add\` keeps working.
|