Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
openbis
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
sispub
openbis
Commits
b2d70d64
Commit
b2d70d64
authored
16 years ago
by
tpylak
Browse files
Options
Downloads
Patches
Plain Diff
LMS-659 bigger timeout during legacy db indexing
SVN: 9106
parent
3cd9eca6
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
openbis/source/java/ch/systemsx/cisd/openbis/generic/server/dataaccess/db/search/FullTextIndexerRunnable.java
+5
-0
5 additions, 0 deletions
.../server/dataaccess/db/search/FullTextIndexerRunnable.java
with
5 additions
and
0 deletions
openbis/source/java/ch/systemsx/cisd/openbis/generic/server/dataaccess/db/search/FullTextIndexerRunnable.java
+
5
−
0
View file @
b2d70d64
...
@@ -22,6 +22,7 @@ import java.util.Set;
...
@@ -22,6 +22,7 @@ import java.util.Set;
import
org.apache.commons.io.FileUtils
;
import
org.apache.commons.io.FileUtils
;
import
org.apache.commons.lang.time.StopWatch
;
import
org.apache.commons.lang.time.StopWatch
;
import
org.apache.log4j.Logger
;
import
org.apache.log4j.Logger
;
import
org.apache.lucene.index.IndexWriter
;
import
org.hibernate.Session
;
import
org.hibernate.Session
;
import
org.hibernate.SessionFactory
;
import
org.hibernate.SessionFactory
;
import
org.hibernate.search.annotations.Indexed
;
import
org.hibernate.search.annotations.Indexed
;
...
@@ -60,6 +61,8 @@ public final class FullTextIndexerRunnable extends HibernateDaoSupport implement
...
@@ -60,6 +61,8 @@ public final class FullTextIndexerRunnable extends HibernateDaoSupport implement
this
.
context
=
context
;
this
.
context
=
context
;
operationLog
.
debug
(
String
.
format
(
"Hibernate search context: %s."
,
context
));
operationLog
.
debug
(
String
.
format
(
"Hibernate search context: %s."
,
context
));
fullTextIndexer
=
new
DefaultFullTextIndexer
(
context
.
getBatchSize
());
fullTextIndexer
=
new
DefaultFullTextIndexer
(
context
.
getBatchSize
());
// TODO 2008-11-25, Tomasz Pylak: maybe we could get rid of hardcoding package path by
// scanning Hibernate mapped entities?
indexedEntityFinder
=
indexedEntityFinder
=
new
PackageBasedIndexedEntityFinder
(
"ch.systemsx.cisd.openbis.generic.shared.dto"
);
new
PackageBasedIndexedEntityFinder
(
"ch.systemsx.cisd.openbis.generic.shared.dto"
);
}
}
...
@@ -85,6 +88,8 @@ public final class FullTextIndexerRunnable extends HibernateDaoSupport implement
...
@@ -85,6 +88,8 @@ public final class FullTextIndexerRunnable extends HibernateDaoSupport implement
Class
<?>
currentEntity
=
null
;
Class
<?>
currentEntity
=
null
;
try
try
{
{
// timeout exceptions were observed for the default timeout when database was bigger
IndexWriter
.
setDefaultWriteLockTimeout
(
3000
);
final
File
indexBase
=
new
File
(
context
.
getIndexBase
());
final
File
indexBase
=
new
File
(
context
.
getIndexBase
());
final
File
markerFile
=
new
File
(
indexBase
,
FULL_TEXT_INDEX_MARKER_FILENAME
);
final
File
markerFile
=
new
File
(
indexBase
,
FULL_TEXT_INDEX_MARKER_FILENAME
);
if
(
indexMode
==
IndexMode
.
SKIP_IF_MARKER_FOUND
&&
markerFile
.
exists
())
if
(
indexMode
==
IndexMode
.
SKIP_IF_MARKER_FOUND
&&
markerFile
.
exists
())
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment