Glassfish/Payara: why might deployment of a large web app to Glassfish-4.1.1 (or Payara Server 4.1.1.163) take 5 times longer than to Glassfish-4.1 - glassfish-4.1

Mac OS X: Yosemite 10.10.5
Until recently I have been using:
NetBeans8.1beta
Glassfish4.1
Mojarra 2.2.7
I have recently investigated using:
NetBeans8.1
Glassfish4.1.1
Mojarra 2.2.12.
With a very large JSF web app (with ObjectDB as JPA persistence provider) I am experiencing massively longer deployment times to Glassfish4.1.1 (over 10 minutes) than to Glassfish4.1 (around 2 minutes). That's about 5 times slower.
[EDIT: 2016-09-13 Tried with Payara 163 Full (Payara Server 4.1.1.163) and it took over 20 minutes, even slower than on Glassfish4.1.1, with nearly identical setup]
I can't possibly reproduce here or provide examples of the large web app.
Q1: Has anybody experienced any similar difference between Glassfish-4.1 and Glassfish-4.1.1 [EDIT: OR Payara Server 4.1.1.163], and where I might I look for the point of difference ?
(I am already trying to investigate it by using the NetBeans Profiler, but it is not turning out to be so easy yet to find the cause.)
[EDIT: 2016-09-15 timing tests]
I have performed careful side-by-side comparison using screencast recording and comparing with timings in the log.
In Payara41 (4.1.1.163) and Glassfish4.1.1 it gets "stuck" as shown below for about 10 minutes, and I have not found any log setting that gives a single line of output here where the problem occurs, and running the server in DEBUG mode also does not seem to give any additional information.
[2016-09-14T23:02:53.450+1000] [Payara 4.1] [INFO] [NCLS-LOGGING-00009] [javax.enterprise.logging] [tid: _ThreadID=19 _ThreadName=RunLevelControllerThread-1473858173343] [timeMillis: 1473858173450] [levelValue: 800] [[
Running Payara Version: Payara Server 4.1.1.163 #badassfish (build 215)]]
... runs ok through all steps and then through dozens of these EJB JNDI name declarations:
[2016-09-14T23:03:48.823+1000] [Payara 4.1] [INFO] [AS-EJB-00054] [javax.enterprise.ejb.container] [tid: _ThreadID=74 _ThreadName=admin-thread-pool(2)] [timeMillis: 1473858228823] [levelValue: 800] [[
Portable JNDI names for EJB BeanName: [java:global/app-name/BeanName!com.example.BeanName, java:global/app-name/BeanName]]]
Gives this WELD version message:
[2016-09-14T23:03:48.875+1000] [Payara 4.1] [INFO] [] [org.jboss.weld.Version] [tid: _ThreadID=74 _ThreadName=admin-thread-pool(2)] [timeMillis: 1473858228875] [levelValue: 800] [[
WELD-000900: 2.3.5 (Final)]]
... then takes about 8 seconds before this message ..
[2016-09-14T23:03:56.666+1000] [Payara 4.1] [INFO] [] [org.jboss.weld.Event] [tid: _ThreadID=74 _ThreadName=admin-thread-pool(2)] [timeMillis: 1473858236666] [levelValue: 800] [[
WELD-000411: Observer method [BackedAnnotatedMethod] private org.glassfish.jersey.ext.cdi1x.internal.CdiComponentProvider.processAnnotatedType(#Observes ProcessAnnotatedType) receives events for all annotated types. Consider restricting events using #WithAnnotations or a generic type with bounds.]]
... Then take many minutes (typically about 10 minutes) before resuming these otherwise harmless warnings ..
[2016-09-14T23:11:33.387+1000] [Payara 4.1] [INFO] [] [org.jboss.weld.Bootstrap] [tid: _ThreadID=74 _ThreadName=admin-thread-pool(2)] [timeMillis: 1473858693387] [levelValue: 800] [[
WELD-001125: Illegal bean type java.util.Comparator<javax.persistence.metamodel.EntityType<?>> ignored on [EnhancedAnnotatedTypeImpl] public static class com.example.ElementManager$EntityTypeSorter]]
[2016-09-14T23:11:59.736+1000] [Payara 4.1] [WARNING] [] [org.glassfish.jersey.internal.Errors] [tid: _ThreadID=74 _ThreadName=admin-thread-pool(2)] [timeMillis: 1473858719736] [levelValue: 900] [[
The following warnings have been detected: WARNING: Parameter 1 of type T from public void com.example.NumberProperty.setDefaultValue(T) is not resolvable to a concrete type.
]]
Similar warning messages happen in the Glassfish4.1 log, but there is no long pause/holdup.
Q2: What else can I do to find out why it is pausing/stalling there for ages ?

Thanks to detailed help from the Payara team I have an answer.
The max heap settings were different between my old Glassfish4.1 install (-Xmx2048m) and the new Glassfish4.1.1 and Payara41 install (-Xmx512m). On building my web app project's database model on startup, it was hitting the 512m heap limit and causing excessive garbage collection (as revealed by JVisualVM), which massively slowed the deployment.
I already had these as run-time VMargs for the NetBeans web app project:
-Xms2048m -Xmx2048m
But on installing NetBeans8.1 (with Glassfish4.1.1), and then Payara41, I had neglected to also match this on the new servers to make room for it. With the increased max heap and fixed minimum the deployment time is now about 2 mins on both Glassfish4.1.1 and Payara41.

Related

Unable to deploy app to shinyapps.io: Unable to determine package source

I have an embarrassing error when deploy a simple app to shinyapps.io.
The app needs only one more package "Seurat" which I load in server.R by library(Seurat). But When I deploy it to shinyappsio.io, it stopped and showed:
Preparing to deploy application...DONE
Uploading bundle for application: 1762339...DONE
Deploying bundle: 2806268 for application: 1762339 ...
Waiting for task: 693229180
building: Processing bundle: 2806268
building: Parsing manifest
################################ Begin Task Log ################################
################################# End Task Log #################################
Error: Unhandled Exception: Child Task 693229181 failed: Error parsing manifest: Unable to determine package source for Bioconductor package Biobase: Repository must be specified
Execution halted
While it seems to be a simple repository specification problem. So I tried changing the repos:
options(repos = BiocManager::repositories())
which didn't help, then I tried:
setRepositories()
and choose the "BioC software" and it doesn't help either. The error specified for the Bioconductor package Seurat:
Preparing to deploy application...DONE
Uploading bundle for application: 1762339...DONE
Deploying bundle: 2806287 for application: 1762339 ...
Waiting for task: 693231225
building: Processing bundle: 2806287
building: Parsing manifest
################################ Begin Task Log ################################
################################# End Task Log #################################
Error: Unhandled Exception: Child Task 693231227 failed: Error parsing manifest: Unable to determine package source for Bioconductor package Seurat: Repository must be specified
Execution halted
Then I found Seurat is even not a bioconductor package and should be found with r CRAN:
https://cran.r-project.org/web/packages/Seurat/index.html
I have no other solution in my head. Could anyone help me out? Thank you!
Here's current options("repos"):
> options("repos")
$repos
CRAN
"https://cloud.r-project.org"
BioCsoft
"https://bioconductor.org/packages/3.10/bioc"
BioCann
"https://bioconductor.org/packages/3.10/data/annotation"
BioCexp
"https://bioconductor.org/packages/3.10/data/experiment"
Here's my sessioninfo:
R version 3.6.2 (2019-12-12)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 18.04.4 LTS
Matrix products: default
BLAS: /usr/lib/x86_64-linux-gnu/blas/libblas.so.3.7.1
LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.7.1
locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C LC_TIME=en_GB.UTF-8 LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=en_GB.UTF-8 LC_MESSAGES=en_US.UTF-8 LC_PAPER=en_GB.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C LC_MEASUREMENT=en_GB.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] ggplot2_3.2.1 Seurat_3.1.3 shiny_1.4.0
loaded via a namespace (and not attached):
[1] TH.data_1.0-10 Rtsne_0.15 colorspace_1.4-1 ggridges_0.5.2 rsconnect_0.8.16 rstudioapi_0.11
[7] leiden_0.3.3 listenv_0.8.0 npsurv_0.4-0 ggrepel_0.8.1 mvtnorm_1.0-12 codetools_0.2-16
[13] splines_3.6.2 mnormt_1.5-6 lsei_1.2-0 TFisher_0.2.0 jsonlite_1.6.1 packrat_0.5.0
[19] ica_1.0-2 cluster_2.1.0 png_0.1-7 uwot_0.1.5 sctransform_0.2.1 BiocManager_1.30.10
[25] compiler_3.6.2 httr_1.4.1 assertthat_0.2.1 Matrix_1.2-18 fastmap_1.0.1 lazyeval_0.2.2
[31] later_1.0.0 htmltools_0.4.0 tools_3.6.2 rsvd_1.0.2 igraph_1.2.4.2 gtable_0.3.0
[37] glue_1.3.1 RANN_2.6.1 reshape2_1.4.3 dplyr_0.8.4 rappdirs_0.3.1 Rcpp_1.0.3
[43] Biobase_2.46.0 vctrs_0.2.2 multtest_2.42.0 gdata_2.18.0 ape_5.3 nlme_3.1-144
[49] gbRd_0.4-11 lmtest_0.9-37 stringr_1.4.0 globals_0.12.5 mime_0.9 lifecycle_0.1.0
[55] irlba_2.3.3 gtools_3.8.1 future_1.16.0 MASS_7.3-51.5 zoo_1.8-7 scales_1.1.0
[61] promises_1.1.0 parallel_3.6.2 sandwich_2.5-1 RColorBrewer_1.1-2 curl_4.3 reticulate_1.14
[67] pbapply_1.4-2 gridExtra_2.3 stringi_1.4.5 mutoss_0.1-12 plotrix_3.7-7 caTools_1.18.0
[73] BiocGenerics_0.32.0 bibtex_0.4.2.2 Rdpack_0.11-1 rlang_0.4.4 pkgconfig_2.0.3 bitops_1.0-6
[79] lattice_0.20-38 ROCR_1.0-7 purrr_0.3.3 htmlwidgets_1.5.1 cowplot_1.0.0 tidyselect_1.0.0
[85] RcppAnnoy_0.0.14 plyr_1.8.5 magrittr_1.5 R6_2.4.1 gplots_3.0.1.2 multcomp_1.4-12
[91] withr_2.1.2 pillar_1.4.3 sn_1.5-5 fitdistrplus_1.0-14 survival_3.1-8 tibble_2.1.3
[97] future.apply_1.4.0 tsne_0.1-3 crayon_1.3.4 KernSmooth_2.23-16 plotly_4.9.2 grid_3.6.2
[103] data.table_1.12.8 metap_1.3 digest_0.6.24 xtable_1.8-4 tidyr_1.0.2 httpuv_1.5.2
[109] numDeriv_2016.8-1.1 openssl_1.4.1 RcppParallel_4.4.4 stats4_3.6.2 munsell_0.5.0 viridisLite_0.3.0
[115] askpass_1.1
I had this exact problem, but after many many hours I found the solution in this thread:
https://github.com/satijalab/seurat/issues/2716
You simply need to install the development version. Hope this helps!

Automation test report issues with JENKINS/MAVEN/ECLIPSE

I am facing issues while generating reports after successful build using maven in jenkins.
First, I have created java code into my local machine using eclipse.
Second, After creating the code I converted it to the Maven and completed all required setup of pom.xml file inside jenkins using Maven.
Third, I ran the script it gives me the success response.
Below, it is my maven success build result logs.
Started by user jenkin
Building in workspace /var/lib/jenkins/workspace/TestProject
Parsing POMs
Modules changed, recalculating dependency graph
Established TCP socket on 35275
[TestProject01] $ java -cp /var/lib/jenkins/plugins/maven-plugin/WEB-INF/lib/maven35-agent-1.12.jar:/var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/Maven1/boot/plexus-classworlds-2.5.2.jar:/var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/Maven1/conf/logging jenkins.maven3.agent.Maven35Main /var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/Maven1 /var/cache/jenkins/war/WEB-INF/lib/remoting-3.27.jar /var/lib/jenkins/plugins/maven-plugin/WEB-INF/lib/maven35-interceptor-1.12.jar /var/lib/jenkins/plugins/maven-plugin/WEB-INF/lib/maven3-interceptor-commons-1.12.jar 35275
<===[JENKINS REMOTING CAPACITY]===>channel started
Executing Maven: -B -f /home/user/Documents/eclipse-workspace/TestProject01/pom.xml clean install
[INFO] Scanning for projects...
[HUDSON] Collecting dependencies info
[INFO]
[INFO] ------------------< TestProject01:TestProject01 >-------------------
[INFO] Building TestProject01 0.0.1-SNAPSHOT
[INFO] --------------------------------[ pom ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) # TestProject01 ---
[INFO]
[INFO] --- maven-install-plugin:2.4:install (default-install) # TestProject01 ---
[INFO] Installing /home/user/Documents/eclipse-workspace/TestProject01/pom.xml to /var/lib/jenkins/.m2/repository/TestProject01/TestProject01/0.0.1-SNAPSHOT/TestProject01-0.0.1-SNAPSHOT.pom
[WARNING] Attempt to (de-)serialize anonymous class org.jfrog.hudson.maven2.MavenDependenciesRecorder$1; see: https://jenkins.io/redirect/serialization-of-anonymous-classes/
[INFO]
[INFO] BUILD SUCCESS
[INFO] Total time: 2.821 s
[INFO] Finished at: 2019-02-05T19:09:16+05:30
[INFO] ------------------------------------------------------------------------
Waiting for Jenkins to finish collecting data
[JENKINS] Archiving /home/user/Documents/eclipse-workspace/TestProject01/pom.xml to TestProject01/TestProject01/0.0.1-SNAPSHOT/TestProject01-0.0.1-SNAPSHOT.pom
/home/user/Documents/eclipse-workspace/TestProject01/pom.xml is not inside /var/lib/jenkins/workspace/TestProject/home/user/Documents/eclipse-workspace/TestProject01/; will archive in a separate pass
channel stopped
[htmlpublisher] Archiving HTML reports...
[htmlpublisher] Archiving at PROJECT level /home/user/Documents/eclipse-workspace/TestProject01/test-output to /var/lib/jenkins/jobs/TestProject/htmlreports/HTML_20Report
Finished: SUCCESS
Now, The issue is I do not know how can I check if all testcases covered with success. Here, HTML report been generated but it stays the same after every build success which creating lot of confusion.
Please help!!!!!!!!

How to install Apache Atlas 1.1.0 on MacOS Mojave?

I am trying to setup Apache Atlas on my system. I am encountering the following error
I read the article as suggested (http://cwiki.apache.org/confluence/display/MAVEN/PluginConfigurationException) but I was unable to understand what it was trying to convey.
[INFO] >>> findbugs-maven-plugin:3.0.1:check (findbugs-check) > :findbugs # apache-atlas >>>
[INFO]
[INFO] --- findbugs-maven-plugin:3.0.1:findbugs (findbugs) # apache-atlas ---
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.codehaus.groovy.reflection.CachedClass$3$1 (file:/Users/r0r017e/.m2/repository/org/codehaus/groovy/groovy-all/2.4.0/groovy-all-2.4.0.jar) to method java.lang.Object.finalize()
WARNING: Please consider reporting this to the maintainers of org.codehaus.groovy.reflection.CachedClass$3$1
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
...
[INFO] Apache Atlas Server Build Tools 1.0 ................ SUCCESS [ 0.632 s]
[INFO] apache-atlas 1.1.0 ................................. FAILURE [ 3.341 s]
...
[ERROR] Failed to execute goal org.codehaus.mojo:findbugs-maven-plugin:3.0.1:findbugs (findbugs) on project apache-atlas: Unable to parse configuration of mojo org.codehaus.mojo:findbugs-maven-plugin:3.0.1:findbugs for parameter pluginArtifacts: Cannot assign configuration entry 'pluginArtifacts' with value '${plugin.artifacts}' of type java.util.Collections.UnmodifiableRandomAccessList to property of type java.util.ArrayList -> [Help 1]
I need to setup Apache Atlas via Cassandra as a backend store. I am new to data governance and open source solutions, any help would be appreciated!
If you are just testing Atlas I suggest using a docker image. The following worked for me. https://github.com/michalmiklas/atlas-docker

USRP1 with RFX2400: Loading the "unknown" daughterboard

I'm trying to utilize the outdated SDR USRP1 with a daughterboard RFX2400. But it does not provide any items.
So, I ran uhd_usrp_probe:
$ uhd_usrp_probe
[INFO] [UHD] linux; GNU C++ version 5.4.0 20160609; Boost_105800; UHD_3.11.0.git-94-g5964adcd
[INFO] [USRP1] Opening a USRP1 device...
[INFO] [USRP1] Using FPGA clock rate of 64.000000MHz...
[ERROR] [DBMGR] The daughterboard manager encountered a recoverable error in init.
Loading the "unknown" daughterboard implementations to continue.
The daughterboard cannot operate until this error is resolved.
LookupError: KeyError: key "0" not found in dict(i, N14adf4360_regs_t17prescaler_value_tE)
How should I resolve the error?

EvoSuite test generation stucks when using maven plugin

I Have followed steps given in the site to configure maven plugin. When I give "mvn evosuite:generate", it hangs with below detail in console.
[INFO] Going to start job for: com.emirates.gws.service.grouprequest.GroupRequestServiceImpl.
Following are the environment detail
Windows 7
maven-3.2.1
jdk1.7.0_72
Following are the detail shown in console
[INFO] --- evosuite-maven-plugin:0.2.0:generate (default-cli) # gws-grouprequest-implementation ---
[WARNING] The POM for org.slf4j:slf4j-api:jar:1.7.12 is missing, no dependency information available
[WARNING] The POM for org.ow2.asm:asm-all:jar:5.0.4 is missing, no dependency information available
[WARNING] The POM for dk.brics.automaton:automaton:jar:1.11-8 is missing, no dependency information available
[WARNING] The POM for com.googlecode.gentyref:gentyref:jar:1.2.0 is missing, no dependency information available
[WARNING] The POM for net.sf.jgrapht:jgrapht:jar:0.8.3 is missing, no dependency information available
[WARNING] The POM for commons-cli:commons-cli:jar:1.3 is missing, no dependency information available
[WARNING] The POM for org.kohsuke:graphviz-api:jar:1.1 is missing, no dependency information available
[INFO] Going to generate tests with EvoSuite
[INFO] Total memory: 800mb
[INFO] Time per class: 2 minutes
[INFO] Number of used cores: 1
[INFO] Target: D:\EGIT\Projects\GWS\Source\gws-project-MICE\gws-grouprequest\gws-grouprequest-implementation\target\classes
[INFO] Basedir: D:\EGIT\Projects\GWS\Source\gws-project-MICE\gws-grouprequest\gws-grouprequest-implementation
[INFO] SLF4J: Class path contains multiple SLF4J bindings.
[INFO] SLF4J: Found binding in [jar:file:/D:/EGIT/Projects/GWS/M2_REPO/org/evosuite/evosuite-master/0.2.0/evosuite-master-0.2.0.jar!/org/slf4j/impl/S
taticLoggerBinder.class]
[INFO] SLF4J: Found binding in [jar:file:/D:/EGIT/Projects/GWS/M2_REPO/org/evosuite/evosuite-runtime/0.2.0/evosuite-runtime-0.2.0.jar!/org/slf4j/impl
/StaticLoggerBinder.class]
[INFO] SLF4J: Found binding in [jar:file:/D:/EGIT/Projects/GWS/M2_REPO/ch/qos/logback/logback-classic/1.1.3/logback-classic-1.1.3.jar!/org/slf4j/impl
/StaticLoggerBinder.class]
[INFO] SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
[INFO] SLF4J: Actual binding is of type [ch.qos.logback.classic.util.ContextSelectorStaticBinder]
[INFO] * EvoSuite
[INFO] [MASTER] 21:49:11.703 [main] WARN ProjectAnalyzer - Cannot handle com.emirates.gws.service.payments.PaymentServiceImpl due to: class java.lan
g.ClassNotFoundException Method code too large!
[INFO] Going to execute 32 jobs
[INFO] Going to start job for: com.emirates.gws.service.grouprequest.GroupRequestServiceImpl
From your settings, it looks like you are using 1 core, 2 minutes per class, and trying to generate tests for 32 classes: this means it will take up to 64 minutes to complete. However, each time a new class is done (roughly every 2 minutes), you should get a new entry in the logs.
Btw, it seems you are using only 800MB of memory. Just in case, it is better to use some more, eg 1-1.5GB
Following is bit worrying:
[INFO] [MASTER] 21:49:11.703 [main] WARN ProjectAnalyzer - Cannot handle com.emirates.gws.service.payments.PaymentServiceImpl due to: class java.lan
g.ClassNotFoundException Method code too large!
Java does have limits on how large a method can be. EvoSuite needs to add some instrumentation on the bytecode to work, and that might lead to exceed the limit :(