Repository navigation
v0.7.9
ExisJS Release v0.7.9
Release Date: 2026-09-24
Type: Minor Feature, Enterprise OOP Architecture Upgrades & Bug Fixes
Affected Packages: exisjs, create-exisjs
Highlights
- Enterprise OOP Architecture Upgrades:
- Security & Authorization Decorators: Added first-class
@Permissions(),@Roles(), and@Public()(@IsPublic(),@AllowAnonymous()) decorators with automatedisSuperAdminbypass and context propagation. - Service Lifecycle Hooks: Exported
OnInit,OnDestroy,OnModuleInit,OnModuleDestroy, andOnApplicationBootstraplifecycle interfaces, seamlessly invoked during application boot and graceful shutdown. - Off-Heap Method Caching: Added
@Cacheable()and@CacheEvict()decorators powered directly by ExisJS's native off-heap Rust LRU cache (NativeMemoryCache). - Automatic Transaction Management: Added
@Transactional()method decorator supporting ExisJS built-in DB, Prisma, Drizzle, TypeORM, Knex, and connection pools. - Performance Profiling: Added
@Profile()decorator with sub-millisecond precision usingperformance.now(). - Declarative Exception Filtering: Added
@Catch(...exceptions)and@UseFilters()decorators withExceptionFilterandArgumentsHostinterfaces. - Dual Class/Type Exception Declarations: Converted all HTTP exception aliases (
NotFoundException,UnauthorizedException,ForbiddenException,BadRequestException, etc.) into proper subclasses that function simultaneously as runtime class constructors and TypeScript type annotations.
- Security & Authorization Decorators: Added first-class
- Route & Decorator Schema Normalization: Enhanced
@Get,@Post,@Put,@Patch,@Delete,@Options,@Head,@Allto gracefully accept rawTexEngine/Zod validation schemas as well as structured{ body, query, params, headers }objects withoutTS(2559)errors. - Async Generator Type Safety: Standardized all starter templates in
create-exisjsand CLI generators to emit explicitPromise<T>return types on async methods to resolveTS(1064). - Test Harness Enhancements:
createTestAppandcreateTestContextnow accept bothAppinstances,ExisAppDefinitiondefinitions, andExisConfigconfiguration objects with shared boot promise memoization. - Dev Watcher Lockfile & Debounce Optimization: Configured
chokidarinexis devto ignore package lockfiles (package-lock.json,pnpm-lock.yaml,yarn.lock,bun.lock), cache dirs (.turbo,.next,.cache), and debounced reload events to eliminate restart loops duringnpm install. - ESM Multiline Import Path Resolution: Fixed regex in
resolve-aliases.tsto support multiline import/export specifiers across line breaks duringexis build. - Scaffolding Template Alignment: Standardized
exis.config.tsgenerator template to exportconst config: ExisConfigandexport default config.
Key Improvements & Details
1. Security & Permissions Decorators
import { Controller, Get, Post, Body, Permissions, Public, Use } from 'exisjs/decorators'
@Controller('/roles')
@Use(AuthGuard)
export default class RolesController {
@Get('/public')
@Public()
async getPublic() { ... }
@Post('/')
@Permissions('role:create', 'role:manage')
async createRole(@Body() body: CreateRoleDto) { ... }
}2. Service Lifecycle Interfaces
import { Injectable, type OnInit, type OnDestroy } from 'exisjs/decorators'
@Injectable()
export class DatabaseService implements OnInit, OnDestroy {
async onInit(): Promise<void> {
await this.pool.connect()
}
async onDestroy(): Promise<void> {
await this.pool.end()
}
}3. Native Off-Heap Method Caching
import { Injectable, Cacheable, CacheEvict } from 'exisjs/decorators'
@Injectable()
export class RoleService {
@Cacheable({ ttl: 300, key: (id) => `role:${id}` })
async findById(id: string): Promise<Role> {
return this.db.query('SELECT * FROM roles WHERE id = $1', [id])
}
@CacheEvict({ key: (id) => `role:${id}` })
async updateRole(id: string, data: any) {
return this.db.update('roles', id, data)
}
}4. Automatic Database Transactions
import { Injectable, Transactional } from 'exisjs/decorators'
@Injectable()
export class OrderService {
constructor(private db: DatabaseService) {}
@Transactional()
async placeOrder(userId: string, items: CartItem[]) {
const order = await this.db.orders.create({ userId })
await this.db.inventory.decrement(items)
return order
}
}5. Performance Profiling
import { Injectable, Profile } from 'exisjs/decorators'
@Injectable()
export class ReportService {
@Profile({ thresholdMs: 100, warnSlow: true })
async generateReport() {
return this.calculateMetrics()
}
}6. Declarative Exception Filters
import { Catch, UseFilters, type ExceptionFilter, type ArgumentsHost } from 'exisjs/decorators'
import { NotFoundException } from 'exisjs/error'
@Catch(NotFoundException)
export class NotFoundFilter implements ExceptionFilter<NotFoundException> {
catch(exception: NotFoundException, host: ArgumentsHost) {
host.res.status(404).json({
code: 'NOT_FOUND',
message: exception.message,
})
}
}Full Changelog: v0.7.8...v0.7.9