Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
portal-backend
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
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
HBP Medical Informatics Platform
portal-backend
Commits
3fe17418
Commit
3fe17418
authored
9 years ago
by
Mirco Nasuti
Browse files
Options
Downloads
Patches
Plain Diff
do not load db data at startup
parent
e59dd18f
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
src/main/java/org/hbp/mip/MIPApplication.java
+0
-22
0 additions, 22 deletions
src/main/java/org/hbp/mip/MIPApplication.java
with
0 additions
and
22 deletions
src/main/java/org/hbp/mip/MIPApplication.java
+
0
−
22
View file @
3fe17418
...
...
@@ -24,7 +24,6 @@ import com.fasterxml.jackson.core.JsonProcessingException;
import
com.fasterxml.jackson.databind.ObjectMapper
;
import
io.swagger.annotations.Api
;
import
org.hbp.mip.controllers.HibernateUtil
;
import
org.hbp.mip.data.Database
;
import
org.hbp.mip.model.User
;
import
org.hibernate.Session
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -92,27 +91,6 @@ public class MIPApplication extends WebSecurityConfigurerAdapter {
OAuth2ClientContext
oauth2ClientContext
;
public
static
void
main
(
String
[]
args
)
{
Session
session
=
HibernateUtil
.
getSessionFactory
().
getCurrentSession
();
session
.
beginTransaction
();
org
.
hibernate
.
Query
query
=
session
.
createQuery
(
"select count(*) from Group"
);
Long
count
=
(
Long
)
query
.
uniqueResult
();
session
.
getTransaction
().
commit
();
if
(
count
<
1
)
{
Database
.
loadGroups
();
}
session
=
HibernateUtil
.
getSessionFactory
().
getCurrentSession
();
session
.
beginTransaction
();
query
=
session
.
createQuery
(
"select count(*) from Variable"
);
count
=
(
Long
)
query
.
uniqueResult
();
session
.
getTransaction
().
commit
();
if
(
count
<
1
)
{
Database
.
loadVariables
();
}
SpringApplication
.
run
(
MIPApplication
.
class
,
args
);
}
...
...
This diff is collapsed.
Click to expand it.
Preview
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!
Save comment
Cancel
Please
register
or
sign in
to comment