@kumori/aurora-backend-handler 1.0.76 → 1.0.78

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.
@@ -209,7 +209,6 @@ export const restartService = async (data: Service, security: string) => {
209
209
  }
210
210
  };
211
211
  const generateLinkBody = (data: Service, link: Link) => {
212
- const generateLinkBody = (data: Service, link: Link) => {
213
212
  const isOrigin = data.name === link.origin;
214
213
  const isTarget = data.name === link.target;
215
214
 
@@ -313,7 +312,7 @@ const generateLinkBody = (data: Service, link: Link) => {
313
312
  };
314
313
  } else {
315
314
  console.warn(
316
- `No se encontraron canales para el enlace: origin=${link.origin}, target=${link.target}`
315
+ `No se encontraron canales para el enlace: origin=${link.origin}, target=${link.target}`,
317
316
  );
318
317
  linkBody = {
319
318
  client_tenant: data.tenant,
@@ -326,6 +325,7 @@ const generateLinkBody = (data: Service, link: Link) => {
326
325
  }
327
326
  return linkBody;
328
327
  };
328
+
329
329
  export const linkPendingServices = async (service: Service, token: string) => {
330
330
  const links = pendingLinks.get(service.name);
331
331
  if (links) {
@@ -604,7 +604,7 @@ export const updateService = async (
604
604
  },
605
605
  };
606
606
  eventHelper.service.publish.updated(updatedService);
607
-
607
+
608
608
  const updateNotification: Notification = {
609
609
  type: "success",
610
610
  subtype: "service-updated",
@@ -616,11 +616,10 @@ export const updateService = async (
616
616
  tenant: data.tenant,
617
617
  },
618
618
  };
619
-
619
+
620
620
  eventHelper.notification.publish.creation(updateNotification);
621
621
  return response;
622
622
  }
623
-
624
623
  } catch (err) {
625
624
  console.error("Error updating service configuration via WebSocket:", err);
626
625
  const notification: Notification = {
@@ -859,10 +858,15 @@ function getLatestRevision(revisions: Revision[]): number | null {
859
858
  if (!revisions || revisions.length === 0) {
860
859
  return null;
861
860
  }
862
-
861
+
863
862
  return Math.max(...revisions.map((revision) => Number(revision.id)));
864
863
  }
865
- export async function restartInstance(service: Service, roleId: string, instanceId: string, token: string) {
864
+ export async function restartInstance(
865
+ service: Service,
866
+ roleId: string,
867
+ instanceId: string,
868
+ token: string,
869
+ ) {
866
870
  try {
867
871
  await initializeGlobalWebSocketClient(token);
868
872
  const status = getWebSocketStatus();
@@ -877,7 +881,7 @@ export async function restartInstance(service: Service, roleId: string, instance
877
881
  revisionBody,
878
882
  30000,
879
883
  "RESTART_INSTANCE",
880
- service.name
884
+ service.name,
881
885
  );
882
886
  const notification: Notification = {
883
887
  type: "success",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kumori/aurora-backend-handler",
3
- "version": "1.0.76",
3
+ "version": "1.0.78",
4
4
  "description": "backend handler",
5
5
  "main": "backend-handler.ts",
6
6
  "scripts": {