410 response via irules

How can I right an irule to return 410 response for a specific URL.

when HTTP_REQUEST {
  if {[HTTP::uri] eq "/myspecificuri"} { HTTP::respond 410 content "410 Gone" Connection Close }
}

Thanks. That worked.

If any of the above posts have provided a solution to your issue, please indicate so by clicking the tick to the left of them. This gives feedback and recognition to the volunteers who responded to your issue.