Skip to content

Commit

Permalink
Merge pull request #10 from BouyguesTelecom/clean/archi-folder
Browse files Browse the repository at this point in the history
change backup-storage in utils => delegated-storage in api
  • Loading branch information
AmelieLoulergue authored Nov 19, 2024
2 parents 44357d0 + 3b87d3d commit 8a78afc
Show file tree
Hide file tree
Showing 9 changed files with 11 additions and 101 deletions.
Binary file modified local/redis/dumps/dump.rdb
Binary file not shown.
2 changes: 1 addition & 1 deletion src/api/controllers/backup.controller.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Request, Response } from 'express';
import { getLastDump, deleteFileBackup, getFileBackup, updateFileBackup, uploadFileBackup } from '../utils/backup-storage';
import { getLastDump, deleteFileBackup, getFileBackup, updateFileBackup, uploadFileBackup } from '../delegated-storage/index';
import fs from 'fs';
import { BackupProps } from '../props/backup';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import fetch, { Headers } from 'node-fetch';
import { BackupProps } from '../../../props/backup';
import { connectClient, disconnectClient } from '../../redis/connection';
import { addMultipleFiles } from '../../redis/operations';
import { logger } from '../../logs/winston';
import { BackupProps } from '../../props/backup';
import { connectClient, disconnectClient } from '../../utils/redis/connection';
import { addMultipleFiles } from '../../utils/redis/operations';
import { logger } from '../../utils/logs/winston';

interface UploadFileProps {
filepath: string;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as distantBackend from './distant-backend/utils';
import * as s3 from './s3/utils';
import { logger } from '../logs/winston';
import { logger } from '../utils/logs/winston';

export interface FilePathProps {
filepath: string;
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { minioClient } from './connection';
import { FileProps } from '../types';
import { promisify } from 'node:util';
import { addMultipleFiles, getLastVersion } from '../../redis/operations';
import { connectClient, disconnectClient } from '../../redis/connection';
import app from '../../../app';
import { addMultipleFiles, getLastVersion } from '../../utils/redis/operations';
import { connectClient, disconnectClient } from '../../utils/redis/connection';
import app from '../../app';

export const getLastDump = async () => {
const getObjectAsync = promisify(minioClient.getObject.bind(minioClient));
Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions src/api/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import app from './app';
import { logger } from './utils/logs/winston';
import fs from 'fs';
import { redisClient } from './utils/redis/connection';
import { getLastDump } from './utils/backup-storage';
import { minioClient } from './utils/backup-storage/s3/connection';
import { getLastDump } from './delegated-storage/index';
import { minioClient } from './delegated-storage/s3/connection';
import { expressListRoutes } from './utils/list-routes';
import fetch from 'node-fetch';

Expand Down
90 changes: 0 additions & 90 deletions src/api/tests/api.test.ts

This file was deleted.

0 comments on commit 8a78afc

Please sign in to comment.