[ 
https://issues.apache.org/jira/browse/OFBIZ-6783?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15290628#comment-15290628
 ] 

Jacques Le Roux commented on OFBIZ-6783:
----------------------------------------

OK, I will simply revert and let you handling things, it's indeed only 
formatting anyway.

BTW, I think I can't compare with what we had before because AFAIK we could 
only run all tests. But when I ran
bq. java -jar ofbiz.jar --test component=minilang --test
I got this in stopping phase
{code}
2016-05-19 09:22:51,685 |main                 |ContainerLoader               
|I| Started container testtools-container
2016-05-19 09:22:51,685 |main                 |ContainerLoader               
|I| Shutting down containers
2016-05-19 09:22:51,685 |main                 |ContainerLoader               
|I| Stopping container testtools-container
2016-05-19 09:22:51,685 |main                 |ContainerLoader               
|I| Stopped container testtools-container
2016-05-19 09:22:51,686 |main                 |ContainerLoader               
|I| Stopping container catalina-container-test
2016-05-19 09:22:51,844 |0.0.0.0-startStop-2  |ServiceContainer              
|I| Removing from cache dispatcher: ebay
2016-05-19 09:22:51,844 |0.0.0.0-startStop-2  |ServiceDispatcher             
|I| De-Registering dispatcher: ebay
2016-05-19 09:22:51,848 |0.0.0.0-startStop-2  |WebappClassLoaderBase         
|W| The web application [ebay] appears to have started a thread named 
[OFBiz-JobPoller] but has failed to stop it. This is very lik
ely to create a memory leak. Stack trace of thread:
 java.lang.Thread.sleep(Native Method)
 org.ofbiz.service.job.JobPoller$JobManagerPoller.run(JobPoller.java:214)
 java.lang.Thread.run(Unknown Source)
2016-05-19 09:22:51,849 |0.0.0.0-startStop-2  |WebappClassLoaderBase         
|W| The web application [ebay] appears to have started a thread named 
[RetryTimer] but has failed to stop it. This is very likely t
o create a memory leak. Stack trace of thread:
 java.lang.Object.wait(Native Method)
 java.lang.Object.wait(Unknown Source)
 java.util.TimerThread.mainLoop(Unknown Source)
 java.util.TimerThread.run(Unknown Source)
2016-05-19 09:22:51,849 |0.0.0.0-startStop-2  |WebappClassLoaderBase         
|W| The web application [ebay] appears to have started a thread named 
[ForkJoinPool-1-worker-3] but has failed to stop it. This is
very likely to create a memory leak. Stack trace of thread:
 sun.misc.Unsafe.park(Native Method)
 java.util.concurrent.ForkJoinPool.awaitWork(Unknown Source)
 java.util.concurrent.ForkJoinPool.runWorker(Unknown Source)
 java.util.concurrent.ForkJoinWorkerThread.run(Unknown Source)
2016-05-19 09:22:51,849 |0.0.0.0-startStop-2  |WebappClassLoaderBase         
|W| The web application [ebay] appears to have started a thread named 
[ForkJoinPool-1-worker-5] but has failed to stop it. This is
very likely to create a memory leak. Stack trace of thread:
 sun.misc.Unsafe.park(Native Method)
 java.util.concurrent.ForkJoinPool.awaitWork(Unknown Source)
 java.util.concurrent.ForkJoinPool.runWorker(Unknown Source)
 java.util.concurrent.ForkJoinWorkerThread.run(Unknown Source)
2016-05-19 09:22:51,849 |0.0.0.0-startStop-2  |WebappClassLoaderBase         
|W| The web application [ebay] appears to have started a thread named 
[ForkJoinPool-1-worker-6] but has failed to stop it. This is
very likely to create a memory leak. Stack trace of thread:
 sun.misc.Unsafe.park(Native Method)
 java.util.concurrent.ForkJoinPool.awaitWork(Unknown Source)
 java.util.concurrent.ForkJoinPool.runWorker(Unknown Source)
 java.util.concurrent.ForkJoinWorkerThread.run(Unknown Source)
2016-05-19 09:22:51,850 |0.0.0.0-startStop-2  |WebappClassLoaderBase         
|W| The web application [ebay] appears to have started a thread named 
[ForkJoinPool-1-worker-7] but has failed to stop it. This is
very likely to create a memory leak. Stack trace of thread:
 sun.misc.Unsafe.park(Native Method)
 java.util.concurrent.ForkJoinPool.awaitWork(Unknown Source)
 java.util.concurrent.ForkJoinPool.runWorker(Unknown Source)
 java.util.concurrent.ForkJoinWorkerThread.run(Unknown Source)
2016-05-19 09:22:51,856 |0.0.0.0-startStop-2  |ServiceContainer              
|I| Removing from cache dispatcher: marketing
2016-05-19 09:22:51,856 |0.0.0.0-startStop-2  |ServiceDispatcher             
|I| De-Registering dispatcher: marketing
2016-05-19 09:22:51,869 |0.0.0.0-startStop-2  |ServiceContainer              
|I| Removing from cache dispatcher: oagismgr
2016-05-19 09:22:51,869 |0.0.0.0-startStop-2  |ServiceDispatcher             
|I| De-Registering dispatcher: oagismgr
2016-05-19 09:22:51,875 |0.0.0.0-startStop-2  |ServiceContainer              
|I| Removing from cache dispatcher: order
2016-05-19 09:22:51,875 |0.0.0.0-startStop-2  |ServiceDispatcher             
|I| De-Registering dispatcher: order
2016-05-19 09:22:51,881 |0.0.0.0-startStop-2  |ServiceContainer              
|I| Removing from cache dispatcher: googlecheckout
2016-05-19 09:22:51,881 |0.0.0.0-startStop-2  |ServiceDispatcher             
|I| De-Registering dispatcher: googlecheckout
{code}
Not a big deal, and it seems not related with your changes, just wanted to let 
you know

> Refactor the start component
> ----------------------------
>
>                 Key: OFBIZ-6783
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-6783
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: Upcoming Branch
>            Reporter: Taher Alkhateeb
>            Assignee: Taher Alkhateeb
>              Labels: framework, main, refactoring, start
>         Attachments: OFBIZ-6783.patch, OFBIZ-6783.patch, OFBIZ-6783.patch, 
> OFBIZ-6783.patch, OFBIZ-6783.patch, OFBIZ-6783.patch, OFBIZ-6783.patch, 
> OFBIZ-6783.patch, OFBIZ-6783.patch, StartCommandUtil.java
>
>
> Looking at the main method and design of Start.java and the start component 
> overall looks ugly. The things I would like to fix so far are:
> - the files are too long
> - some variables are not even needed (loaderArgs?)
> - the level of abstraction is wrong
> - main throws an exception!
> - the arguments processing logic is terrible, need to move it to commons-cli
> It's just so messy and ugly to look at. So for me refactoring starts at 
> Start! Given that this is an important component, I will provide a patch to 
> be reviewed by the community before committing just to be on the safe side.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to