Skip to content

Commit

Permalink
Merge pull request #868 from openworm/development
Browse files Browse the repository at this point in the history
Release 0.4.2
  • Loading branch information
tarelli authored Jan 16, 2019
2 parents d091f65 + 3f38023 commit 7588ed3
Show file tree
Hide file tree
Showing 57 changed files with 20,020 additions and 2,039 deletions.
15 changes: 13 additions & 2 deletions .project
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,23 @@
</projects>
<buildSpec>
<buildCommand>
<name>org.python.pydev.PyDevBuilder</name>
<name>org.eclipse.ui.externaltools.ExternalToolBuilder</name>
<triggers>full,incremental,</triggers>
<arguments>
<dictionary>
<key>LaunchConfigHandle</key>
<value>&lt;project&gt;/.externalToolBuilders/org.python.pydev.PyDevBuilder.launch</value>
</dictionary>
</arguments>
</buildCommand>
<buildCommand>
<name>com.aptana.ide.core.unifiedBuilder</name>
<name>org.eclipse.ui.externaltools.ExternalToolBuilder</name>
<triggers>full,incremental,</triggers>
<arguments>
<dictionary>
<key>LaunchConfigHandle</key>
<value>&lt;project&gt;/.externalToolBuilders/com.aptana.ide.core.unifiedBuilder.launch</value>
</dictionary>
</arguments>
</buildCommand>
<buildCommand>
Expand Down Expand Up @@ -46,5 +56,6 @@
<nature>com.aptana.ruby.core.rubynature</nature>
<nature>org.python.pydev.pythonNature</nature>
<nature>org.eclipse.virgo.ide.facet.core.bundlenature</nature>
<nature>org.eclipse.wst.jsdt.core.jsNature</nature>
</natures>
</projectDescription>
7 changes: 2 additions & 5 deletions .settings/org.eclipse.wst.common.component
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
<wb-module deploy-name="org.geppetto.frontend">
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/java"/>
<wb-resource deploy-path="/js/" source-path="/src/main/webapp/js"/>
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/resources"/>
<wb-resource deploy-path="/font/" source-path="/src/main/webapp/fonts"/>
<wb-resource deploy-path="/" source-path="/WebContent" tag="defaultRootSource"/>
<wb-resource deploy-path="/" source-path="/target/m2e-wtp/web-resources"/>
<wb-resource deploy-path="/" source-path="/src/main/webapp"/>
<wb-resource deploy-path="/" source-path="/src/main/webapp" tag="defaultRootSource"/>
<property name="context-root" value="org.geppetto.frontend"/>
<property name="java-output-path" value="/org.geppetto.frontend/target/classes"/>
<property name="component.exclusion.patterns" value="node_modules/**,WEB-INF/classes/lib/*.jar,WEB-INF/lib/*.jar,node/**"/>
<property name="java-output-path" value="/org.geppetto.frontend/target/classes"/>
</wb-module>
</project-modules>
6 changes: 2 additions & 4 deletions .settings/org.eclipse.wst.common.project.facet.core.xml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<faceted-project>
<runtime name="Virgo Runtime"/>
<fixed facet="wst.jsdt.web"/>
<installed facet="wst.jsdt.web" version="1.0"/>
<installed facet="osgi.bundle" version="4.2"/>
<installed facet="java" version="1.7"/>
<installed facet="wst.jsdt.web" version="1.0"/>
<installed facet="org.eclipse.virgo.server.bundle" version="1.0"/>
<installed facet="jst.web" version="2.5"/>
<installed facet="jst.web" version="3.0"/>
</faceted-project>
17 changes: 11 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,15 @@ language: node_js
os: linux
sudo: required
dist: trusty
group: deprecated-2017Q4
bundler_args: --retry 5
node_js:
- "7"
env:
global:
secure: dn0FPQ5IG4M/3kdwnyI78ElQ308Vc3QnKAvkWfwMFb8QxDqxQdnTo7AV1qTMtbLrDNkeEWIgi4nc7jmXNtvGTwOfhAULVh6606Qs5B+ezTdwzajbbFMI8SKQx/pnTojOMu8dx7V4lMoR/YWcojR0VC1IWVC62TGbSB1k5BDGgH0=
before_install:
- sudo apt-get install -y xserver-xorg-dev libxext-dev libxi-dev
install:
- npm install --silent -g phantomjs
- npm install --silent -g casperjs
Expand All @@ -26,6 +29,8 @@ addons:
- libgl1-mesa-dri
- libglapi-mesa
- libosmesa6
- net-tools
- lsof
before_script:
- "export DISPLAY=:99.0"
- "sh -e /etc/init.d/xvfb start"
Expand All @@ -34,11 +39,11 @@ before_script:
script:
- npm config set registry http://registry.npmjs.org/
- echo "Current time :$(date +"%T")"
- docker --version
- cd $TRAVIS_BUILD_DIR/src/main/webapp/js/pages/tests/casperjs
- echo "$TRAVIS_BRANCH"
- travis_retry docker build -t="geppetto" --build-arg frontendBranch=$TRAVIS_BRANCH https://github.com/openworm/org.geppetto.git#development:utilities/docker/geppetto/
- echo "Current time :$(date +"%T")"
- travis_retry docker run -t -dit --name=geppetto_container -h localhost -p 28081:8080 geppetto
- travis_retry docker build -t="geppetto" --build-arg mainBranch=$TRAVIS_BRANCH https://github.com/openworm/org.geppetto.git#update-virgo:utilities/docker/geppetto/
- travis_retry docker run -t -dit --name=geppetto_container -p 28081:8080 geppetto
- bash $TRAVIS_BUILD_DIR/src/main/webapp/js/pages/tests/casperjs/utilities/test_geppetto_server.sh
- sleep 30
- http_status=$(curl -s -I $1 http://localhost:28081/org.geppetto.frontend | grep HTTP/1.1 | awk {'print $2'})
Expand All @@ -52,7 +57,7 @@ script:
sleep 10;
docker rm $(docker ps -a -q);
sleep 10;
travis_retry docker run -t -dit --name=geppetto_container -h localhost -p 28081:8080 geppetto;
travis_retry docker run -t -dit --name=geppetto_container -p 28081:8080 geppetto;
bash $TRAVIS_BUILD_DIR/src/main/webapp/js/pages/tests/casperjs/utilities/test_geppetto_server.sh;
sleep 60;
http_status=$(curl -s -I $1 http://localhost:28081/org.geppetto.frontend | grep HTTP/1.1 | awk {'print $2'});
Expand All @@ -63,8 +68,8 @@ script:
- travis_retry xvfb-run -a --server-args="-screen 0 1024x768x24" casperjs test --includes=utilities/TestsUtility.js UIComponentsTests.js --host=http://localhost:28081/ --engine=slimerjs
- travis_retry xvfb-run -a --server-args="-screen 0 1024x768x24" casperjs test --includes=utilities/TestsUtility.js GeppettoModelTests.js --host=http://localhost:28081/ --engine=slimerjs
- travis_retry xvfb-run -a --server-args="-screen 0 1024x768x24" casperjs test --includes=utilities/TestsUtility.js,NeuronalTestsLogic.js DefaultProjectsTests.js --host=http://localhost:28081/ --engine=slimerjs
- docker ps -a;
- sudo docker cp geppetto_container:/home/developer/virgo/serviceability/logs/log.log /etc
- tail /etc/log.log -n 200
- echo "Current time :$(date +"%T")"
- docker stop $(docker ps -a -q)
- docker rm $(docker ps -a -q)
- docker rm $(docker ps -a -q)
116 changes: 12 additions & 104 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.geppetto</groupId>
<artifactId>frontend</artifactId>
<version>0.4.1</version>
<version>0.4.2</version>
<name>Geppetto Frontend</name>
<packaging>war</packaging>
<properties>
<contextPath>org.geppetto.frontend</contextPath>
<spring.version>3.1.3.RELEASE</spring.version>
<spring.version>4.3.9.RELEASE</spring.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<profiles>
Expand Down Expand Up @@ -132,129 +132,38 @@
<artifactId>simulation</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
<version>2.1.0</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>2.1.0</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>com.springsource.org.apache.commons.logging</artifactId>
<version>1.1.1</version>
</dependency>
<dependency>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-catalina</artifactId>
<version>7.0.29</version>
<version>8.5.31</version>
</dependency>
<dependency>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-coyote</artifactId>
<version>7.0.29</version>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>com.springsource.javax.servlet.jsp.jstl</artifactId>
<version>1.1.2</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<version>2.2.2</version>
</dependency>

<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-core</artifactId>
<version>${spring.version}</version>
<version>8.5.31</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-aspects</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context-support</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-beans</artifactId>
<version>${spring.version}</version>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-websocket</artifactId>
<version>8.5.31</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-web</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-test</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-webmvc</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework.osgi</groupId>
<artifactId>spring-osgi-core</artifactId>
<version>1.2.1</version>
</dependency>
<dependency>
<groupId>org.springframework.osgi</groupId>
<artifactId>spring-osgi-web</artifactId>
<version>1.2.1</version>
</dependency>
<dependency>
<groupId>org.springframework.osgi</groupId>
<artifactId>spring-osgi-extender</artifactId>
<version>1.2.1</version>
</dependency>
<dependency>
<groupId>org.springframework.osgi</groupId>
<artifactId>spring-osgi-web-extender</artifactId>
<version>1.2.1</version>
</dependency>
<dependency>
<groupId>org.apache.servicemix.bundles</groupId>
<artifactId>org.apache.servicemix.bundles.velocity</artifactId>
<version>1.7_6</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.core</artifactId>
<version>5.0.0</version>
</dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>3.1.0</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.junit</groupId>
<artifactId>com.springsource.org.junit</artifactId>
<version>4.7.0</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpcore-osgi</artifactId>
<version>4.3.2</version>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient-osgi</artifactId>
<version>4.4-alpha1</version>
</dependency>
<dependency>
<groupId>org.apache.shiro</groupId>
<artifactId>shiro-core</artifactId>
Expand Down Expand Up @@ -329,7 +238,6 @@
org.eclipse.virgo.web.dm;version="2.1.1.RELEASE",*
</Import-Package>
<Import-Library>org.springframework.spring;version="${spring.version}"</Import-Library>
<Import-Bundle>org.springframework.aop;version="${spring.version}"</Import-Bundle>
</instructions>
</configuration>
<executions>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
package org.geppetto.frontend;

import org.springframework.context.ApplicationEvent;
import org.springframework.context.ApplicationListener;
import org.springframework.context.event.ContextRefreshedEvent;

public class ApplicationListenerBean implements ApplicationListener<ContextRefreshedEvent>
public class ApplicationListenerBean implements ApplicationListener
{
@Override
public void onApplicationEvent(ContextRefreshedEvent event)
{
// DONT'DO ANYTHING THAT HAS TO DO WITH THE DATABASE HERE OR DATANUCLEUS BREAKS
public void onApplicationEvent(ApplicationEvent event) {
// TODO Auto-generated method stub

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,11 @@
@Controller
public class Application
{

@Autowired
private IGeppettoManager geppettoManager;

private static Log logger = LogFactory.getLog(Application.class);


private String getGeppetto(HttpServletRequest req, String page){
try
{
Expand Down Expand Up @@ -164,5 +162,4 @@ public String root(HttpServletRequest request, HttpServletResponse response)

return "dashboard";
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ public void loadProjectFromURL(String requestID, String urlString)
}
catch(IOException e)
{
error(e, "Could not load geppetto project");
error(e, "Could not load geppetto project from url: " + urlString );
}
}

Expand Down Expand Up @@ -519,10 +519,8 @@ public void resolveImportValue(String requestID, Long projectId, Long experiment
catch(IOException e)
{
error(e, "Error importing value " + path);
}
catch(GeppettoExecutionException e)
{
error(e, "Error importing value " + path);
} catch (GeppettoExecutionException e) {
error(e, "Error importing value " + path);
}

}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package org.geppetto.frontend.controllers;

import java.io.IOException;
import java.nio.CharBuffer;
import java.util.ArrayList;
import java.util.Collection;
Expand Down Expand Up @@ -67,15 +66,7 @@ private void purgeLostConnections()
for(WebsocketConnection client : this.getConnections())
{
CharBuffer buffer = CharBuffer.wrap("ping");
try
{
client.getWsOutbound().writeTextMessage(buffer);
}
catch(IOException e)
{
_logger.error("Unable to communicate with client " + e.getMessage() + ". Removing connection.");
toBeRemoved.add(client);
}
client.getSession().getAsyncRemote().sendObject(buffer);
}
for(WebsocketConnection client : toBeRemoved)
{
Expand Down
Loading

0 comments on commit 7588ed3

Please sign in to comment.