class ModelBean {

    @POST
    @Produces({"application/xml", "text/xml", "application/json", "text/yaml", "text/x-yaml", "application/x-yaml", "application/x-protobuf",
            "application/x-protostuff"})
    @Path("/clone")
    @GZIP
    @RolesAllowed({"Administrator", "JBossAdministrator"})
    @Interceptors({RequiredInterceptor.class, ResponseInterceptor.class})
    public VoidResponse cloneModel(@Required("name") @FormParam("name") String name, @Required("newName") @FormParam("newName") String newName,
                    @FormParam("modelTableName") String modelTableName) {
        VoidResponse response = new VoidResponse();
        
        if (modelTableName == null) {
            modelTableName = defaultModelTableName;
        }
        
        datawave.webservice.model.Model model = getModel(name, modelTableName);
        // Set the new name
        model.setName(newName);
        importModel(model, modelTableName);
        return response;
    }

}