Source:
<code>private void addProcedure(MetadataFactory mf, String key, Path path) { for(Entry<HttpMethod, Operation> entry : path.getOperationMap().entrySet()){ String action = entry.getKey().toString(); Operation operation = entry.getValue(); String procName = operation.getOperationId(); String produces = getProduceTypes(operation); String consumes = getConsumeTypes(operation); String annotation = getOperationSummary(operation); Procedure procedure = mf.addProcedure(procName); procedure.setVirtual(false); procedure.setNameInSource(procName); procedure.setProperty(HTTP_ACTION, action); procedure.setProperty(HTTP_API_PATH, key); procedure.setProperty(BASE_URL, baseUrl); procedure.setProperty(HTTP_HOST, httpHost); procedure.setProperty(PROCEDURE_PRODUCES, produces); procedure.setProperty(PROCEDURE_CONSUMES, consumes); procedure.setAnnotation(annotation); mf.addProcedureParameter("result", TypeFacility.RUNTIME_NAMES.BLOB, Type.ReturnValue, procedure); addProcedureParameter(mf, procedure, operation); <START> ProcedureParameter param = mf.addProcedureParameter("headers", TypeFacility.RUNTIME_NAMES.CLOB, Type.In, procedure); END> param.setAnnotation("Headers to send"); param.setNullType(NullType.Nullable); param = mf.addProcedureParameter("contentType", TypeFacility.RUNTIME_NAMES.STRING, Type.Out, procedure); param.setAnnotation("return contentType"); param.setNullType(NullType.Nullable); } }</code><technical_language>"headers" input parameters in Swagger define behavior of call? I is user need enter specific data for headers? If yes, need collect of input parameter. if no, need collect needs for header properties send execution time. enter a clob is good usability wise</technical_language>

Target:
private void addProcedure(MetadataFactory mf, String key, Path path) { for(Entry<HttpMethod, Operation> entry : path.getOperationMap().entrySet()){ String action = entry.getKey().toString(); Operation operation = entry.getValue(); String procName = operation.getOperationId(); String produces = getProduceTypes(operation); String consumes = getConsumeTypes(operation); String annotation = getOperationSummary(operation); Procedure procedure = mf.addProcedure(procName); procedure.setVirtual(false); procedure.setNameInSource(procName); procedure.setProperty(HTTP_ACTION, action); procedure.setProperty(HTTP_API_PATH, key); procedure.setProperty(BASE_URL, baseUrl); procedure.setProperty(HTTP_HOST, httpHost); procedure.setProperty(PROCEDURE_PRODUCES, produces); procedure.setProperty(PROCEDURE_CONSUMES, consumes); procedure.setAnnotation(annotation); addProcedureParameter(mf, procedure, operation); ProcedureParameter param = mf.addProcedureParameter("headers", TypeFacility.RUNTIME_NAMES.CLOB, Type.In, procedure); param.setAnnotation("Headers to send"); param.setNullType(NullType.Nullable); Map<String, Response> respMap = operation.getResponses(); Response resp = respMap.get("200"); if(isRef(resp)){ Model model = getReferenceModel(resp.getSchema()); String returnType = resp.getSchema().getType(); if(null != model){ ModelWrapper wrapper = new ModelWrapper(null, this.definitions, model); for(Entry<String, Property> column : wrapper.getProperties().entrySet()){ String name = column.getKey(); Property prop = column.getValue(); String type = SwaggerTypeManager.teiidType(prop.getType(), prop.getFormat()); mf.addProcedureResultSetColumn(name, type, procedure); } procedure.setProperty(PROCEDURE_RETURN, returnType); } } else { mf.addProcedureParameter("result", TypeFacility.RUNTIME_NAMES.OBJECT, Type.ReturnValue, procedure); } } }