Produced by Araxis Merge on 5/1/2018 12:02:02 PM Central Daylight Time. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.
# | Location | File | Last Modified |
---|---|---|---|
1 | C:\AraxisMergeCompare\Pri_un\ZIP\JLV_2.6.2.0.3_src\jMeadows\src\main\java\gov\va\med\jmeadows\common | AppConfig.java | Thu Mar 29 22:08:33 2018 UTC |
2 | C:\AraxisMergeCompare\Pri_re\ZIP\JLV_2.6.2.0.3_src\jMeadows\src\main\java\gov\va\med\jmeadows\common | AppConfig.java | Tue May 1 13:46:15 2018 UTC |
Description | Between Files 1 and 2 |
|
---|---|---|
Text Blocks | Lines | |
Unchanged | 2 | 2186 |
Changed | 1 | 2 |
Inserted | 0 | 0 |
Removed | 0 | 0 |
Whitespace | |
---|---|
Character case | Differences in character case are significant |
Line endings | Differences in line endings (CR and LF characters) are ignored |
CR/LF characters | Not shown in the comparison detail |
No regular expressions were active.
1 | /** | |
2 | * Janus 4 .0 (c) | |
3 | * Copyrig ht (c) 201 1 Hawaii R esource Gr oup LLC. A ll Rights Reserved. | |
4 | * Develop ed for the Pacific T elehealth & Technolo gy Hui and the Pacif ic Joint I nformation Technolog y Center | |
5 | * Contrib utors: | |
6 | * Hon orable Sen ator Danie l K. Inouy e | |
7 | * VA Pacific Is lands Heal th Care Sy stem | |
8 | * Tri pler Army Medical Ce nter | |
9 | */ | |
10 | ||
11 | ||
12 | package go v.va.med.j meadows.co mmon; | |
13 | ||
14 | import gov .va.med.fo undations. utilities. EncryptUti l; | |
15 | import org .slf4j.Log ger; | |
16 | import org .slf4j.Log gerFactory ; | |
17 | ||
18 | import jav a.io.FileI nputStream ; | |
19 | import jav a.io.FileN otFoundExc eption; | |
20 | import jav a.io.IOExc eption; | |
21 | import jav a.io.Input Stream; | |
22 | import jav a.util.Pro perties; | |
23 | ||
24 | /** | |
25 | * Applica tion confi guration. | |
26 | * | |
27 | * User: D N S UYEHAC | |
28 | * Date: 8 /1/11 | |
29 | * Time: 1 0:24 AM | |
30 | */ | |
31 | public cla ss AppConf ig { | |
32 | ||
33 | /** | |
34 | * Log ger. | |
35 | */ | |
36 | privat e static f inal Logge r LOGGER = LoggerFac tory.getLo gger(AppCo nfig.class ); | |
37 | ||
38 | /** | |
39 | * CHC S site cod e. | |
40 | */ | |
41 | privat e static f inal Strin g LOCAL_CH CS_SITECOD E = "LOCAL _CHCS_SITE CODE"; | |
42 | ||
43 | /** | |
44 | * Vis tA site co de. | |
45 | */ | |
46 | privat e static f inal Strin g LOCAL_VI STA_SITECO DE = "LOCA L_VISTA_SI TECODE"; | |
47 | ||
48 | /** | |
49 | * jMe adows vers ion number . | |
50 | */ | |
51 | privat e static f inal Strin g APP_VERS ION = "app .version"; | |
52 | ||
53 | /** | |
54 | * jMe adows app environmen t. | |
55 | */ | |
56 | privat e static f inal Strin g APP_ENVI RONMENT = "app.envir onment"; | |
57 | ||
58 | /** | |
59 | * Dat asource. | |
60 | */ | |
61 | privat e static f inal Strin g APP_DATA SOURCE = " app.dataso urce"; | |
62 | ||
63 | /** | |
64 | * Env ironment. | |
65 | */ | |
66 | privat e static f inal Strin g ENV = "E NV"; | |
67 | ||
68 | /** | |
69 | * log 4j propert ies file p ath. | |
70 | */ | |
71 | privat e static f inal Strin g LOG4J_PR OPERTIES = "LOG4J_PR OPERTIES"; | |
72 | ||
73 | /** | |
74 | * CHC SWS endpoi nt. | |
75 | */ | |
76 | privat e static f inal Strin g CHCS_URL = "CHCS_U RL"; | |
77 | ||
78 | /** | |
79 | * Vis taDataServ ice endpoi nt. | |
80 | */ | |
81 | privat e static f inal Strin g VISTA_UR L = "VISTA _URL"; | |
82 | ||
83 | /** | |
84 | * MVI endpoint. | |
85 | */ | |
86 | privat e static f inal Strin g MVI_URL = "MVI_URL "; | |
87 | ||
88 | /** | |
89 | * MVI HL7 Messa ge Sender Device ID. | |
90 | */ | |
91 | privat e static f inal Strin g MVI_SND_ DEV_ID = " MVI_SND_DE V_ID"; | |
92 | ||
93 | /** | |
94 | * MVI search re sult quant ity. | |
95 | */ | |
96 | privat e static f inal Strin g MVI_SEAR CH_QTY = " MVI_SEARCH _QTY"; | |
97 | ||
98 | /** | |
99 | * Res trict VA u ser access to DoD-on ly patient informati on. | |
100 | */ | |
101 | privat e static f inal Strin g VA_USER_ RESTRICT = "VA_USER_ RESTRICT"; | |
102 | ||
103 | /** | |
104 | * All ow VA user access to DoD-only patient in formation (Audited a nd prompte d). | |
105 | */ | |
106 | privat e static f inal Strin g VA_USER_ ALLOW_REST RICT_ACCES S = "VA_US ER_ALLOW_R ESTRICT_AC CESS"; | |
107 | ||
108 | /** | |
109 | * PIX service e ndpoint. | |
110 | */ | |
111 | privat e static f inal Strin g PIX_URL = "PIX_URL "; | |
112 | ||
113 | /** | |
114 | * BHI ERelayServ ice endpoi nt. | |
115 | */ | |
116 | privat e static f inal Strin g BHIE_REL AY_SERVICE _URL = "BH IE_RELAY_S ERVICE_URL "; | |
117 | ||
118 | /** | |
119 | * ESS ENTRIS cus todian OID . | |
120 | */ | |
121 | privat e static f inal Strin g BHIE_CUS TODIAN_OID _ESS = "BH IE_CUSTODI AN_OID_ESS "; | |
122 | ||
123 | /** | |
124 | * TMD S custodia n OID. | |
125 | */ | |
126 | privat e static f inal Strin g BHIE_CUS TODIAN_OID _CHCS = "B HIE_CUSTOD IAN_OID_CH CS"; | |
127 | /** | |
128 | * SHA RE custodi an OID. | |
129 | */ | |
130 | privat e static f inal Strin g BHIE_CUS TODIAN_OID _SHARE = " BHIE_CUSTO DIAN_OID_S HARE"; | |
131 | /** | |
132 | * PDW SService e ndpoint * | |
133 | */ | |
134 | privat e static f inal Strin g PDWS_PS_ URL = "PDW S_PS_URL"; | |
135 | privat e static f inal Strin g PDWS_PR_ URL = "PDW S_PR_URL"; | |
136 | privat e static f inal Strin g PDWS_FS_ URL = "PDW S_FS_URL"; | |
137 | privat e static f inal Strin g PDWS_FR_ URL = "PDW S_FR_URL"; | |
138 | /** | |
139 | * PDW SService H L7 Message Header Pr ocessing C ode. | |
140 | */ | |
141 | privat e static f inal Strin g PDWS_PRO C_CODE = " PDWS_PROC_ CODE"; | |
142 | /** | |
143 | * PDW SService H L7 Message //Sender/ Device/id. | |
144 | */ | |
145 | privat e static f inal Strin g PDWS_SND _DEV_ID = "PDWS_SND_ DEV_ID"; | |
146 | ||
147 | /** | |
148 | * PDW SService S OAP DEBUG FLAG. | |
149 | */ | |
150 | privat e static f inal Strin g DEBUG_SO AP_OUTPUT = "DEBUG_S OAP_OUTPUT "; | |
151 | ||
152 | /** | |
153 | * CHC SWS encryp ted userna me. | |
154 | */ | |
155 | privat e static f inal Strin g CHCSWS_U SERNAME = "CHCSWS_US ERNAME"; | |
156 | /** | |
157 | * CHC SWS encryp ted pwd. | |
158 | */ | |
159 | privat e static f inal Strin g CHCSWS_P WD = "CHCS WS_PWD"; | |
160 | /** | |
161 | * BHI ERelayServ ice encryp ted userna me. | |
162 | */ | |
163 | privat e static f inal Strin g BHIE_REL AY_SERVICE _USERNAME = "BHIE_RE LAY_SERVIC E_USERNAME "; | |
164 | /** | |
165 | * BHI ERelayServ ice encryp ted pwd. | |
166 | */ | |
167 | privat e static f inal Strin g BHIE_REL AY_SERVICE _PWD = "BH IE_RELAY_S ERVICE_PWD "; | |
168 | ||
169 | /** | |
170 | * tru e to relax SSL v3 se curity req uirements. (Use this for debug ging purpo ses only!) . | |
171 | */ | |
172 | privat e static f inal Strin g IS_TRUST _ALL_SSL_H OSTNAMES_A ND_CERTS = "IS_TRUST _ALL_SSL_H OSTNAMES_A ND_CERTS"; | |
173 | /** | |
174 | * tru e to utili ze C3PO fo r as the s ql connect ion poolin g api. | |
175 | * If false, def aults to u tilizing J NDI lookup for conne ction pool . | |
176 | */ | |
177 | privat e static f inal Strin g USE_C3PO = "USE_C3 PO"; | |
178 | /** | |
179 | * SQL server JD BC connect ion string (for use with C3PO) . | |
180 | */ | |
181 | privat e static f inal Strin g SQL_URL = "SQL_URL "; | |
182 | /** | |
183 | * SQL server JD BC connect ion string (for use with C3PO) . | |
184 | */ | |
185 | privat e static f inal Strin g SQL_URL_ ENCRYPTED = "SQL_URL _ENCRYPTED "; | |
186 | /** | |
187 | * SQL server dr iver (for use with C 3PO). | |
188 | */ | |
189 | privat e static f inal Strin g SQL_DRIV ER = "SQL_ DRIVER"; | |
190 | /** | |
191 | * JDN I connecti on pooling lookup na me. | |
192 | */ | |
193 | privat e static f inal Strin g JNDI_JDB C = "JNDI_ JDBC"; | |
194 | /** | |
195 | * JDN I connecti on pooling lookup na me. | |
196 | */ | |
197 | privat e static f inal Strin g JNDI_JDB C_ENCRYPTE D = "JNDI_ JDBC_ENCRY PTED"; | |
198 | ||
199 | /** | |
200 | * Gen eral servi ce request timeout s etting in millisecon ds. | |
201 | */ | |
202 | privat e static f inal Strin g REQUEST_ TIMEOUT_MS = "REQUES T_TIMEOUT_ MS"; | |
203 | /** | |
204 | * Gen eral servi ce connect ion timeou t setting in millise conds. | |
205 | */ | |
206 | privat e static f inal Strin g CONNECTI ON_TIMEOUT _MS = "CON NECTION_TI MEOUT_MS"; | |
207 | /** | |
208 | * Gen eral threa d timeout in millise conds. | |
209 | */ | |
210 | privat e static f inal Strin g THREAD_T IMEOUT_MS = "THREAD_ TIMEOUT_MS "; | |
211 | ||
212 | /** | |
213 | * VLE R service request ti meout sett ing in mil liseconds. | |
214 | */ | |
215 | privat e static f inal Strin g VLER_REQ UEST_TIMEO UT_MS = "V LER_REQUES T_TIMEOUT_ MS"; | |
216 | /** | |
217 | * VLE R service connection timeout s etting in millisecon ds. | |
218 | */ | |
219 | privat e static f inal Strin g VLER_CON NECTION_TI MEOUT_MS = "VLER_CON NECTION_TI MEOUT_MS"; | |
220 | ||
221 | /** | |
222 | * Def ault error message s tring. | |
223 | */ | |
224 | privat e static f inal Strin g ERROR_MS G_CONNECTI ON_UNAVAIL ABLE = "ER ROR_MSG_CO NNECTION_U NAVAILABLE "; | |
225 | /** | |
226 | * Def ault edr s ervice rel ated error message s tring. | |
227 | */ | |
228 | privat e static f inal Strin g ERROR_MS G_EDR_DOCS = "ERROR_ MSG_EDR_DO CS"; | |
229 | ||
230 | /** | |
231 | * AHL TA custodi an OID. | |
232 | */ | |
233 | privat e static f inal Strin g BHIE_CUS TODIAN_OID _AHLTA = " BHIE_CUSTO DIAN_OID_A HLTA"; | |
234 | /** | |
235 | * VA custodian OID. | |
236 | */ | |
237 | privat e static f inal Strin g BHIE_CUS TODIAN_OID _VA = "BHI E_CUSTODIA N_OID_VA"; | |
238 | /** | |
239 | * TMD S custodia n OID. | |
240 | */ | |
241 | privat e static f inal Strin g BHIE_CUS TODIAN_OID _TMDS = "B HIE_CUSTOD IAN_OID_TM DS"; | |
242 | ||
243 | /** | |
244 | * FHI E custodia n OID. | |
245 | */ | |
246 | privat e static f inal Strin g BHIE_CUS TODIAN_OID _FHIE = "B HIE_CUSTOD IAN_OID_FH IE"; | |
247 | /** | |
248 | * Sit e code to return wit h BHIE err or beans ( utilized w hen BHIE c onnection is unavail able). | |
249 | */ | |
250 | privat e static f inal Strin g BHIE_ERR OR_SITE_CO DE = "BHIE _ERROR_SIT E_CODE"; | |
251 | /** | |
252 | * Sit e name to return wit h BHIE err or bean (u tilized wh en BHIE co nnection i s unavaila ble). | |
253 | */ | |
254 | privat e static f inal Strin g BHIE_ERR OR_SITE_NA ME = "BHIE _ERROR_SIT E_NAME"; | |
255 | /** | |
256 | * Sit e moniker to return with BHIE error bean (utilized when BHIE connectio n is unava ilable). | |
257 | */ | |
258 | privat e static f inal Strin g BHIE_ERR OR_SITE_MO NIKER = "B HIE_ERROR_ SITE_MONIK ER"; | |
259 | ||
260 | /** | |
261 | * The local VA facility's patient I EN OID - f or use wit h the PIX Service pa tient iden tifier map . | |
262 | * (2. 16.840.1.1 13883.3.42 .10006.100 005.8 for North Chic ago VA) | |
263 | */ | |
264 | privat e static f inal Strin g LOCAL_VA _IEN_OID = "LOCAL_VA _IEN_OID"; | |
265 | /** | |
266 | * Vis ta enterpr ise ICN OI D - for us e with the PIX Servi ce patient identifie r map. | |
267 | */ | |
268 | privat e static f inal Strin g VISTA_IC N_OID = "V ISTA_ICN_O ID"; | |
269 | /** | |
270 | * The DoD enter prise EDIP N (EDIPI) OID - for use with t he Pix Ser vice ident ifier map. | |
271 | */ | |
272 | privat e static f inal Strin g DOD_EDIP N_OID = "D OD_EDIPN_O ID"; | |
273 | ||
274 | /** | |
275 | * VA agency nam e string S hould be c onfigured as VA, | |
276 | */ | |
277 | privat e static f inal Strin g AGENCY_V A = "AGENC Y_VA"; | |
278 | /** | |
279 | * DOD agency na me string. Should be configure d as DOD, | |
280 | */ | |
281 | privat e static f inal Strin g AGENCY_D OD = "AGEN CY_DOD"; | |
282 | ||
283 | /** | |
284 | * Sit eMap's EHC ache name, | |
285 | */ | |
286 | privat e static f inal Strin g EHCACHE_ NAME_SITEM AP = "EHCA CHE_NAME_S ITEMAP"; | |
287 | ||
288 | /** | |
289 | * RPC endpoint environmen t (enterpr ise, hrg, etc.), | |
290 | */ | |
291 | privat e static f inal Strin g RPC_ENDP OINT_ENVIR ONMENT = " RPC_ENDPOI NT_ENVIRON MENT"; | |
292 | ||
293 | /** | |
294 | * CAC HE endpoin t environm ent (enter prise, hrg , etc.), | |
295 | */ | |
296 | privat e static f inal Strin g CACHE_EN DPOINT_ENV IRONMENT = "CACHE_EN DPOINT_ENV IRONMENT"; | |
297 | ||
298 | /** | |
299 | * Sha re endpoin t environm ent, | |
300 | */ | |
301 | privat e static f inal Strin g SHARE_EN DPOINT_ENV IRONMENT = "SHARE_EN DPOINT_ENV IRONMENT"; | |
302 | ||
303 | /** | |
304 | * Med web endpoi nt environ ment, | |
305 | */ | |
306 | privat e static f inal Strin g MEDWEB_E NDPOINT_EN VIRONMENT = "MEDWEB_ ENDPOINT_E NVIRONMENT "; | |
307 | privat e static f inal Strin g AHLTA_EN DPOINT_ENV IRONMENT = "AHLTA_EN DPOINT_ENV IRONMENT"; | |
308 | /** st atic const ants **/ | |
309 | privat e static f inal Strin g CONST_DO DADAPTER_S OURCE_STAT US_REPORT_ FLAG = "DO DADAPTER_S OURCE_STAT US_REPORT" ; | |
310 | privat e final st atic Strin g CONST_SY STEM_TYPE_ CHCS = "CH CS"; | |
311 | privat e final st atic Strin g CONST_SY STEM_TYPE_ VISTA = "V ISTA"; | |
312 | privat e final st atic Strin g CONST_SY STEM_TYPE_ SHARE = "S HARE"; | |
313 | privat e final st atic Strin g CONST_SY STEM_TYPE_ DOD_ADAPTE R = "DODAD APTER"; | |
314 | privat e final st atic Strin g IDENTIFI ER_UNAVAIL ABLE_FLAG = "IDENTIF IER_UNAVAI LABLE"; | |
315 | ||
316 | privat e final st atic Strin g CONST_SO URCE_PROTO COL_CACHE = "CACHE"; | |
317 | privat e final st atic Strin g CONST_SO URCE_PROTO COL_RPC = "RPC"; | |
318 | privat e final st atic Strin g CONST_SO URCE_PROTO COL_SHARE = "SHARE"; | |
319 | privat e final st atic Strin g CONST_SO URCE_PROTO COL_MEDWEB = "MEDWEB "; | |
320 | privat e final st atic Strin g CONST_SO URCE_PROTO COL_DOD_AD APTER = "D ODADAPTER" ; | |
321 | ||
322 | privat e final st atic Strin g USE_TERM _MAPPING_C ACHE = "US E_TERM_MAP PING_CACHE "; | |
323 | ||
324 | privat e final st atic Strin g LOAD_VLE R_SITE_CAC HE = "LOAD _VLER_SITE _CACHE"; | |
325 | ||
326 | privat e final st atic Strin g USE_SNAR EWORKS = " USE_SNAREW ORKS"; | |
327 | ||
328 | /** | |
329 | * DMI S IDs and facilities used for mapping DM IS IDs to clinic nam es for pat ient demog raphic's P CM clinic. | |
330 | */ | |
331 | privat e final st atic Strin g DMIS_FIL E_NAME = " DMIS_FILE_ NAME"; | |
332 | privat e final st atic Strin g DMIS_TOK EN_DELIM = "DMIS_TOK EN_DELIM"; | |
333 | privat e final st atic Strin g DMIS_ID_ TOKEN_POS = "DMIS_ID _TOKEN_POS "; | |
334 | privat e final st atic Strin g DMIS_NAM E_TOKEN_PO S = "DMIS_ NAME_TOKEN _POS"; | |
335 | ||
336 | privat e final st atic Strin g LAB_TYPE _CH = "LAB _TYPE_CH"; | |
337 | privat e final st atic Strin g LAB_TYPE _MI = "LAB _TYPE_MI"; | |
338 | privat e final st atic Strin g LAB_TYPE _AP = "LAB _TYPE_AP"; | |
339 | privat e final st atic Strin g LAB_TYPE _EM = "LAB _TYPE_EM"; | |
340 | privat e final st atic Strin g LAB_TYPE _SP = "LAB _TYPE_SP"; | |
341 | privat e final st atic Strin g LAB_TYPE _ST = "LAB _TYPE_ST"; | |
342 | privat e final st atic Strin g LAB_TYPE _CY = "LAB _TYPE_CY"; | |
343 | privat e final st atic Strin g LAB_TYPE _AU = "LAB _TYPE_AU"; | |
344 | privat e final st atic Strin g LAB_TYPE _BB = "LAB _TYPE_BB"; | |
345 | privat e final st atic Strin g LAB_TYPE _HIV = "LA B_TYPE_HIV "; | |
346 | ||
347 | privat e final st atic Strin g ENABLE_V IX_DOD_RAD IOLOGY_RET RIEVE = "E NABLE_VIX_ DOD_RADIOL OGY_RETRIE VE"; | |
348 | privat e final st atic Strin g VIX_DOD_ RAD_EXAM_I D_DELIM = "VIX_DOD_R AD_EXAM_ID _DELIM"; | |
349 | privat e final st atic Strin g VIX_ORPH ANED_KEYWO RD = "VIX_ ORPHANED_K EYWORD"; | |
350 | ||
351 | privat e final st atic Strin g USE_ENHA NCED_DEBUG = "USE_EN HANCED_DEB UG"; | |
352 | ||
353 | privat e final st atic Strin g LANGUAGE _CODE = "L ANGUAGE_CO DE"; | |
354 | privat e final st atic Strin g LANGUAGE _DESCRIPTI ON = "LANG UAGE_DESCR IPTION"; | |
355 | ||
356 | privat e final st atic Strin g DISABLE_ CACHED_THR EAD_POOL = "DISABLE_ CACHED_THR EAD_POOL"; | |
357 | privat e final st atic Strin g THREAD_K EEPALIVE_S ECONDS = " THREAD_KEE PALIVE_SEC ONDS"; | |
358 | privat e final st atic Strin g MAX_THRE ADPOOL_SIZ E = "MAX_T HREADPOOL_ SIZE"; | |
359 | privat e final st atic Strin g NUM_VDS_ REJECTED_R ETRIES = " NUM_VDS_RE JECTED_RET RIES"; | |
360 | privat e final st atic Strin g VDS_REJE CTED_RETRY _DELAY_MS = "VDS_REJ ECTED_RETR Y_DELAY_MS "; | |
361 | ||
362 | privat e static f inal AppCo nfig INSTA NCE = new AppConfig( ); | |
363 | ||
364 | privat e Properti es appProp erties; | |
365 | ||
366 | privat e AppConfi g() { | |
367 | ||
368 | ap pPropertie s = new Pr operties() ; | |
369 | ||
370 | lo adAppMetaP roperties( ); | |
371 | lo adAppConfi gPropertie s(); | |
372 | } | |
373 | ||
374 | privat e void loa dAppMetaPr operties() { | |
375 | St ring prope rtiesFile = "applica tion.prope rties"; | |
376 | ||
377 | In putStream inputStrea m = null; | |
378 | ||
379 | Cl assLoader classLoade r = AppCon fig.class. getClassLo ader(); | |
380 | if (classLoa der != nul l) { | |
381 | inputStr eam = clas sLoader.ge tResourceA sStream(pr opertiesFi le); | |
382 | } | |
383 | ||
384 | tr y { | |
385 | appPrope rties.load (inputStre am); | |
386 | } catch (IOE xception e ) { | |
387 | LOGGER.e rror("Fail ed load ap plication. properties : " + e.ge tMessage() ); | |
388 | throw ne w RuntimeE xception(e ); | |
389 | } finally { | |
390 | try { | |
391 | if ( inputStrea m != null) { | |
392 | inputStrea m.close(); | |
393 | } | |
394 | } catch (IOExcepti on e) { | |
395 | LOGG ER.error(e .getMessag e()); | |
396 | } | |
397 | } | |
398 | } | |
399 | ||
400 | privat e void loa dAppConfig Properties () { | |
401 | St ring prope rtiesFile = "jmeadow s.properti es"; | |
402 | ||
403 | In putStream inputStrea m = null; | |
404 | ||
405 | Cl assLoader classLoade r = AppCon fig.class. getClassLo ader(); | |
406 | if (classLoa der != nul l) { | |
407 | inputStr eam = clas sLoader.ge tResourceA sStream(pr opertiesFi le); | |
408 | } | |
409 | ||
410 | if (inputStr eam != nul l) { | |
411 | try { | |
412 | appP roperties. load(input Stream); | |
413 | } catch (IOExcepti on e) { | |
414 | LOGG ER.error(" Failed loa d appconfi g properti es: " + e. getMessage ()); | |
415 | thro w new Runt imeExcepti on(e); | |
416 | } finall y { | |
417 | try { | |
418 | inputStrea m.close(); | |
419 | } ca tch (IOExc eption e) { | |
420 | LOGGER.err or(e.getMe ssage()); | |
421 | } | |
422 | } | |
423 | } | |
424 | ||
425 | tr y { | |
426 | ||
427 | inputStr eam = new FileInputS tream(prop ertiesFile ); | |
428 | ||
429 | try { | |
430 | appP roperties. load(input Stream); | |
431 | } catch (IOExcepti on e) { | |
432 | LOGG ER.error(" Failed loa d appconfi g properti es: " + e. getLocaliz edMessage( )); | |
433 | thro w new Runt imeExcepti on(e); | |
434 | } finall y { | |
435 | try { | |
436 | inputStrea m.close(); | |
437 | } ca tch (IOExc eption e) { | |
438 | LOGGER.err or(e.getMe ssage()); | |
439 | } | |
440 | } | |
441 | ||
442 | } catch (Fil eNotFoundE xception e ) { | |
443 | LOGGER.i nfo("Faile d to load appconfig from file (jmeadows. properties ) -" | |
444 | + " utiliz ing defaul t appconfi g properti es."); | |
445 | ||
446 | } | |
447 | } | |
448 | ||
449 | // priv ate void l ogConfigs( ) | |
450 | // { | |
451 | // //log some jMeadows configurat ion values | |
452 | // logger.inf o("Local V A site cod e: {}", ge tLocalVASi teCode()); | |
453 | // logger.inf o("Local V A site nam e: {}", ge tLocalVASi teName()); | |
454 | // logger.inf o("Local V A site mon iker: {}", getLocalV ASiteMonik er()); | |
455 | // | |
456 | // logger.inf o("Local D oD site co de: {}", g etLocalDOD SiteCode() ); | |
457 | // logger.inf o("Local D oD site na me: {}", g etLocalDOD SiteName() ); | |
458 | // logger.inf o("Local D oD site mo niker {}", getLocalD ODSiteName ()); | |
459 | // | |
460 | // logger.inf o("MPI ena bled: {}", isMPIEnab led()); | |
461 | // logger.inf o("Pix ser vice enabl ed: {}", i sPIXServic eEnabled() ); | |
462 | ||
463 | // logger.inf o("Utilize MSI locat ion's url as webserv ice endpoi nt value: {}", useMS IEndpoint( )); | |
464 | // logger.inf o("Query u ser locati on using N PI enabled : {}", isP roviderNPI LocationQu eryEnabled ()); | |
465 | // | |
466 | // logger.inf o("CHCSWS endpoint: {}", getCH CSWSURL()) ; | |
467 | // logger.inf o("VistaDa taService endpoint: {}", getVi staWsURL() ); | |
468 | // logger.inf o("PIX ser vice endpo int: {}", getPIXURL( )); | |
469 | // logger.inf o("BHIERel ayService endpoint: {}", getBH IERelaySer viceURL()) ; | |
470 | // logger.inf o("JALFHCC alert ser vice endpo int: {}", getAlertSe rviceURL() ); | |
471 | // logger.inf o("DREnj e nabled: {} ", isDREnj ServiceEna bled()); | |
472 | // logger.inf o("DREnj U RL: {}", g etDREnjURL ()); | |
473 | // logger.inf o("SHARE e nabled: {} ", isShare ServiceEna bled()); | |
474 | // logger.inf o("SHARE U RL: {}", g etShareURL ()); | |
475 | // logger.inf o("PDWS UR L: {}", ge tPDWSURL() ); | |
476 | // | |
477 | // logger.inf o("BHIE al lergies en abled: {}" , isBHIEAl lergiesEna bled()); | |
478 | // logger.inf o("BHIE pr oblems lis t enabled: {}", isBH IEProblems Enabled()) ; | |
479 | // logger.inf o("BHIE pr ogress not es enabled : {}", isB HIEProgres sNotesEnab led()); | |
480 | // logger.inf o("BHIE di scharge su mmaries en abled: {}" + isBHIED ischargeSu mmariesEna bled()); | |
481 | // logger.inf o("BHIE vi tals enabl ed: {}", i sBHIEVital sEnabled() ); | |
482 | // logger.inf o("BHIE ap pointments enabled: {}", isBHI EAppointme ntsEnabled ()); | |
483 | // logger.inf o("BHIE co nsults ena bled: {}", isBHIECon sultsEnabl ed()); | |
484 | // logger.inf o("BHIE de mographics enabled: {}", isBHI EDemograph icDetailsE nabled()); | |
485 | // logger.inf o("BHIE de mographic details en abled: {}" , isBHIEDe mographicD etailsEnab led()); | |
486 | // logger.inf o("BHIE ou tpatient m edications enabled: {}", isBHI EOutpatien tMedicatio nsEnabled( )); | |
487 | // logger.inf o("BHIE in patient me dications enabled: { }" + isBHI EInpatient Medication sEnabled() ); | |
488 | // logger.inf o("BHIE ra diology re sults enab led: {}" + isBHIERad iologyEnab led()); | |
489 | // | |
490 | // logger.inf o("BHIE ut ilize pati ent EDIPN (EDIPI): { }", isBHIE UtilizePat ientEDIPN( )); | |
491 | // logger.inf o("BHIE CH CS namespa ce: {}", g etBHIECHCS Namespace( )); | |
492 | // } | |
493 | ||
494 | public static fi nal AppCon fig getIns tance() { | |
495 | re turn INSTA NCE; | |
496 | } | |
497 | ||
498 | /** | |
499 | * Sit e moniker to return with BHIE error bean (utilized when BHIE connectio n is unava ilable). | |
500 | */ | |
501 | public final Str ing getBHI EErrorSite Moniker() { | |
502 | re turn appPr operties.g etProperty (BHIE_ERRO R_SITE_MON IKER); | |
503 | } | |
504 | ||
505 | /** | |
506 | * jMe adows vers ion number . | |
507 | */ | |
508 | public final Str ing getApp Version() { | |
509 | re turn appPr operties.g etProperty (APP_VERSI ON); | |
510 | } | |
511 | ||
512 | public final Str ing getDat aSource() { | |
513 | re turn appPr operties.g etProperty (APP_DATAS OURCE); | |
514 | } | |
515 | ||
516 | /** | |
517 | * jMe adows app environmen t. | |
518 | */ | |
519 | public final Str ing getApp Environmen t() { | |
520 | re turn appPr operties.g etProperty (APP_ENVIR ONMENT); | |
521 | } | |
522 | ||
523 | /** | |
524 | * log 4j propert ies file p ath. | |
525 | */ | |
526 | public final Str ing getLog 4jProperti es() { | |
527 | re turn appPr operties.g etProperty (LOG4J_PRO PERTIES); | |
528 | } | |
529 | ||
530 | /** | |
531 | * CHC SWS endpoi nt. | |
532 | */ | |
533 | public final Str ing getCHC SWSURL() { | |
534 | re turn appPr operties.g etProperty (CHCS_URL) ; | |
535 | } | |
536 | ||
537 | /** BH IE/DoD ada pter clini cal domain enablemen t configur ations. BH IE use is for DoD da ta only, n ot VA. | |
538 | * Pl ease note that if BH IE IS enab led for a given doma in CHCS wi ll NOT be queried. | |
539 | * Li kewise, if BHIE is N OT enabled , CHCS is queried by default. | |
540 | **/ | |
541 | ||
542 | /** | |
543 | * Vis taDataServ ice endpoi nt. | |
544 | */ | |
545 | public final Str ing getVis taWsURL() { | |
546 | re turn appPr operties.g etProperty (VISTA_URL ); | |
547 | } | |
548 | ||
549 | /** | |
550 | * MVI endpoint. | |
551 | */ | |
552 | public final Str ing getMVI URL() { | |
553 | re turn appPr operties.g etProperty (MVI_URL); | |
554 | } | |
555 | ||
556 | /** | |
557 | * MVI HL7 Messa ge Sender Device ID. | |
558 | */ | |
559 | public final Str ing getMVI SndDevId() { return appPropert ies.getPro perty(MVI_ SND_DEV_ID ); } | |
560 | ||
561 | /** | |
562 | * MVI search re sult quant ity. | |
563 | */ | |
564 | public final int getMVISea rchQty() { return In teger.pars eInt(appPr operties.g etProperty (MVI_SEARC H_QTY)); } | |
565 | ||
566 | /** | |
567 | * Res trict VA u ser access to DoD-on ly patient informati on. | |
568 | */ | |
569 | public final Str ing getVaU serRestric t() { | |
570 | re turn appPr operties.g etProperty (VA_USER_R ESTRICT); | |
571 | } | |
572 | ||
573 | /** | |
574 | * All ow VA user access to DoD-only patient in formation (Audited a nd prompte d). | |
575 | */ | |
576 | public final Str ing getVaU serAllowRe strictAcce ss() { | |
577 | re turn appPr operties.g etProperty (VA_USER_A LLOW_RESTR ICT_ACCESS ); | |
578 | } | |
579 | ||
580 | /** | |
581 | * PIX service e ndpoint. | |
582 | */ | |
583 | public final Str ing getPIX URL() { | |
584 | re turn appPr operties.g etProperty (PIX_URL); | |
585 | } | |
586 | ||
587 | /** | |
588 | * BHI ERelayServ ice endpoi nt. | |
589 | */ | |
590 | public final Str ing getBHI ERelayServ iceURL() { | |
591 | re turn appPr operties.g etProperty (BHIE_RELA Y_SERVICE_ URL); | |
592 | } | |
593 | ||
594 | /** | |
595 | * PDW SService e ndpoint. | |
596 | */ | |
597 | public final Str ing getPdw sPsUrl() { | |
598 | re turn appPr operties.g etProperty (PDWS_PS_U RL); | |
599 | } | |
600 | public final Str ing getPdw sPrUrl() { return ap pPropertie s.getPrope rty(PDWS_P R_URL); } | |
601 | public final Str ing getPdw sFsUrl() { | |
602 | re turn appPr operties.g etProperty (PDWS_FS_U RL); | |
603 | } | |
604 | public final Str ing getPdw sFrUrl() { return ap pPropertie s.getPrope rty(PDWS_F R_URL); } | |
605 | ||
606 | /** | |
607 | * PDW SService e ndpoint. | |
608 | */ | |
609 | public final Str ing getPDW SProcCode( ) { | |
610 | re turn appPr operties.g etProperty (PDWS_PROC _CODE); | |
611 | } | |
612 | ||
613 | /** | |
614 | * PDW SService e ndpoint. | |
615 | */ | |
616 | public final Str ing getPDW SSndDevId( ) { | |
617 | re turn appPr operties.g etProperty (PDWS_SND_ DEV_ID); | |
618 | } | |
619 | ||
620 | /** | |
621 | * PDW SService d ebug flag. | |
622 | */ | |
623 | public final Str ing getPDW SDebugFlag () { | |
624 | re turn appPr operties.g etProperty (DEBUG_SOA P_OUTPUT); | |
625 | } | |
626 | ||
627 | ||
628 | /** | |
629 | * CHC SWS userna me. | |
630 | */ | |
631 | public final Str ing getCHC SWSUsernam e() { | |
632 | re turn Encry ptUtil.dec rypt(appPr operties.g etProperty (CHCSWS_US ERNAME)); | |
633 | } | |
634 | ||
635 | /** | |
636 | * CHC SWS pwd. | |
637 | */ | |
638 | public final Str ing getCHC SWSPasswor d() { | |
639 | re turn Encry ptUtil.dec rypt(appPr operties.g etProperty (CHCSWS_PW D)); | |
640 | } | |
641 | ||
642 | /** | |
643 | * BHI ERelayServ ice userna me. | |
644 | */ | |
645 | public final Str ing getBHI ERelayServ iceUsernam e() { | |
646 | re turn Encry ptUtil.dec rypt(appPr operties.g etProperty (BHIE_RELA Y_SERVICE_ USERNAME)) ; | |
647 | } | |
648 | ||
649 | /** | |
650 | * BHI ERelayServ ice pwd. | |
651 | */ | |
652 | public final Str ing getBHI ERelayServ icePasswor d() { | |
653 | re turn Encry ptUtil.dec rypt(appPr operties.g etProperty (BHIE_RELA Y_SERVICE_ PWD)); | |
654 | } | |
655 | ||
656 | /** | |
657 | * tru e to relax SSL v3 se curity req uirements. (Use this for debug ging purpo ses only!) . | |
658 | */ | |
659 | public final boo lean isTru stAllSSLHo stnameAndC erts() { | |
660 | re turn Boole an.valueOf (appProper ties.getPr operty(IS_ TRUST_ALL_ SSL_HOSTNA MES_AND_CE RTS)); | |
661 | } | |
662 | ||
663 | /** | |
664 | * tru e to utili ze C3PO fo r as the s ql connect ion poolin g api. | |
665 | * If false, def aults to u tilizing J NDI lookup for conne ction pool . | |
666 | */ | |
667 | public final boo lean useC3 PO() { | |
668 | re turn Boole an.valueOf (appProper ties.getPr operty(USE _C3PO)); | |
669 | } | |
670 | ||
671 | /** | |
672 | * SQL server JD BC connect ion string (for use with C3PO) . | |
673 | */ | |
674 | public final Str ing getSQL URL() { | |
675 | re turn appPr operties.g etProperty (SQL_URL); | |
676 | } | |
677 | ||
678 | /** | |
679 | * SQL server JD BC connect ion string (for use with C3PO) . | |
680 | */ | |
681 | public final Str ing getSQL URLEncrypt ed() { | |
682 | re turn appPr operties.g etProperty (SQL_URL_E NCRYPTED); | |
683 | } | |
684 | ||
685 | /** | |
686 | * SQL server dr iver (for use with C 3PO). | |
687 | */ | |
688 | public final Str ing getSQL Driver() { | |
689 | re turn appPr operties.g etProperty (SQL_DRIVE R); | |
690 | } | |
691 | ||
692 | /** | |
693 | * JDN I connecti on pooling lookup na me. | |
694 | */ | |
695 | public final Str ing getJDB C_JNDILook up() { | |
696 | re turn appPr operties.g etProperty (JNDI_JDBC ); | |
697 | } | |
698 | ||
699 | /** | |
700 | * JDN I connecti on pooling lookup na me. | |
701 | */ | |
702 | public final Str ing getJDB C_JNDILook upEncrypte d() { | |
703 | re turn appPr operties.g etProperty (JNDI_JDBC _ENCRYPTED ); | |
704 | } | |
705 | ||
706 | /** | |
707 | * Gen eral servi ce request timeout s etting in millisecon ds. | |
708 | */ | |
709 | public final int getReques tTimeoutMS () { | |
710 | re turn Integ er.parseIn t(appPrope rties.getP roperty(RE QUEST_TIME OUT_MS)); | |
711 | } | |
712 | ||
713 | /** | |
714 | * Gen eral servi ce connect ion timeou t setting in millise conds. | |
715 | */ | |
716 | public final int getConnec tionTimeou tMS() { | |
717 | re turn Integ er.parseIn t(appPrope rties.getP roperty(CO NNECTION_T IMEOUT_MS) ); | |
718 | } | |
719 | ||
720 | /** | |
721 | * Gen eral threa d timeout in millise conds. | |
722 | */ | |
723 | public final lon g getThrea dTimeoutMS () { | |
724 | re turn Long. parseLong( appPropert ies.getPro perty(THRE AD_TIMEOUT _MS)); | |
725 | } | |
726 | ||
727 | /** | |
728 | * VLE R service request ti meout sett ing in mil liseconds. | |
729 | */ | |
730 | public final int getVLERRe questTimeo utMS() { | |
731 | re turn Integ er.parseIn t(appPrope rties.getP roperty(VL ER_REQUEST _TIMEOUT_M S)); | |
732 | } | |
733 | ||
734 | /** | |
735 | * VLE R service connection timeout s etting in millisecon ds. | |
736 | */ | |
737 | public final int getVLERCo nnectionTi meoutMS() { | |
738 | re turn Integ er.parseIn t(appPrope rties.getP roperty(VL ER_CONNECT ION_TIMEOU T_MS)); | |
739 | } | |
740 | ||
741 | /** | |
742 | * BHI E custodia n OIDs. Ea ch OID rep resents a particular data site that BHIE aggregate s from. | |
743 | * The se custodi an OIDs ar e included as BHIE q uery inclu ded or exc luded site parameter s. | |
744 | */ | |
745 | ||
746 | /** | |
747 | * Def ault error message s tring. | |
748 | */ | |
749 | public final Str ing getErr orMsgConne ctionUnava ilable() { | |
750 | re turn appPr operties.g etProperty (ERROR_MSG _CONNECTIO N_UNAVAILA BLE); | |
751 | } | |
752 | ||
753 | /** | |
754 | * Def ault edr s ervice rel ated error message s tring. | |
755 | */ | |
756 | public final Str ing getErr orMsgEDRDo cs() { | |
757 | re turn appPr operties.g etProperty (ERROR_MSG _EDR_DOCS) ; | |
758 | } | |
759 | ||
760 | /** | |
761 | * AHL TA custodi an OID. | |
762 | */ | |
763 | public final Str ing getBHI ECustodian OidAHLTA() { | |
764 | re turn appPr operties.g etProperty (BHIE_CUST ODIAN_OID_ AHLTA); | |
765 | } | |
766 | ||
767 | /** | |
768 | * VA custodian OID. | |
769 | */ | |
770 | public final Str ing getBHI ECustodian OidVA() { | |
771 | re turn appPr operties.g etProperty (BHIE_CUST ODIAN_OID_ VA); | |
772 | } | |
773 | ||
774 | /** | |
775 | * TMD S custodia n OID. | |
776 | */ | |
777 | public final Str ing getBHI ECustodian OidTMDS() { | |
778 | re turn appPr operties.g etProperty (BHIE_CUST ODIAN_OID_ TMDS); | |
779 | } | |
780 | ||
781 | /** | |
782 | * FHI E custodia n OID. | |
783 | */ | |
784 | public final Str ing getBHI ECustodian OidFHIE() { | |
785 | re turn appPr operties.g etProperty (BHIE_CUST ODIAN_OID_ FHIE); | |
786 | } | |
787 | ||
788 | /** | |
789 | * ESS ENTRIS cus todian OID . | |
790 | */ | |
791 | public final Str ing getBHI ECustodian OidESS() { | |
792 | re turn appPr operties.g etProperty (BHIE_CUST ODIAN_OID_ ESS); | |
793 | } | |
794 | ||
795 | /** | |
796 | * CHC S custodia n OID. | |
797 | */ | |
798 | public final Str ing getBHI ECustodian OidCHCS() { | |
799 | re turn appPr operties.g etProperty (BHIE_CUST ODIAN_OID_ CHCS); | |
800 | } | |
801 | ||
802 | /** | |
803 | * SHA RE custodi an OID. | |
804 | */ | |
805 | public final Str ing getBHI ECustodian OidSHARE() { | |
806 | re turn appPr operties.g etProperty (BHIE_CUST ODIAN_OID_ SHARE); | |
807 | } | |
808 | ||
809 | /** | |
810 | * Sit e code to return wit h BHIE err or beans ( utilized w hen BHIE c onnection is unavail able). | |
811 | */ | |
812 | public final Str ing getBHI EErrorSite Code() { | |
813 | re turn appPr operties.g etProperty (BHIE_ERRO R_SITE_COD E); | |
814 | } | |
815 | ||
816 | /** | |
817 | * Sit e name to return wit h BHIE err or bean (u tilized wh en BHIE co nnection i s unavaila ble). | |
818 | */ | |
819 | public final Str ing getBHI EErrorSite Name() { | |
820 | re turn appPr operties.g etProperty (BHIE_ERRO R_SITE_NAM E); | |
821 | } | |
822 | ||
823 | /** | |
824 | * The local VA facility's patient I EN OID - f or use wit h the PIX Service pa tient iden tifier map . | |
825 | * (2. 16.840.1.1 13883.3.42 .10006.100 005.8 for North Chic ago VA) | |
826 | */ | |
827 | public final Str ing getLoc alVAIenOid () { | |
828 | re turn appPr operties.g etProperty (LOCAL_VA_ IEN_OID); | |
829 | } | |
830 | ||
831 | /** | |
832 | * Vis ta enterpr ise ICN OI D - for us e with the PIX Servi ce patient identifie r map. | |
833 | */ | |
834 | public final Str ing getVis taIcnOid() { | |
835 | re turn appPr operties.g etProperty (VISTA_ICN _OID); | |
836 | } | |
837 | ||
838 | public final Str ing getDOD EdipnOid() { | |
839 | re turn appPr operties.g etProperty (DOD_EDIPN _OID); | |
840 | } | |
841 | ||
842 | /** | |
843 | * VA agency nam e string S hould be c onfigured as VA | |
844 | */ | |
845 | public final Str ing getAge ncyVA() { | |
846 | re turn appPr operties.g etProperty (AGENCY_VA ); | |
847 | } | |
848 | ||
849 | /** | |
850 | * DOD agency na me string. Should be configure d as DOD | |
851 | */ | |
852 | public final Str ing getAge ncyDOD() { | |
853 | re turn appPr operties.g etProperty (AGENCY_DO D); | |
854 | } | |
855 | ||
856 | //meth ods that r eturn stat ic constan ts | |
857 | ||
858 | public final Str ing getDOD AdapterSou rceStatusR eportFlag( ) { | |
859 | re turn CONST _DODADAPTE R_SOURCE_S TATUS_REPO RT_FLAG; | |
860 | } | |
861 | ||
862 | public final Str ing getSys temTypeCHC S() { | |
863 | re turn CONST _SYSTEM_TY PE_CHCS; | |
864 | } | |
865 | ||
866 | public final Str ing getSys temTypeVIS TA() { | |
867 | re turn CONST _SYSTEM_TY PE_VISTA; | |
868 | } | |
869 | ||
870 | public final Str ing getCon stSystemTy peShare() { | |
871 | re turn CONST _SYSTEM_TY PE_SHARE; | |
872 | } | |
873 | ||
874 | public final Str ing getSys temTypeDOD Adapter() { | |
875 | re turn CONST _SYSTEM_TY PE_DOD_ADA PTER; | |
876 | } | |
877 | ||
878 | public final Str ing getSou rceProtoco lCache() { | |
879 | re turn CONST _SOURCE_PR OTOCOL_CAC HE; | |
880 | } | |
881 | ||
882 | public final Str ing getSou rceProtoco lRPC() { | |
883 | re turn CONST _SOURCE_PR OTOCOL_RPC ; | |
884 | } | |
885 | ||
886 | public final Str ing getSou rceProtoco lMedweb() { | |
887 | re turn CONST _SOURCE_PR OTOCOL_MED WEB; | |
888 | } | |
889 | ||
890 | public final Str ing getSou rceProtoco lDODAdapte r() { | |
891 | re turn CONST _SOURCE_PR OTOCOL_DOD _ADAPTER; | |
892 | } | |
893 | ||
894 | public final Str ing getSou rceProtoco lShare() { | |
895 | re turn CONST _SOURCE_PR OTOCOL_SHA RE; | |
896 | } | |
897 | ||
898 | public final Str ing getIde ntifierUna vailableFl ag() { | |
899 | re turn IDENT IFIER_UNAV AILABLE_FL AG; | |
900 | } | |
901 | ||
902 | public final Str ing getEHC acheNameSi teMap() { | |
903 | re turn appPr operties.g etProperty (EHCACHE_N AME_SITEMA P); | |
904 | } | |
905 | ||
906 | public final Str ing getRPC EndpointEn vironment( ) { | |
907 | re turn appPr operties.g etProperty (RPC_ENDPO INT_ENVIRO NMENT); | |
908 | } | |
909 | ||
910 | public final Str ing getCac heEndpoint Environmen t() { | |
911 | re turn appPr operties.g etProperty (CACHE_END POINT_ENVI RONMENT); | |
912 | } | |
913 | ||
914 | public final Str ing getSha reEndpoint Environmen t() { | |
915 | re turn appPr operties.g etProperty (SHARE_END POINT_ENVI RONMENT); | |
916 | } | |
917 | ||
918 | public final Str ing getMed webEndpoin tEnvironme nt() { | |
919 | re turn appPr operties.g etProperty (MEDWEB_EN DPOINT_ENV IRONMENT); | |
920 | } | |
921 | ||
922 | public final Str ing getAhl taEndpoint Environmen t() { | |
923 | re turn appPr operties.g etProperty (AHLTA_END POINT_ENVI RONMENT); | |
924 | } | |
925 | ||
926 | public final Str ing getLoc alCHCSSite Code() { | |
927 | re turn appPr operties.g etProperty (LOCAL_CHC S_SITECODE ); | |
928 | } | |
929 | ||
930 | public final Str ing getLoc alVistaSit eCode() { | |
931 | re turn appPr operties.g etProperty (LOCAL_VIS TA_SITECOD E); | |
932 | } | |
933 | ||
934 | /** | |
935 | * tru e to utili ze HashMap as cache for termin ology mapp ing. | |
936 | * If false, to utilize SQ L server f or mapping without h ashmap cac he. | |
937 | */ | |
938 | public final boo lean useTe rmMappingC ache() { | |
939 | re turn Boole an.valueOf (appProper ties.getPr operty(USE _TERM_MAPP ING_CACHE) ); | |
940 | } | |
941 | ||
942 | /** | |
943 | * Loa d mapping data from SQL Server on startu p. | |
944 | */ | |
945 | public final boo lean loadV LERSiteCac he() { | |
946 | re turn Boole an.valueOf (appProper ties.getPr operty(LOA D_VLER_SIT E_CACHE)); | |
947 | } | |
948 | ||
949 | /** | |
950 | * tru e to use s nareworks instead of database whitelist. | |
951 | */ | |
952 | public final boo lean useSn areworks() { | |
953 | re turn Boole an.valueOf (appProper ties.getPr operty(USE _SNAREWORK S)); | |
954 | } | |
955 | ||
956 | /** | |
957 | * DMI S IDs and facilities used for mapping DM IS IDs to clinic nam es for pat ient demog raphic's P CM clinic | |
958 | */ | |
959 | public final Str ing getDmi sFileName( ) { | |
960 | re turn appPr operties.g etProperty (DMIS_FILE _NAME); | |
961 | } | |
962 | public final Str ing getDmi sTokenDeli m() { | |
963 | re turn appPr operties.g etProperty (DMIS_TOKE N_DELIM); | |
964 | } | |
965 | public final int getDmisId TokenPos() { | |
966 | re turn Integ er.parseIn t(appPrope rties.getP roperty(DM IS_ID_TOKE N_POS)); | |
967 | } | |
968 | public final int getDmisNa meTokenPos () { | |
969 | re turn Integ er.parseIn t(appPrope rties.getP roperty(DM IS_NAME_TO KEN_POS)); | |
970 | } | |
971 | ||
972 | public final Str ing getLa bTypeCh() { | |
973 | re turn appPr operties.g etProperty (LAB_TYPE_ CH); | |
974 | } | |
975 | ||
976 | public final Str ing getLab TypeMi() { | |
977 | re turn appPr operties.g etProperty (LAB_TYPE_ MI); | |
978 | } | |
979 | ||
980 | public final Str ing getLab TypeAp() { | |
981 | re turn appPr operties.g etProperty (LAB_TYPE_ AP); | |
982 | } | |
983 | ||
984 | public final Str ing getLab TypeEm() { | |
985 | re turn appPr operties.g etProperty (LAB_TYPE_ EM); | |
986 | } | |
987 | ||
988 | public final Str ing getLab TypeSp() { | |
989 | re turn appPr operties.g etProperty (LAB_TYPE_ SP); | |
990 | } | |
991 | ||
992 | public final Str ing getLab TypeSt() { | |
993 | re turn appPr operties.g etProperty (LAB_TYPE_ ST); | |
994 | } | |
995 | ||
996 | public final Str ing getLab TypeCy() { | |
997 | re turn appPr operties.g etProperty (LAB_TYPE_ CY); | |
998 | } | |
999 | ||
1000 | public final Str ing getLab TypeAu() { | |
1001 | re turn appPr operties.g etProperty (LAB_TYPE_ AU); | |
1002 | } | |
1003 | ||
1004 | public final Str ing getLab TypeBb() { | |
1005 | re turn appPr operties.g etProperty (LAB_TYPE_ BB); | |
1006 | } | |
1007 | ||
1008 | public final Str ing getLab TypeHiv() { | |
1009 | re turn appPr operties.g etProperty (LAB_TYPE_ HIV); | |
1010 | } | |
1011 | ||
1012 | public final boo lean isVix DodRadiolo gyRetrieve Enabled() { | |
1013 | re turn Boole an.valueOf (appProper ties.getPr operty(ENA BLE_VIX_DO D_RADIOLOG Y_RETRIEVE , "false") ); | |
1014 | } | |
1015 | ||
1016 | public final Str ing getVix DodRadExam IdDelim() { | |
1017 | re turn appPr operties.g etProperty (VIX_DOD_R AD_EXAM_ID _DELIM, "# - "); | |
1018 | } | |
1019 | ||
1020 | public final Str ing getVix OrphanedKe yword() { | |
1021 | re turn appPr operties.g etProperty (VIX_ORPHA NED_KEYWOR D, "vastud y:"); | |
1022 | } | |
1023 | ||
1024 | /** | |
1025 | * @re turn the a ppProperti es | |
1026 | */ | |
1027 | public Propertie s getPrope rties() { | |
1028 | re turn appPr operties; | |
1029 | } | |
1030 | ||
1031 | public final Str ing getEnv () {return appProper ties.getPr operty(ENV );} | |
1032 | ||
1033 | /** | |
1034 | * tru e to use a ny enhance d debuggin g code | |
1035 | */ | |
1036 | public final boo lean useEn hancedDebu g() { | |
1037 | re turn Boole an.valueOf (appProper ties.getPr operty(USE _ENHANCED_ DEBUG)); | |
1038 | } | |
1039 | ||
1040 | public final Str ing getLan guageCode( ) { | |
1041 | re turn appPr operties.g etProperty (LANGUAGE_ CODE); | |
1042 | } | |
1043 | ||
1044 | public final Str ing getLan guageDescr iption() { | |
1045 | re turn appPr operties.g etProperty (LANGUAGE_ DESCRIPTIO N); | |
1046 | } | |
1047 | ||
1048 | /** | |
1049 | * tru e to disab le cached thread poo ls (unlimi ted size) | |
1050 | * If false, swi tches to f ixed threa d pools. | |
1051 | */ | |
1052 | public final boo lean disab leCachedTh readPool() { | |
1053 | re turn Boole an.valueOf (appProper ties.getPr operty(DIS ABLE_CACHE D_THREAD_P OOL)); | |
1054 | } | |
1055 | ||
1056 | /** | |
1057 | * Thr ead keep a live is us ed for the cached th read pools , it is ho w long a t hread stay s | |
1058 | * ali ve waiting for work. | |
1059 | */ | |
1060 | public final lon g getThrea dKeepalive Sec() { | |
1061 | re turn Long. parseLong( appPropert ies.getPro perty(THRE AD_KEEPALI VE_SECONDS )); | |
1062 | } | |
1063 | ||
1064 | public final int getMaxThr eadpoolSiz e() { | |
1065 | in t maxSize = 5000; | |
1066 | tr y { | |
1067 | maxSize = Integer. parseInt(a ppProperti es.getProp erty(MAX_T HREADPOOL_ SIZE)); | |
1068 | } catch (Num berFormatE xception n fe) { | |
1069 | LOGGER.e rror("Bad format MAX _THREADPOO L_SIZE set in proper ties, will use {}", maxSize); | |
1070 | } | |
1071 | re turn maxSi ze; | |
1072 | } | |
1073 | ||
1074 | public final int getNumVds RejectedRe tries() { | |
1075 | in t retries = 2; | |
1076 | tr y { | |
1077 | retries = Integer. parseInt(a ppProperti es.getProp erty(NUM_V DS_REJECTE D_RETRIES) ); | |
1078 | } catch (Num berFormatE xception n fe) { | |
1079 | LOGGER.e rror("Bad format NUM _VDS_REJEC TED_RETRIE S set in p roperties, will use {}", retri es); | |
1080 | } | |
1081 | re turn retri es; | |
1082 | } | |
1083 | ||
1084 | public final int getVdsRej ectedRetry DelayMs() { | |
1085 | in t waitTime Ms = 1000; | |
1086 | tr y { | |
1087 | waitTime Ms = Integ er.parseIn t(appPrope rties.getP roperty(VD S_REJECTED _RETRY_DEL AY_MS)); | |
1088 | } catch (Num berFormatE xception n fe) { | |
1089 | LOGGER.e rror("Bad format VDS _REJECTED_ RETRY_DELA Y_MS set i n properti es, will u se {}", wa itTimeMs); | |
1090 | } | |
1091 | re turn waitT imeMs; | |
1092 | } | |
1093 | ||
1094 | } |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.