Remove logic function layer (#17697)
## Remove logic function layer Package.json and yarn.lock are now on the application entity, so the logic function layer is no longer used except as a legacy source for the 1.17 backfill. This PR removes all layer usage outside of that migration and keeps only the entity for backfill. ### Summary - **Kept:** `LogicFunctionLayerEntity` and its table, only used by the 1.17 backfill command to read legacy layer data and backfill application package files. - **Removed:** All other layer logic: CRUD, cache, resolvers, services, DTOs, and frontend types. Logic functions now depend only on the application for package/dependency context. ### Why Dependencies instead of Source for package files Package.json and yarn.lock are the application’s dependency set and are stored under the application in **FileFolder.Dependencies**. The build service and drivers now read them only from Dependencies; nothing is written to Source for these files.
This commit is contained in:
+1
-17
@@ -6,16 +6,12 @@ import {
|
||||
DeleteDateColumn,
|
||||
Entity,
|
||||
Index,
|
||||
JoinColumn,
|
||||
ManyToOne,
|
||||
PrimaryGeneratedColumn,
|
||||
Relation,
|
||||
UpdateDateColumn,
|
||||
} from 'typeorm';
|
||||
|
||||
import { type JsonbProperty } from 'src/engine/workspace-manager/workspace-migration/universal-flat-entity/types/jsonb-property.type';
|
||||
import { LogicFunctionLayerEntity } from 'src/engine/metadata-modules/logic-function-layer/logic-function-layer.entity';
|
||||
import { SyncableEntity } from 'src/engine/workspace-manager/types/syncable-entity.interface';
|
||||
import { type JsonbProperty } from 'src/engine/workspace-manager/workspace-migration/universal-flat-entity/types/jsonb-property.type';
|
||||
|
||||
export type CronTriggerSettings = {
|
||||
pattern: string;
|
||||
@@ -46,7 +42,6 @@ export const DEFAULT_HANDLER_NAME = 'main';
|
||||
|
||||
@Entity('logicFunction')
|
||||
@Index('IDX_LOGIC_FUNCTION_ID_DELETED_AT', ['id', 'deletedAt'])
|
||||
@Index('IDX_LOGIC_FUNCTION_LAYER_ID', ['logicFunctionLayerId'])
|
||||
export class LogicFunctionEntity
|
||||
extends SyncableEntity
|
||||
implements Required<LogicFunctionEntity>
|
||||
@@ -85,17 +80,6 @@ export class LogicFunctionEntity
|
||||
@Column({ nullable: false, default: false })
|
||||
isTool: boolean;
|
||||
|
||||
@Column({ nullable: false, type: 'uuid' })
|
||||
logicFunctionLayerId: string;
|
||||
|
||||
@ManyToOne(
|
||||
() => LogicFunctionLayerEntity,
|
||||
(logicFunctionLayer) => logicFunctionLayer.logicFunctions,
|
||||
{ nullable: false },
|
||||
)
|
||||
@JoinColumn({ name: 'logicFunctionLayerId' })
|
||||
logicFunctionLayer: Relation<LogicFunctionLayerEntity>;
|
||||
|
||||
@Column({ nullable: true, type: 'jsonb' })
|
||||
cronTriggerSettings: JsonbProperty<CronTriggerSettings> | null;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user