How azeebneuron/influconnect works
Main Components
• Frontend (Vue.js):
• This is represented by the directory “influencer-sponsor-platform” (housing Vue components, views, assets, router configuration, etc.).
• Contains various pages including Home, Login, Registration, Sponsor Dashboard, Influencer Dashboard, and Admin Dashboard.
• Backend (Flask):
• The Flask application is initiated via “app.py” and supports user authentication, API endpoints, and business logic.
• Includes additional scripts like “create_admin.py” for administrative setup.
• Database:
• An SQLite database is in use for storing user data, campaigns, and other relevant records.
• Task Queue & Message Broker:
• Celery is used for asynchronous tasks (e.g., exporting campaign data) that depend on RabbitMQ/Redis.
• Redis is specifically mentioned as the message broker (and is also used with Flask-Caching).
• Authentication and Security:
• JWT token-based security ensures secure authentication across the platform.
• Email Service (Optional):
• Configured via Flask’s mailing configuration, with support for a debugging SMTP server.
Relationships and Interactions
• The Frontend (Vue.js) communicates with the Backend (Flask) via RESTful API endpoints.
• The Flask backend handles authentication (with JWT), processes requests, performs CRUD operations on the SQLite database, and triggers asynchronous jobs using Celery.
• Celery interacts with Redis for queuing tasks (data export, notifications, etc.).
• Optionally, the Flask backend is configured to send emails via an SMTP server.
Architectural Patterns and Design Principles
• Separation of Concerns: The clear division between frontend and backend highlights a modern SPA architecture.
• Role-Based Access Control: The authentication flow uses JWT tokens for Admin, Sponsor, and Influencer users.
• Asynchronous Processing: The use of Celery with Redis is important for processing long-running tasks without blocking the user experience.
• Modular Component Design: The frontend structure (with separate views for sponsors, influencers, admin, and auth) indicates a component-based design (common in modern Vue.js applications).
Relevant Technologies and Frameworks
• Frontend: Vue.js 2, Vue Router; use of Babel, ESLint configuration.
• Backend: Flask (Python), along with libraries for caching (Flask-Caching), JWT security.
• Task Queue: Celery for background processing.
• Database: SQLite.
• Message Broker/Cache: Redis.
• Email: Python SMTP (debugging server for development) and possible environment variable configurations for production.