Commit 070b16da by Adi Amir

change configuration

parent 384a7c87
......@@ -4,7 +4,7 @@
"apiList": [{
"id": "getroutes",
"method": "GET",
"uri": "getroutes",
"path": "getroutes",
"QueryParams": [{
"key": "$config$chicago.transportation.key"
}]
......
{
"adapters": [{
"id": "chicago.transportationn",
"instance": "CHttpAdapter:jarName",
"configFile": "chicago.transportation.json"
"id": "adapter.chicago.transportation",
"instance": "HttpAdapter:myAdapter.jar",
"configFile": "adapter.chicago.transportation.json"
}]
}
\ No newline at end of file
......@@ -7,3 +7,5 @@ log4j.prop.file.path=/logs/conf/log4j.xml
server.port=50040
server.host=0.0.0.0
server.worker.threads=6
chicago.transportation.key=gT2nciTKwRv6Jy5njqm8fe7LW
\ No newline at end of file
......@@ -3,7 +3,7 @@
"apiId": "getroutes",
"actions": [{
"id": "forwardRequest",
"adapterId": "chicago.transportation",
"adapterId": "adapter.chicago.transportation",
"apiId": "getroutes",
"Responses": [{
"code": "*",
......
......@@ -58,7 +58,7 @@ file(adapter api(s)): chicago.transportation.json
Flow
====
http://www.ctabustracker.com/bustime/api/v1/getroutes?key=gT2nciTKwRv6Jy5njqm8fe7LW
GET http://www.ctabustracker.com/bustime/api/v1/getroutes?key=gT2nciTKwRv6Jy5njqm8fe7LW
GET ../mde/{tenantId}/{serviceId}/{apiId}
......
package logic;
import logic.adapter.BaseAdapter;
import logic.adapter.HttpAdapter.HttpAdapter;
import microservice.io.iface.ILogger;
import java.util.Map;
/**
* Created by eli on 6/7/16.
*/
......@@ -11,6 +15,8 @@ public class MdeManager {
private ILogger logger = null;
private int currentNumber = 0;
Map<String, BaseAdapter> AdapterList = null;
public MdeManager(ILogger logger) {
try{
this.logger = logger;
......@@ -20,4 +26,14 @@ public class MdeManager {
}
}
public void LoadServices() {
}
public void LoadAdapters() {
HttpAdapter httpAdapter = new HttpAdapter();
AdapterList.put("aaa", httpAdapter);
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment