There is already a method which you can use if you don't want to implement it yourself:
int[] nums = {1, 1, 1, 2, 3};
Arrays.parallelPrefix(nums,Integer::sum);
System.out.println(Arrays.toString(nums));
//[1, 2, 3, 5, 8]
This is useful if you also need to do other calculations than making cumulative sum. For example if you want to multiply the elements instead of adding them:
int[] nums = {1, 2, 3, 4, 5};
Arrays.parallelPrefix(nums, (i,j) -> i*j);
System.out.println(Arrays.toString(nums));
//[1, 2, 6, 24, 120]
From the doc Arrays.parallelPrefix for parallelPrefix(int[] array, IntBinaryOperator op) which accepts an int array (there are also overloaded methods for long[], double[] ...)
Cumulates, in parallel, each element of the given array in place, using the supplied function. For example if the array initially holds [2, 1, 0, 3] and the operation performs addition, then upon return the array holds [2, 3, 3, 6]. Parallel prefix computation is usually more efficient than sequential loops for large arrays.