You cannot respond to an atrocity in which innocent civilians were murdered by committing another atrocity that murders more innocent civilians.
It seems to me that it is quite a major security failure by Israel. They have not managed to protect their border with sufficient personnel on the ground. They have already started bombing Gaza, and this is already killing/wounding many innocent people. You cannot bomb urban areas without killing and wounding innocent people. Whether they are attempting to target militants or not is irrelevant, it cannot be done without collateral casualties. It is a totally ineffective response, and something of a knee jerk reaction from the military, who has dented pride through its defensive failures. It will only stoke the fires of further militancy. Israel would be better to focus on correcting its defensive failures than to start bombing, which will kill more innocent civilians, and will achieve nothing.