xieyi888 opened a new issue, #3033:
URL: https://github.com/apache/amoro/issues/3033

   ### What happened?
   
   1. Test environment, Upgrade amoro from 0.6 to master
   
   2.Start  AMS
   
   3.IndexOutOfBoundsException occurs
   ```
   2024-07-12 17:09:07,231 ERROR [main] 
[org.apache.amoro.server.AmoroServiceContainer] [] - AMS start error
   java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
        at java.util.ArrayList.rangeCheck(ArrayList.java:653) ~[?:1.8.0_91]
        at java.util.ArrayList.get(ArrayList.java:429) ~[?:1.8.0_91]
        at 
org.apache.amoro.server.persistence.TaskFilesPersistence.loadTaskInputs(TaskFilesPersistence.java:52)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at 
org.apache.amoro.server.optimizing.OptimizingQueue$TableOptimizingProcess.loadTaskRuntimes(OptimizingQueue.java:670)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at 
org.apache.amoro.server.optimizing.OptimizingQueue$TableOptimizingProcess.<init>(OptimizingQueue.java:395)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at 
org.apache.amoro.server.optimizing.OptimizingQueue.initTableRuntime(OptimizingQueue.java:116)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at java.util.ArrayList.forEach(ArrayList.java:1249) ~[?:1.8.0_91]
        at 
org.apache.amoro.server.optimizing.OptimizingQueue.<init>(OptimizingQueue.java:109)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at 
org.apache.amoro.server.DefaultOptimizingService.lambda$loadOptimizingQueues$0(DefaultOptimizingService.java:141)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at java.util.ArrayList.forEach(ArrayList.java:1249) ~[?:1.8.0_91]
        at 
org.apache.amoro.server.DefaultOptimizingService.loadOptimizingQueues(DefaultOptimizingService.java:131)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at 
org.apache.amoro.server.DefaultOptimizingService.access$300(DefaultOptimizingService.java:87)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at 
org.apache.amoro.server.DefaultOptimizingService$TableRuntimeHandlerImpl.initHandler(DefaultOptimizingService.java:460)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at 
org.apache.amoro.server.table.RuntimeHandlerChain.initialize(RuntimeHandlerChain.java:60)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at 
org.apache.amoro.server.table.DefaultTableService.initialize(DefaultTableService.java:324)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at 
org.apache.amoro.server.AmoroServiceContainer.startService(AmoroServiceContainer.java:150)
 ~[amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
        at 
org.apache.amoro.server.AmoroServiceContainer.main(AmoroServiceContainer.java:108)
 [amoro-ams-server-0.7-SNAPSHOT.jar:0.7-SNAPSHOT]
   ```
   
   4. under the test environment, no optimize processId  in table 
table_optimizing_process(don't know why it occurs), so it leads to 
IndexOutOfBoundsException.
   
![image](https://github.com/user-attachments/assets/d34fdd67-10b5-4877-ab57-571636f43704)
   
   ```
   mysql> SELECT rewrite_input FROM table_optimizing_process WHERE process_id 
=1710443014215;
   Empty set (0.01 sec)
   ```
   
   
   ### Affects Versions
   
   master
   
   ### What table formats are you seeing the problem on?
   
   _No response_
   
   ### What engines are you seeing the problem on?
   
   AMS
   
   ### How to reproduce
   
   _No response_
   
   ### Relevant log output
   
   _No response_
   
   ### Anything else
   
   _No response_
   
   ### Are you willing to submit a PR?
   
   - [X] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's Code of Conduct


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to