As there are microstructure issues with the commodity market, e.g. the Goldman roll, is there any research on when it is optimal to monthly rebalance?
Yes, considerable. My old firm did loads of it. However knowing that the research exists is not the same as getting hold of it or using it.
In general we could say that it is going to be a good place to start by avoiding periods where there is limited liquidity. In many commodity futures contracts, these are usually seasonal. In general I can also tell you that there isn't one point every month that is a "good" time in this respect, and in many cases it isn't even every month.
My old firm took the approach of rebalancing the portfolio every night after all the settlement closes were known, and then treating rolling out of "soon to expire" contract expiries as separate issues. The contract "rolls" were at most monthly, and at least 6 monthly. This approach is fairly straightforward to engineer into an algorithm that can be consistently applied and backtested on historic data.
To avoid "churn" on limited liquidity contracts, the portfolio rebalance trades were subject to some histeresis. That is to say, we set minimum trade size thresholds and didn't trade until these were exceeded. This saved trade costs vs holding optimum positions, but in some markets this was a net positive.