This repository was archived by the owner on Dec 16, 2025. It is now read-only.
Description Current micro-services code has hard-coded server/port information in the config file. Example. from ,employee_service/config/configuration we see,
17 module.exports = {
18 'db_url': process.env.MONGO_SERVER_URL || 'mongodb://127.0.0.1:27017/node-els-db',
19 'employee_svc_port' : process.env.EMPLOYEE_SERVER_PORT || 3000,
20 'address_svc' : 'http://localhost:3001/addresses ',
21 'address_svc_byzipcode' : 'http://localhost:3001/addresses/zipcode ',
22 'address_svc_byemployeeid' : 'http://localhost:3001/addresses/:employee_id ',
23 'family_svc' : 'http://localhost:3002/families ',
24 'family_svc_byemployeeid' : 'http://localhost:3002/families/:employee_id ',
25 'health_svc' : 'http://localhost:3003/health ',
26 'health_svc_byemployeeid' : 'http://localhost:3003/health/:employee_id ',
27 'compensation_svc' : 'http://localhost:3004/compensations ',
28 'compensation_svc_byemployeeid' : 'http://localhost:3004/compensations/:employee_id ',
29 'photo_svc' : 'http://localhost:3005/photos ',
30 'photo_svc_byemployeeid' : 'http://localhost:3005/photos/:employee_id ',
31 'db_loader_svc_ipaddress' : 'http://localhost:4001/loaddb ',
32 'checkdb_svc_ipaddress' : 'http://localhost:4001/checkdb ',
33 'app_mode' : 'Micro-services',
34 'mongodb_timeout' : 30000
35 };
Making this dynamic would be really helpful for real deployment and testing.