Cleanup: MB 2.0 Gap Analysis előtti állapot (adatok kizárva)
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -2,21 +2,33 @@
|
||||
from app.db.base_class import Base # noqa
|
||||
|
||||
# Közvetlen importok (HOZZÁADVA az audit és sales modellek)
|
||||
from app.models.address import Address, GeoPostalCode, GeoStreet, GeoStreetType, Branch # noqa
|
||||
from app.models.identity import User, Person, VerificationToken, Wallet # noqa
|
||||
from app.models.organization import Organization, OrganizationMember, OrganizationSalesAssignment # noqa
|
||||
from app.models.address import Address, GeoPostalCode, GeoStreet, GeoStreetType, Branch, Rating # noqa
|
||||
|
||||
from app.models.identity import Person, User, Wallet, VerificationToken, SocialAccount # noqa
|
||||
|
||||
from app.models.organization import Organization, OrganizationMember, OrganizationFinancials, OrganizationSalesAssignment # noqa
|
||||
|
||||
from app.models.service import ServiceProfile, ExpertiseTag, ServiceExpertise, ServiceStaging, DiscoveryParameter # noqa
|
||||
|
||||
from app.models.vehicle_definitions import VehicleType, VehicleModelDefinition, FeatureDefinition # noqa
|
||||
|
||||
from app.models.audit import SecurityAuditLog, OperationalLog, FinancialLedger # noqa <--- KRITIKUS!
|
||||
|
||||
from app.models.asset import ( # noqa
|
||||
Asset, AssetCatalog, AssetCost, AssetEvent,
|
||||
AssetFinancials, AssetTelemetry, AssetReview, ExchangeRate
|
||||
)
|
||||
from app.models.gamification import ( # noqa
|
||||
PointRule, LevelConfig, UserStats, Badge, UserBadge, Rating, PointsLedger
|
||||
)
|
||||
|
||||
from app.models.gamification import PointRule, LevelConfig, UserStats, Badge, UserBadge, PointsLedger # noqa
|
||||
|
||||
from app.models.system import SystemParameter # noqa (system.py használata)
|
||||
|
||||
from app.models.history import AuditLog, VehicleOwnership # noqa
|
||||
|
||||
from app.models.document import Document # noqa
|
||||
|
||||
from app.models.translation import Translation # noqa
|
||||
|
||||
from app.models.core_logic import ( # noqa
|
||||
SubscriptionTier, OrganizationSubscription, CreditTransaction, ServiceSpecialty
|
||||
)
|
||||
|
||||
@@ -3,11 +3,12 @@ from app.core.config import settings
|
||||
from typing import AsyncGenerator
|
||||
|
||||
engine = create_async_engine(
|
||||
settings.DATABASE_URL, # A te eredeti kulcsod
|
||||
echo=getattr(settings, "DEBUG", False),
|
||||
settings.DATABASE_URL,
|
||||
echo=False, # Termelésben ne legyen True a log-áradat miatt
|
||||
future=True,
|
||||
pool_size=20,
|
||||
max_overflow=10
|
||||
pool_size=30, # Megemelve a Researcher 15-20 szála miatt
|
||||
max_overflow=20, # Extra rugalmasság csúcsidőben
|
||||
pool_pre_ping=True # Megakadályozza a "Server closed connection" hibákat
|
||||
)
|
||||
|
||||
AsyncSessionLocal = async_sessionmaker(
|
||||
@@ -16,7 +17,7 @@ AsyncSessionLocal = async_sessionmaker(
|
||||
expire_on_commit=False,
|
||||
autoflush=False
|
||||
)
|
||||
# Ez a sor kell, mert a main.py és a többiek ezen a néven keresik
|
||||
|
||||
SessionLocal = AsyncSessionLocal
|
||||
|
||||
async def get_db() -> AsyncGenerator[AsyncSession, None]:
|
||||
|
||||
Reference in New Issue
Block a user