Skip to content

Conversation

@bekam-bit
Copy link
Contributor

No description provided.

bella-247 and others added 14 commits December 11, 2025 01:41
- Introduced `ActuatorManager`, `ItemTracker`, `ProductionLine`, `SensorManager`, and `SimulationEngine` classes for managing automation processes.
- Implemented `DatabaseManager` for SQLite database interactions, including connection handling and CRUD operations.
- Created `ProductItem` entity to replace the deprecated `Product` class, enhancing item tracking capabilities.
- Developed `Logger` utility for logging events and errors within the system.
- Added `ConsoleApp` and `ConsoleUI` for user interaction and simulation control.
- Removed obsolete `EventLog` and `ProductRepository` classes to streamline the codebase.
- Updated package structure to follow consistent naming conventions.
feat: Add core automation components and database management
- Updated WeightSensor class to improve weight simulation and calibration logic.
- Enhanced the constructor to support initialization with explicit sensor ID.
- Implemented ClockObserver interface for better time-based weight updates.
- Refactored Repository class methods to streamline database interactions using a functional RowMapper.
- Improved SensorRepository to handle both TemperatureSensor and WeightSensor with appropriate database operations.
- Added safe getters for ResultSet to handle potential null values gracefully.
- Created new test and demo classes for sensor initialization and management.
- Introduced package-lock.json and package.json for dependency management.
Copilot AI review requested due to automatic review settings December 28, 2025 19:44
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR performs a major refactoring of the factory automation system, standardizing package naming conventions and introducing new sensor implementations with a clock-based simulation engine.

Key Changes:

  • Standardized package naming from org.Automation to org.automation (lowercase)
  • Introduced new sensor architecture with Sensor, TemperatureSensor, and WeightSensor classes implementing simulation clock observers
  • Refactored database layer with improved DatabaseManager and repository pattern
  • Added comprehensive test utilities and demo classes

Reviewed changes

Copilot reviewed 48 out of 52 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/main/java/org/automation/ui/ConsoleUI.java Updated package name to lowercase, cleaned up whitespace
src/main/java/org/automation/ui/ConsoleApp.java New file entirely commented out - complete sensor management UI implementation
src/main/java/org/automation/repositories/*.java Package rename and import path corrections for database layer
src/main/java/org/automation/entities/Sensor*.java New sensor implementations with clock-based simulation and lifecycle management
src/main/java/org/automation/engine/*.java New simulation engine and clock observer pattern implementation
src/main/java/org/automation/database/*.java Refactored database manager with improved query/mutator pattern
src/main/java/org/automation/controllers/SensorManager.java New centralized sensor management controller
src/main/java/org/automation/TestSensorManager.java New interactive test utility for sensor management
pom.xml Updated dependencies, removed JavaFX, added exec plugin configuration
Old org/Automation files Deleted old package structure files

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

public int getSensorId() { return sensorId; }
public String getSensorType() { return sensorType; }
public String getLocation() { return location; }
public String getStatus() { return status; }
Copy link

Copilot AI Dec 28, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This get method is unsynchronized, but the corresponding set method is synchronized.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants