Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Genesys Backend
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
45
Issues
45
List
Boards
Labels
Service Desk
Milestones
Operations
Operations
Incidents
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Genesys PGR
Genesys Backend
Commits
5296f24d
Commit
5296f24d
authored
Nov 13, 2013
by
Matija Obreza
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Replaced jetty profile with jetty-maven-plugin
parent
2a1f7983
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
97 deletions
+17
-97
pom.xml
pom.xml
+16
-51
src/main/java/org/genesys2/JettyMain.java
src/main/java/org/genesys2/JettyMain.java
+0
-44
src/main/java/org/genesys2/server/service/impl/CropServiceImpl.java
...ava/org/genesys2/server/service/impl/CropServiceImpl.java
+1
-2
No files found.
pom.xml
View file @
5296f24d
...
...
@@ -40,7 +40,7 @@
<aspectj.version>
1.7.2
</aspectj.version>
<spring.framework.version>
3.2.5.RELEASE
</spring.framework.version>
<spring.security.version>
3.1.4.RELEASE
</spring.security.version>
<spring.security.oauth2.version>
1.0.5.RELEASE
</spring.security.oauth2.version>
<spring.security.oauth2.version>
1.0.5.RELEASE
</spring.security.oauth2.version>
<spring.data.core.version>
1.5.1.RELEASE
</spring.data.core.version>
<spring.data.jpa.version>
1.3.2.RELEASE
</spring.data.jpa.version>
...
...
@@ -50,7 +50,7 @@
<jackson.version>
2.2.1
</jackson.version>
<!--Container -->
<jetty.version>
9.0.
5.v20130815
</jetty.version>
<jetty.version>
9.0.
6.v20130930
</jetty.version>
<maven.test.skip>
false
</maven.test.skip>
...
...
@@ -151,21 +151,19 @@
</dependency>
<!--Servlet and portal dependencies -->
<!--
<dependency>
<dependency>
<groupId>
javax.servlet.jsp
</groupId>
<artifactId>
jsp-api
</artifactId>
<version>
${jsp-api.version}
</version>
<scope>
provided
</scope>
</dependency>
</dependency>
<dependency>
<dependency>
<groupId>
javax.servlet
</groupId>
<artifactId>
servlet-api
</artifactId>
<version>
${servlet-api.version}
</version>
<scope>
provided
</scope>
</dependency>
-->
</dependency>
<dependency>
<groupId>
javax.servlet
</groupId>
...
...
@@ -300,17 +298,7 @@
</dependency>
<!--Jetty -->
<dependency>
<groupId>
org.eclipse.jetty
</groupId>
<artifactId>
jetty-deploy
</artifactId>
<version>
${jetty.version}
</version>
</dependency>
<dependency>
<groupId>
org.eclipse.jetty
</groupId>
<artifactId>
jetty-jsp
</artifactId>
<version>
${jetty.version}
</version>
</dependency>
<dependency>
<groupId>
net.tanesha.recaptcha4j
</groupId>
...
...
@@ -323,7 +311,7 @@
<artifactId>
httpclient
</artifactId>
<version>
4.2.5
</version>
</dependency>
<dependency>
<groupId>
net.sf.opencsv
</groupId>
<artifactId>
opencsv
</artifactId>
...
...
@@ -350,9 +338,9 @@
<version>
r209
</version>
</dependency>
<dependency>
<groupId>
org.springframework.security.oauth
</groupId>
<artifactId>
spring-security-oauth2
</artifactId>
<version>
${spring.security.oauth2.version}
</version>
<groupId>
org.springframework.security.oauth
</groupId>
<artifactId>
spring-security-oauth2
</artifactId>
<version>
${spring.security.oauth2.version}
</version>
</dependency>
</dependencies>
...
...
@@ -379,38 +367,15 @@
<showWarnings>
true
</showWarnings>
</configuration>
</plugin>
<plugin>
<groupId>
org.eclipse.jetty
</groupId>
<artifactId>
jetty-maven-plugin
</artifactId>
<version>
${jetty.version}
</version>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>
start-jetty
</id>
<build>
<plugins>
<plugin>
<groupId>
org.codehaus.mojo
</groupId>
<artifactId>
exec-maven-plugin
</artifactId>
<version>
1.2.1
</version>
<configuration>
<mainClass>
org.genesys2.JettyMain
</mainClass>
</configuration>
<executions>
<execution>
<phase>
compile
</phase>
<goals>
<goal>
java
</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<version>
0.9.0
</version>
<version>
0.9.1
</version>
<url>
http://genesys-pgr.org
</url>
<description>
Genesys 2 Server
</description>
<organization>
...
...
src/main/java/org/genesys2/JettyMain.java
deleted
100644 → 0
View file @
2a1f7983
/**
* Copyright 2013 Global Crop Diversity Trust
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
**/
package
org.genesys2
;
import
org.apache.commons.logging.Log
;
import
org.apache.commons.logging.LogFactory
;
import
org.eclipse.jetty.server.Server
;
import
org.eclipse.jetty.server.ServerConnector
;
import
org.eclipse.jetty.webapp.WebAppContext
;
public
class
JettyMain
{
public
static
final
Log
_logger
=
LogFactory
.
getLog
(
JettyMain
.
class
);
public
static
void
main
(
String
[]
args
)
throws
Exception
{
_logger
.
info
(
"Starting Jetty"
);
Server
server
=
new
Server
();
ServerConnector
connector
=
new
ServerConnector
(
server
);
connector
.
setPort
(
8080
);
server
.
addConnector
(
connector
);
WebAppContext
root
=
new
WebAppContext
(
"src/main/webapp"
,
"/"
);
server
.
setHandler
(
root
);
_logger
.
info
(
"Starting..."
);
server
.
start
();
server
.
join
();
}
}
src/main/java/org/genesys2/server/service/impl/CropServiceImpl.java
View file @
5296f24d
...
...
@@ -25,7 +25,6 @@ import java.util.Locale;
import
org.apache.commons.lang.StringUtils
;
import
org.apache.commons.logging.Log
;
import
org.apache.commons.logging.LogFactory
;
import
org.eclipse.jetty.util.StringUtil
;
import
org.genesys2.server.model.genesys.Taxonomy
;
import
org.genesys2.server.model.impl.Crop
;
import
org.genesys2.server.model.impl.CropRule
;
...
...
@@ -225,7 +224,7 @@ public class CropServiceImpl implements CropService {
@PreAuthorize
(
"hasRole('ADMINISTRATOR')"
)
@Transactional
(
readOnly
=
false
)
public
CropRule
addCropRule
(
Crop
crop
,
String
genus
,
String
species
,
boolean
included
)
{
if
(
crop
==
null
||
StringUtil
.
isBlank
(
genus
))
{
if
(
crop
==
null
||
StringUtil
s
.
isBlank
(
genus
))
{
LOG
.
debug
(
"Ignoring blank rule"
);
return
null
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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