Berth allocation is a critical concern in container terminal port logistics, involving the precise determination of where and when arriving vessels should dock along a quay. With berth space limitations and a continuous surge in container handling demands, ensuring an effective berth allocation is paramount for the smooth and efficient operation of container ports. However, due to the randomness of vessel arrival times and uncertainties surrounding container ship loading capacities, berth allocation problems (BAP) often present discrete and dynamic challenges. This paper addresses these challenges by considering real-world terminal operational factors, formulating relevant assumptions, and establishing a model for dynamic berth allocation and efficient ship berthing scheduling. The primary motivation stems from the parallels observed between the BAP problem and ant foraging path selection, leading to the proposal of a novel Parallel Search Structure Enhanced Ant Colony Algorithm (PACO). A proper set of parameters of the algorithm are selected based upon sensitivity analyses on the convergence and parallelism efficiency of the algorithm. To validate our method, a real-world case-container terminal operation in Shanghai Port was studied. The experimental comparison results show that the PACO algorithm outperforms other commonly used algorithms, making it more effective and efficient for the Discrete Dynamic Berth Allocation Problem (DDBAP).