add debugging for terminology cache issue
This commit is contained in:
parent
e3faaa5ccc
commit
590a4d48b1
|
@ -3304,7 +3304,7 @@ public class ProfileUtilities extends TranslatingUtilities {
|
||||||
p = Utilities.uncapitalize(p);
|
p = Utilities.uncapitalize(p);
|
||||||
StructureDefinition sd = context.fetchResource(StructureDefinition.class, sdNs(p));
|
StructureDefinition sd = context.fetchResource(StructureDefinition.class, sdNs(p));
|
||||||
if (sd == null)
|
if (sd == null)
|
||||||
throw new Error("Unable to find profile "+p);
|
throw new Error("Unable to find profile '"+p+"' at "+ed.getId());
|
||||||
ccmp = new ElementDefinitionComparer(false, sd.getSnapshot().getElement(), p, child.getSelf().getPath().length(), cmp.name);
|
ccmp = new ElementDefinitionComparer(false, sd.getSnapshot().getElement(), p, child.getSelf().getPath().length(), cmp.name);
|
||||||
} else if (child.getSelf().hasType() && child.getSelf().getType().get(0).getCode().equals("Reference")) {
|
} else if (child.getSelf().hasType() && child.getSelf().getType().get(0).getCode().equals("Reference")) {
|
||||||
for (TypeRefComponent t: child.getSelf().getType()) {
|
for (TypeRefComponent t: child.getSelf().getType()) {
|
||||||
|
|
|
@ -327,12 +327,14 @@ public class TerminologyCache {
|
||||||
NamedCache nc = new NamedCache();
|
NamedCache nc = new NamedCache();
|
||||||
nc.name = title;
|
nc.name = title;
|
||||||
caches.put(title, nc);
|
caches.put(title, nc);
|
||||||
|
System.out.print(" - load "+title+".cache");
|
||||||
String src = TextFile.fileToString(Utilities.path(folder, fn));
|
String src = TextFile.fileToString(Utilities.path(folder, fn));
|
||||||
if (src.startsWith("?"))
|
if (src.startsWith("?"))
|
||||||
src = src.substring(1);
|
src = src.substring(1);
|
||||||
int i = src.indexOf(ENTRY_MARKER);
|
int i = src.indexOf(ENTRY_MARKER);
|
||||||
while (i > -1) {
|
while (i > -1) {
|
||||||
String s = src.substring(0, i);
|
String s = src.substring(0, i);
|
||||||
|
System.out.print(".");
|
||||||
src = src.substring(i+ENTRY_MARKER.length()+1);
|
src = src.substring(i+ENTRY_MARKER.length()+1);
|
||||||
i = src.indexOf(ENTRY_MARKER);
|
i = src.indexOf(ENTRY_MARKER);
|
||||||
if (!Utilities.noString(s)) {
|
if (!Utilities.noString(s)) {
|
||||||
|
@ -360,6 +362,7 @@ public class TerminologyCache {
|
||||||
nc.list.add(ce);
|
nc.list.add(ce);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
System.out.println("done");
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new FHIRException("Error loading "+fn+": "+e.getMessage(), e);
|
throw new FHIRException("Error loading "+fn+": "+e.getMessage(), e);
|
||||||
}
|
}
|
||||||
|
|
|
@ -569,7 +569,7 @@ public class Utilities {
|
||||||
for(String arg: args) {
|
for(String arg: args) {
|
||||||
if (!d)
|
if (!d)
|
||||||
d = !noString(arg);
|
d = !noString(arg);
|
||||||
else if (!s.toString().endsWith("/"))
|
else if (!s.toString().endsWith("/") && !arg.startsWith("/"))
|
||||||
s.append("/");
|
s.append("/");
|
||||||
s.append(arg);
|
s.append(arg);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue