Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Gitlab will go into maintenance Friday 3rd February from 9:00 to 10:00
Open sidebar
minerva
core
Commits
85dd9930
Commit
85dd9930
authored
Jan 31, 2017
by
Piotr Gawron
Browse files
error handling/reporting improved
parent
d2277318
Changes
5
Hide whitespace changes
Inline
Side-by-side
annotation/src/main/java/lcsb/mapviewer/annotation/cache/BigFileCache.java
View file @
85dd9930
...
...
@@ -811,6 +811,14 @@ public class BigFileCache {
*/
public
boolean
isCached
(
String
sourceUrl
)
{
BigFileEntry
entry
=
bigFileEntryDao
.
getByUrl
(
sourceUrl
);
if
(
entry
!=
null
)
{
File
f
=
new
File
(
Configuration
.
getWebAppDir
()
+
entry
.
getLocalPath
());
if
(!
f
.
exists
())
{
logger
.
warn
(
"File is supposed to be cached but it's not there... "
+
sourceUrl
);
bigFileEntryDao
.
delete
(
entry
);
entry
=
null
;
}
}
return
entry
!=
null
;
}
...
...
annotation/src/main/java/lcsb/mapviewer/annotation/services/DrugbankHTMLParser.java
View file @
85dd9930
...
...
@@ -572,7 +572,7 @@ public class DrugbankHTMLParser extends DrugAnnotation implements IExternalServi
int
id
=
page
.
indexOf
(
"<th>DrugBank ID</th>"
);
if
(
id
<
0
)
{
throw
new
InvalidArgument
Exception
(
"Problematic web page"
);
throw
new
DrugSearch
Exception
(
"Problematic web page
for target: "
+
drugbankTarget
+
"("
+
hgncTarget
+
")
"
);
}
int
i
=
page
.
indexOf
(
"/polypeptides/"
);
...
...
service/src/main/java/lcsb/mapviewer/services/search/db/chemical/ChemicalService.java
View file @
85dd9930
...
...
@@ -320,7 +320,7 @@ public class ChemicalService implements IChemicalService {
chemicalViewFactory
.
create
(
chemical
);
}
}
catch
(
ChemicalSearchException
e
)
{
logger
.
error
(
"Problem with accessing info about chemical for target
"
,
e
);
logger
.
error
(
"Problem with accessing info about chemical for target
: "
+
md
,
e
);
}
counter
+=
1
;
progress
=
counter
/
(
double
)
targetMiriams
.
size
();
...
...
service/src/main/java/lcsb/mapviewer/services/search/db/drug/DrugService.java
View file @
85dd9930
...
...
@@ -399,7 +399,7 @@ public class DrugService implements IDrugService {
drugViewFactory
.
create
(
chemical
);
}
}
catch
(
DrugSearchException
e
)
{
logger
.
error
(
"Problem with accessing info about drugbank for target
"
,
e
);
logger
.
error
(
"Problem with accessing info about drugbank for target
: "
+
md
,
e
);
}
try
{
List
<
Drug
>
chemicalList
=
chEMBLParser
.
getDrugListByTarget
(
md
);
...
...
@@ -407,7 +407,7 @@ public class DrugService implements IDrugService {
drugViewFactory
.
create
(
chemical
);
}
}
catch
(
DrugSearchException
e
)
{
logger
.
error
(
"Problem with accessing info about chembl for target
"
,
e
);
logger
.
error
(
"Problem with accessing info about chembl for target
: "
+
md
,
e
);
}
counter
+=
1
;
progress
=
counter
/
(
double
)
targetMiriams
.
size
();
...
...
service/src/main/java/lcsb/mapviewer/services/search/db/mirna/MiRNAService.java
View file @
85dd9930
...
...
@@ -240,7 +240,7 @@ public class MiRNAService implements IMiRNAService {
miRNAViewFactory
.
create
(
chemical
);
}
}
catch
(
MiRNASearchException
e
)
{
logger
.
error
(
"Problem with accessing info about mirna for target
"
,
e
);
logger
.
error
(
"Problem with accessing info about mirna for target
: "
+
md
,
e
);
}
progress
=
counter
/
(
double
)
targetMiriams
.
size
();
iProgressUpdater
.
setProgress
(
progress
*
IProgressUpdater
.
MAX_PROGRESS
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment