PharmaFlow (PF)
Abstract
We will be creating a web-based application to streamline operations in medical stores, including medicine inventory management, billing, and customer orders. We can work on quality attributes like availability, scalability, deployable, security and modularity. Moreover, I think we can use Microservices architecture to ensure we can provide our quality attributes. Furthermore, we can divide components using the above mentioned archiecture and start working on them individually. Once we reach here, then we can think of further attributes like integrating some data analysis and reports for both users and staff (sales forecast).
We can make use of technologies like React, CSS for front end, Flask for APIs, SQLAlchemy or MySQL for database. Regarding trade offs, I think we might need to prioritise quality attributes like security, availability and reliability. Moreover, we must be open on hearing suggestions or any changes from every individual of our project to ensure better creativity and engagement. Thanks!
Author
Name: Aksh Garg
Student number: 49390764
Functionality
- A look at various flows:
- Signup & Verification → Staff/Members register → Verify account (Two Factor Authentication)→ Set up profile → Start using the application.
- Inventory Management → Add new medicine stock → Update stock details → Set alerts for low stock/expiry.
- Login & Customer Order Management → Create a new customer order → Generate invoice → Process billing → Complete order.
- Staff Management → Add/edit staff details → Manage roles & permissions.
- Reports → Generate sales reports → View medicine stock summary → Analyze order trends.
- Cancellation of order → Confirm customer details → Confirm Caccellation → Cancel Ordor
- Features
- New user signup & verification (OTP) via the web application.
- Manage profile and reset forgotten password.
- User friendly dashboard for easy navigation and control.
- Role-Based Access for staff and admin users.
- Medicine Inventory Management to track stock levels, expiry, and alerts.
- Automated alerts for low stock and upcoming expirations.
- Billing & Invoice Generation with customer order tracking.
- Sales Reports & Data Analysis to track monthly trends.
- Easy cancellation of the user’s order.
Scope
- User Authentication & Role-Based Access:
- Implement Two-Factor Authentication (2FA) for secure staff and member logins.
- Enforce Role-Based Access Control (RBAC) to restrict access based on user roles (e.g., Admin, Staff).
- User Dashboard & Inventory Management:
- Provide a dashboard displaying Pending and Completed orders with filter options.
- Enable users to add, update, and track medicine stock levels efficiently.
- Set up alerts for low stock and expiry reminders to prevent shortages.
- Order & Billing Management:
- Allow users to create, process, and manage orders.
- Automate invoice generation and ensure secure transaction processing.
- Implement an order cancellation flow with proper verification.
- Report Generation & Analytics:
- Generate HTML/PDF reports summarizing sales, stock trends, and order history.
- Provide data insights on medicine consumption patterns for better inventory forecasting.
Quality Attributes
Scalable
- Scalability is crucial for PharmaFlow (PF) to handle an increasing number of users, transactions, and inventory records without performance degradation. The system should dynamically scale up or down based on demand to ensure smooth operations.
- Scalability can be tested using load testing tools to simulate high traffic and analyze key metrics such as response time, request throughput, and error rate under different loads.
Reliability
- Reliability ensures that PharmaFlow consistently provides accurate inventory tracking, order processing, and billing without failures. A reliable system prevents errors in medicine stock management and order processing, ensuring smooth pharmacy operations.
- Reliability can be tested using functional tests, stress tests, and analyzing error rates in core operations like inventory updates and transactions.
Security
- Security is critical for PharmaFlow to protect sensitive pharmacy data, prevent unauthorized access, and safeguard transactions. Ensuring secure authentication, encryption, and data integrity is essential to maintaining trust.
- Security can be tested through penetration testing, vulnerability assessments, and monitoring authentication mechanisms.
Modularity
- Modularity is essential for PharmaFlow to ensure different system components, such as inventory, billing, and user management, operate independently. This approach enhances maintainability, flexibility, and scalability.
- Modularity can be tested by evaluating how well individual modules function separately and interact seamlessly with each other.
Availability
- Availability is essential for PharmaFlow as pharmacies rely on it for daily operations. Downtime could disrupt inventory management, order processing, and billing, leading to financial losses and customer dissatisfaction.
- Availability can be tested using uptime monitoring, failover simulations, and disaster recovery testing.
Evaluation
Scalable
- Determine maximum request throughput by measuring the number of orders and inventory updates the system can process per second.
- Analyze error rate during peak loads to identify performance bottlenecks.
- Ensure horizontal scaling of services like billing, inventory, and order processing to maintain optimal performance.
Reliability
- Run unit and functional tests to verify accurate order processing and inventory updates.
- Simulate heavy loads and check for consistent system behavior over time.
- Monitor error logs to identify and resolve potential issues.
- Compare actual vs. expected outputs in billing and inventory tracking to ensure data accuracy.
Security
- Monitor authentication & authorization success rates to prevent unauthorized access.
- Implement and test two-factor authentication (2FA) for enhanced security.
- Conduct security code reviews to identify and fix vulnerabilities such as SQL injection and XSS.
- Perform penetration testing to detect weaknesses and improve system security.
Modularity
- Analyze code structure and dependencies to ensure loosely coupled services.
- Assess maintainability by reviewing code complexity and readability.
- Verify unit and functional tests for each module to ensure independent operability.
Availability
- Analyze response times to ensure the system remains responsive under varying loads.
- Measure downtime impact and assess recovery mechanisms.
- Evaluate failover and redundancy systems to ensure seamless recovery from failures.