@go-avro/avro-js 1.6.6-rc4 → 1.6.6-rc5
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/client/QueryClient.d.ts +9 -0
- package/dist/client/hooks/avro.js +13 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
|
@@ -280,6 +280,15 @@ declare module './QueryClient.js' {
|
|
|
280
280
|
msg: string;
|
|
281
281
|
cleared: number;
|
|
282
282
|
}, StandardError, void>>;
|
|
283
|
+
/**
|
|
284
|
+
* Root only: run scheduled jobs now (all of them when called with no
|
|
285
|
+
* ids). The scheduler starts them within a few seconds; watch their
|
|
286
|
+
* status in `useGetPerformanceMetrics`.
|
|
287
|
+
*/
|
|
288
|
+
useRunSchedulerJobs(): ReturnType<typeof useMutation<{
|
|
289
|
+
msg: string;
|
|
290
|
+
jobs: string[];
|
|
291
|
+
}, StandardError, string[] | void>>;
|
|
283
292
|
useSearchUsers(searchUsername: string): UseQueryResult<User[], StandardError>;
|
|
284
293
|
useMergeUsersPreview(keepId: string, duplicateId: string): UseQueryResult<UserMergeSummary, StandardError>;
|
|
285
294
|
useMergeUsers(): ReturnType<typeof useMutation<UserMergeSummary, StandardError, {
|
|
@@ -45,3 +45,16 @@ AvroQueryClient.prototype.useClearErrorLog = function () {
|
|
|
45
45
|
},
|
|
46
46
|
});
|
|
47
47
|
};
|
|
48
|
+
AvroQueryClient.prototype.useRunSchedulerJobs = function () {
|
|
49
|
+
const queryClient = this.getQueryClient();
|
|
50
|
+
return useMutation({
|
|
51
|
+
mutationFn: (jobIds) => this.post({
|
|
52
|
+
path: '/avro/scheduler/run',
|
|
53
|
+
data: JSON.stringify(jobIds ? { job_ids: jobIds } : {}),
|
|
54
|
+
headers: { 'Content-Type': 'application/json' },
|
|
55
|
+
}),
|
|
56
|
+
onSuccess: () => {
|
|
57
|
+
queryClient.invalidateQueries({ queryKey: ['avro', 'performance'] });
|
|
58
|
+
},
|
|
59
|
+
});
|
|
60
|
+
};
|
package/dist/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const AVRO_JS_VERSION = "1.6.6-
|
|
1
|
+
export declare const AVRO_JS_VERSION = "1.6.6-rc5";
|
package/dist/version.js
CHANGED