def spec
      if EasySwaggerUi.cache_enabled
        cache_key = "easy_swagger_ui:spec:#{params[:doc_path]}"
        options = {
          expires_in: EasySwaggerUi.cache_timeout,
          race_condition_ttl: 10,
        }
        spec = EasySwaggerUi.cache_store.fetch(cache_key, options) do
          parse_spec(params[:doc_path])
        end
      else
        spec = parse_spec(params[:doc_path])
      end
      render json: spec
    end
def spec
      if EasySwaggerUi.cache_enabled
        cache_key = "easy_swagger_ui:spec:#{params[:doc_path]}"
        options = {
          expires_in: EasySwaggerUi.cache_timeout,
          race_condition_ttl: 10,
        }
        spec = EasySwaggerUi.cache_store.fetch(cache_key, options) do
          parse_spec(params[:doc_path])
        end
      else
        spec = parse_spec(params[:doc_path])
      end
      render json: spec
    end
get '*doc_path.json'