1. A computer program product for identifying universal resource locator rewriting rules, the computer program product comprising: a non-transitory computer readable storage medium including computer executable program code stored thereon, the computer executable program code comprising: computer executable program code for receiving input of universal resource locators of an application, to form received universal resource locators; computer executable program code for representing the received universal resource locators in a graph; computer executable program code for applying analysis algorithms and heuristics to properties of the graph; computer executable program code for identifying universal resource locator rewriting patterns using the graph to form detected patterns, including if a switch has a complexity value greater than a predetermined value “Q”, grouping identified switches into Left Switches and Right Switches according to a connection set; and computer executable program code for generating rewrite rules corresponding to the detected patterns.