Skip to content

Commit

Permalink
updated config to be compatible with latest HOCON
Browse files Browse the repository at this point in the history
  • Loading branch information
ChemMitch committed Nov 8, 2024
1 parent ff96939 commit 2ebe70f
Show file tree
Hide file tree
Showing 4 changed files with 78 additions and 22 deletions.
26 changes: 19 additions & 7 deletions gsrs-module-substance-example/src/main/resources/application.conf
Original file line number Diff line number Diff line change
Expand Up @@ -25,29 +25,41 @@ ix.authentication.logheaders=false
#logging.level.org.hibernate.type.descriptor.sql.BasicBinder=TRACE
logging.level.gsrs.module.substance.scrubbers.basic=trace

gsrs.matchableCalculators.substances =
[
gsrs.matchableCalculators.substances.list.CASNumberMatchableExtractor =

{"matchableCalculationClass" : "gsrs.dataexchange.extractors.CASNumberMatchableExtractor",
"config" :{
"casCodeSystems": ["CAS", "CASNo", "CASNumber"]
}
},
}

gsrs.matchableCalculators.substances.list.AllNamesMatchableExtractor=
{"matchableCalculationClass" : "gsrs.dataexchange.extractors.AllNamesMatchableExtractor","config" :{}},

gsrs.matchableCalculators.substances.list.ApprovalIdMatchableExtractor=
{"matchableCalculationClass" : "gsrs.dataexchange.extractors.ApprovalIdMatchableExtractor","config" :{}},
{"matchableCalculationClass" : "gsrs.dataexchange.extractors.DefinitionalHashMatchableExtractor","config" :{}},

gsrs.matchableCalculators.substances.list.DefinitionalHashMatchableExtractor=
{"matchableCalculationClass" : "gsrs.dataexchange.extractors.DefinitionalHashMatchableExtractor","config" :{}}

gsrs.matchableCalculators.substances.list.SelectedCodesMatchableExtractor=
{"matchableCalculationClass" : "gsrs.dataexchange.extractors.SelectedCodesMatchableExtractor",
"config" :
{
"codeSystems" :["CAS", "ChemBL", "NCI", "NSC", "EINECS"]
}
},
{"matchableCalculationClass" : "gsrs.dataexchange.extractors.UUIDMatchableExtractor","config" :{}},
}

gsrs.matchableCalculators.substances.list.UUIDMatchableExtractor=
{"matchableCalculationClass" : "gsrs.dataexchange.extractors.UUIDMatchableExtractor","config" :{}}

gsrs.matchableCalculators.substances.list.CodeMatchableExtractor =
{"matchableCalculationClass" : "gsrs.dataexchange.extractors.CodeMatchableExtractor",
"config" :{
"reqCodeSystems": ["FDA UNII"],
"codeType": "PRIMARY",
"codeKey": "CODE"
}
}
]


Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ ix.ginas.export.factories.substances =[

ix.ginas.approvalIdGenerator.generatorClass=ix.ginas.utils.UNIIGenerator

gsrs.validators.substances.BdNumModificationValidator= {
gsrs.validators.substances.list.BdNumModificationValidator= {
"validatorClass" = "fda.gsrs.substance.validators.BdNumModificationValidator",
"newObjClass" = "ix.ginas.models.v1.Substance",
"order"=4000
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ gsrs.standardizers.substances = {
}
}

gsrs.importAdapterFactories.substances.SDFImportAdapterFactory =
gsrs.importAdapterFactories.substances.list.SDFImportAdapterFactory =
{
"adapterName": "SDF Adapter",
"order" : 10,
Expand Down Expand Up @@ -304,7 +304,7 @@ gsrs.importAdapterFactories.substances.SDFImportAdapterFactory =
}
}

gsrs.importAdapterFactories.substances.DelimTextImportAdapterFactory ={
gsrs.importAdapterFactories.substances.list.DelimTextImportAdapterFactory ={
"adapterName": "Delimited Text Adapter",
"order" : 40,
"importAdapterFactoryClass": "gsrs.module.substance.importers.DelimTextImportAdapterFactory",
Expand Down Expand Up @@ -439,7 +439,7 @@ gsrs.importAdapterFactories.substances.DelimTextImportAdapterFactory ={
}
}

gsrs.importAdapterFactories.substances.ExcelFileImportAdapterFactory ={
gsrs.importAdapterFactories.substances.list.ExcelFileImportAdapterFactory ={
"adapterName": "Excel File Adapter",
"order" : 41,
"importAdapterFactoryClass": "gsrs.module.substance.importers.ExcelFileImportAdapterFactory",
Expand Down Expand Up @@ -572,7 +572,7 @@ gsrs.importAdapterFactories.substances.ExcelFileImportAdapterFactory ={
}
}

gsrs.importAdapterFactories.substances.GSRSJSONImportAdapterFactory={
gsrs.importAdapterFactories.substances.list.GSRSJSONImportAdapterFactory={
"adapterName": "GSRS JSON Adapter",
"order" : 11,
"importAdapterFactoryClass"= "gsrs.module.substance.importers.GSRSJSONImportAdapterFactory",
Expand Down
64 changes: 54 additions & 10 deletions gsrs-module-substances-core/src/main/resources/substances-core.conf
Original file line number Diff line number Diff line change
Expand Up @@ -454,17 +454,61 @@ ix.gsrs.delimitedreports.inchikeysforambiguousstereo=true
#if more than one Exporter supports the same file extension,
#the class in the list that supports it fist wins.

ix.ginas.export.factories.substances = [
#"gsrs.module.substance.ExtraColumnsSpreadsheetExporterFactory",
#"gsrs.module.substance.exporters.SdfExporterFactory",
"gsrs.module.substance.exporters.DefaultSubstanceSpreadsheetExporterFactory",
"gsrs.module.substance.exporters.JsonExporterFactory",
#"ix.ginas.exporters.FDANameExporterFactory",
#"ix.ginas.exporters.FDACodeExporterFactory",
# "ix.ginas.exporters.SPLValidatorXMLExporterFactory",
# "ix.ginas.exporters.SRSLegacyDictionaryExporterFactory"
ix.ginas.export.exporterfactories.substances.list.DefaultSubstanceSpreadsheetExporterFactory =
{
"exporterFactoryClass" = "gsrs.module.substance.exporters.DefaultSubstanceSpreadsheetExporterFactory",
"order" = 1000,
"parameters":{
}
}
ix.ginas.export.exporterfactories.substances.list.JsonExporterFactory =
{
"exporterFactoryClass" = "gsrs.module.substance.exporters.JsonExporterFactory",
"order" = 1100,
"parameters":{
}
}
ix.ginas.export.exporterfactories.substances.list.FDANameExporterFactory =
{
"exporterFactoryClass" = "fda.gsrs.substance.exporters.FDANameExporterFactory",
"order" = 1200,
"disabled" = true,
"parameters":{
}
}
ix.ginas.export.exporterfactories.substances.list.FDACodeExporterFactory =
{
"exporterFactoryClass" = "fda.gsrs.substance.exporters.FDACodeExporterFactory",
"order" = 1300,
"disabled" = true,
"parameters":{
}
}
ix.ginas.export.exporterfactories.substances.list.SPLValidatorXMLExporterFactory =
{
"exporterFactoryClass" = "fda.gsrs.substance.exporters.SPLValidatorXMLExporterFactory",
"order" = 1400,
"disabled" = true,
"parameters":{
}
}
ix.ginas.export.exporterfactories.substances.list.SRSLegacyDictionaryExporterFactory =
{
"exporterFactoryClass" = "fda.gsrs.substance.exporters.SRSLegacyDictionaryExporterFactory",
"order" = 1500,
"disabled" = true,
"parameters":{
}
}

]
ix.ginas.export.exporterfactories.substances.list.SdfExporterFactory =
{
"exporterFactoryClass" = "gsrs.module.substance.exporters.SdfExporterFactory",
"order" = 1600,
"parameters":{
"approvalIDName": "UNII"
}
}

ix.ginas.export.exporterfactories.substances = [
{
Expand Down

0 comments on commit 2ebe70f

Please sign in to comment.