Skip to content

AharoniLab/MetFragRelaunched

 
 

Repository files navigation

Build CI install with bioconda

MetFrag relaunched

Requirements
  • Java = openjdk11
  • Apache Maven = 3.8
Sources
  • download sources by cloning git repository
git clone https://github.com/ipb-halle/MetFragRelaunched.git

MetFrag Webapp container

This container packages the MetFrag (https://github.com/ipb-halle/MetFragRelaunched) webapp and some text databases based on the latest official tomcat docker container.

Following options are supported:
  • environment variable JAVA_OPTS="-Xmx?g -Xms?g" to adjust jvm memory
  • environment variable WEBPREFIX to adjust the web app name
  • automatic use of a metfrag settings file if provided at /resources/settings.properties
Examples:

Run MetFrag at http://localhost:8888/MetFragWeb

docker run -it --rm -p 8888:8080 ipb-halle/metfragweb

Run Metfrag at http://localhost:8888/mymetfrag with 4GB JVM size using a settings file from ./settings.properties

docker run -it --rm -e  JAVA_OPTS="-Xmx4g -Xms4g" -e WEBPREFIX=mymetfrag -v $(pwd)/settings.properties:/resources/settings.properties -p 8888:8080 ipbhalle/metfragweb
Container repositories

See https://hub.docker.com/r/ipbhalle/metfragweb for automatic builds.

MetFragLib

Build
mvn clean install -pl MetFragLib -am
  • skipping test during build by
mvn clean install -pl MetFragLib -am -DskipTests

MetFragCommandLine

Basics
Build
mvn clean install -pl MetFragCommandLine -am
  • skipping test during build by
mvn clean install -pl MetFragCommandLine -am -DskipTests

MetFragR

Basics
Build
mvn clean install -pl MetFragR -am
  • skipping test during build by
mvn clean install -pl MetFragR -am -DskipTests
  • after the successful build the MetFragR java library is located in MetFragR/rpackage/metfRag/inst/java/
  • point to the directory MetFragR/rpackage/ to perform checks and the build of the R package
R CMD check metfRag
R CMD build metfRag
  • after the successful build the R package can be installed in R
install.packages("metfRag",repos=NULL,type="source")
library(metfRag)
  • all earlier steps can be skipped by installing the pre-compiled R package from GitHub
library(devtools)
install_github("ipb-halle/MetFragR/metfRag")

MetFragWeb

Basics
  • MetFrag web version depends on MetFragLib. Runs with Java Server Faces 2.2 and PrimeFaces 5.3 and brings its own Tomcat web server
Configuration
  • rename file settings.properties.template in MetFragWeb/src/main/webapp/resources to settings.properties and set necessary parameters
## define chemspider token to query ChemSpider database
ChemSpiderToken = ...

## if MetFragWeb host is connected via proxy to the internet provide proxy settings for 
## different web services
MoNAProxyServer = ...
MoNAProxyPort = ...

KeggProxyServer = ...
KeggProxyPort = ...

MetaCycProxyServer = ...
MetaCycProxyPort = ...

## to speed up database queries you can set up local repositories by setting up MySQL or 
## PostgreSQL databases
LocalPubChemDatabase = ...
LocalPubChemDatabaseCompoundsTable = ...
LocalPubChemDatabasePortNumber = ...
LocalPubChemDatabaseServerIp = ...
LocalPubChemDatabaseMassColumn = ...
LocalPubChemDatabaseFormulaColumn = ...
LocalPubChemDatabaseInChIColumn = ...
LocalPubChemDatabaseInChIKey1Column = ...
LocalPubChemDatabaseInChIKey2Column = ...
LocalPubChemDatabaseCidColumn = ...
LocalPubChemDatabaseSmilesColumn = ...
LocalPubChemDatabaseUser = ...
LocalPubChemDatabasePassword = ...
LocalPubChemDatabaseCompoundNameColumn = ...
Build and Run
mvn clean install -pl MetFragWeb -am
mvn org.codehaus.cargo:cargo-maven3-plugin:run -pl MetFragWeb
  • skipping test during build by
mvn clean install -pl MetFragWeb -am -DskipTests
mvn org.codehaus.cargo:cargo-maven3-plugin:run -pl MetFragWeb
Build
  • if you just want to build the war file to transfer it to another Tomcat instance, run:
mvn clean package -pl MetFragWeb -am
  • after the successful build the war file is located in MetFragWeb/target/MetFragWeb.war

Additionals

Run main methods
mvn exec:java -Dexec.mainClass="java_class_path" -Dexec.args="arg0 arg1 arg2 ..."  

References

Ruttkies C., Schymanski E.L. et al, MetFrag relaunched: incorporating strategies beyond in silico fragmentation. Journal of Cheminformatics, 2016, 8:3. http://jcheminf.springeropen.com/articles/10.1186/s13321-016-0115-9

About

Relaunch of the initial MetFrag project.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 72.3%
  • JavaScript 19.4%
  • HTML 4.9%
  • R 2.0%
  • TeX 0.6%
  • CSS 0.6%
  • Other 0.2%