Optimized path planning of robots are necessary for the industries to thrive towards greater flexibility and sustainability. This paper proposes an implementation of a collision-free path with the shortest distance. The novelty of the work presented is the new ARRT*(Adaptive Rapidly exploring Random Tree Star) algorithm, which is modified from the RRT*(Rapidly exploring Random Tree Star). In a constraint environment, RRT* algorithms tend to fail when searching for suitable collision-free paths. The proposed ARRT* algorithm gives an optimized feasible collision-free paths in a constraint environment. The feasibility to implement RRT* and ARRT* in a Multi Agent System as a path agent for online control of robots is demonstrated. We have created a digital twin simulated environment to find a collision-free path based on these two algorithms. The simulated path is tested in real robots for feasibility and validation purpose. During the real time implementation, we measured the following parameters: the algorithm computation time for generating a collision-free path, move along time of the path in real time, and energy consumed by each path. These parameters were measured for both the RRT* and the ARRT* algorithms and the test results were compared. The test results were showing that ARRT* performs better in a constrained environment. Both algorithms were tested in a Plug and Produce setup and we find that the generated paths for both algorithms are suitable for online path planning applications.