Problem in approving internal requests thru order manager after MRP run

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

Problem in approving internal requests thru order manager after MRP run

eejaz.ahmed
Hi all,
I am quite new to ofbiz. I was reading "Getting started with Apache Ofbiz Manufacturing and MRP" by Sharan Foga. When I run MRP, it shows some requirements based upon min/max stock settings. When I go to  Order Manager > Requirements > Approve requirements and check the approve checkbox for internal requirement, I get the following error:
The Following Errors Occurred:Error calling event: org.ofbiz.webapp.event.EventHandlerException: Commit multi-service global transaction failed

I initially run this on ofbiz from trunk. Then i tried all this on Ofbiz release 10.04 too. Both have same error. Any suggestion to troubleshoot this shall be highly appreciated.

Regards:

Ejaz Ahmed


     
Reply | Threaded
Open this post in threaded view
|

Re: Problem in approving internal requests thru order manager after MRP run

Sharan-F
Hi Ejaz

Did you run through the instructions as exactly described in the guide or did you do any variations? I will run a sample test through on 10.04 to see if I get the same error.

Thanks
Sharan

Reply | Threaded
Open this post in threaded view
|

RE: Problem in approving internal requests thru order manager after MRP run

eejaz.ahmed



Hi Sharan,
Thanks for your response. I run the same steps as described in your guide. I have tried this twice (on trunk and 10.04).

Regards:

Ejaz Ahmed





> Date: Mon, 18 Mar 2013 13:57:34 -0700
> From: [hidden email]
> To: [hidden email]
> Subject: Re: Problem in approving internal requests thru order manager after MRP run
>
> Hi Ejaz
>
> Did you run through the instructions as exactly described in the guide or
> did you do any variations? I will run a sample test through on 10.04 to see
> if I get the same error.
>
> Thanks
> Sharan
>
>
>
>
>
> --
> View this message in context: http://ofbiz.135035.n4.nabble.com/Problem-in-approving-internal-requests-thru-order-manager-after-MRP-run-tp4639893p4639912.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.

     
Reply | Threaded
Open this post in threaded view
|

RE: Problem in approving internal requests thru order manager after MRP run

eejaz.ahmed
In reply to this post by Sharan-F
Hi Sharan,
Thanks for your response. I run the same steps as described in your guide. Tried this twice (on trunk and 10.04).

Regards:

Ejaz Ahmed
Sr. Software Dev. Engineer
Mentor Graphics, Pakistan




> Date: Mon, 18 Mar 2013 13:57:34 -0700
> From: [hidden email]
> To: [hidden email]
> Subject: Re: Problem in approving internal requests thru order manager after MRP run
>
> Hi Ejaz
>
> Did you run through the instructions as exactly described in the guide or
> did you do any variations? I will run a sample test through on 10.04 to see
> if I get the same error.
>
> Thanks
> Sharan
>
>
>
>
>
> --
> View this message in context: http://ofbiz.135035.n4.nabble.com/Problem-in-approving-internal-requests-thru-order-manager-after-MRP-run-tp4639893p4639912.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.
     
Reply | Threaded
Open this post in threaded view
|

RE: Problem in approving internal requests thru order manager after MRP run

Sharan-F
In reply to this post by eejaz.ahmed
Hi Ejaz

I've just run through the complete MRP 5 step scenario using the 10.04 demo version on this website and I've had no problems approving the Internal Requirement.

Are you using the demo version here or are you running it on your own installation?  I would suggest that you try running it on this demo here and see if it happens again.

Thanks
Sharan
Reply | Threaded
Open this post in threaded view
|

RE: Problem in approving internal requests thru order manager after MRP run

eejaz.ahmed
Hi Sharan,
I was using my own installation. Now I've run the MRP scenario using 10.04 demo on website and had no problem. Later I tried on my own installation of 12.04 (which is in release phase) and got the same problem. I think there is some problem in my installation. I build using ant load-demo and started ofbiz using ant start. Can you suggest some solution?
I have also found an open issue with same error message which is located here:https://issues.apache.org/jira/browse/OFBIZ-3696


Regards:

Ejaz Ahmed





> Date: Tue, 19 Mar 2013 06:15:40 -0700
> From: [hidden email]
> To: [hidden email]
> Subject: RE: Problem in approving internal requests thru order manager after MRP run
>
> Hi Ejaz
>
> I've just run through the complete MRP 5 step scenario using the 10.04 demo
> version on this website and I've had no problems approving the Internal
> Requirement.
>
> Are you using the demo version here or are you running it on your own
> installation?  I would suggest that you try running it on this demo here and
> see if it happens again.
>
> Thanks
> Sharan
>
>
>
> --
> View this message in context: http://ofbiz.135035.n4.nabble.com/Problem-in-approving-internal-requests-thru-order-manager-after-MRP-run-tp4639893p4639922.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.
     
Reply | Threaded
Open this post in threaded view
|

RE: Problem in approving internal requests thru order manager after MRP run

Sharan-F
Hi Ejaz

I've got no suggestions I'm afraid although I'm currently updating my books and all other documents like the 5 step guides so will be doing some further testing on the other OFBiz versions you've mentioned in the next couple of weeks. If I come across your error then I'll do some detailed investigation to see what might be triggering it.

Thanks
Sharan



Reply | Threaded
Open this post in threaded view
|

RE: Problem in approving internal requests thru order manager after MRP run

eejaz.ahmed
Hi Sharan,
Thanks for your response. I am also investigating this error by looking into source. Somehow, it is trying to automatically run MRP when I approve internal order and fails to do so. However, I was able to manually run MRP without any issue. I will share this experience if I succeed.  

Regards:

Ejaz Ahmed





> Date: Wed, 20 Mar 2013 09:29:50 -0700
> From: [hidden email]
> To: [hidden email]
> Subject: RE: Problem in approving internal requests thru order manager after MRP run
>
> Hi Ejaz
>
> I've got no suggestions I'm afraid although I'm currently updating my books
> and all other documents like the 5 step guides so will be doing some further
> testing on the other OFBiz versions you've mentioned in the next couple of
> weeks. If I come across your error then I'll do some detailed investigation
> to see what might be triggering it.
>
> Thanks
> Sharan
>
>
>
>
>
>
>
> --
> View this message in context: http://ofbiz.135035.n4.nabble.com/Problem-in-approving-internal-requests-thru-order-manager-after-MRP-run-tp4639893p4639950.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.
     
Reply | Threaded
Open this post in threaded view
|

RE: Problem in approving internal requests thru order manager after MRP run

Sharan-F
Hi Ejaz

For  info - What OFBiz tries to do when you approve the Internal Requirement is to create a Production Run.

I did run a test through 12.04 and got an error too so took a copy of the log (see below).  I’m not sure if this is the exact same issue you encountered.

The first thing to point out is that I’m running OFBiz using a server based in New Zealand and I’m in Europe so there is a time difference of 11 hours as they are ahead of me.

Going through that 5 Step Manufacturing scenario – when I created the BOM for the wood, nails and varnish all the default dates and timestamps are taken from the NZ server by default (so in my case this was  06.43am on 29th March 2013) although in Europe it was  only 16.43 on 28th March 2013.

I ran MRP ran but when I tried to approve the Internal Requirement in Order Manager for the table (as you did) – I got the error message because it says that no production run is required as at 17.29 on 28th March. I think this is because the BOM isnt active until 29th March 2013 at 06.43am.

It seems that in some cases the default date used by OFBiz is the system date and other times it is the user’s local date and time.

Please check to see if this could be the source of your error.  If so then I think you’ll be able to correct it by  

• Updating the start dates and times for the BOM (don’t forget to do the table product linked the BOM and routing too)
• By waiting until the BOM is active and re-running MRP

Hope this helps.

Thanks
Sharan

See below for an extract of the log file.

2013-03-29 06:53:54,136 (http-bio-0.0.0.0-8443-exec-28) [ ServiceEcaRule.java:157:INFO ] Running Service ECA Service: createProductionRunFromRequirement, triggered by rule on Service: updateRequirement
2013-03-29 06:53:54,190 (http-bio-0.0.0.0-8443-exec-28) [ ServiceDispatcher.java:525:ERROR] Error in Service [createProductionRunsForProductBom]: No production run is required for product with id 10003 in date 2013-03-28 17:29:59.995; please verify the validity dates of the bill of materials and routing.
2013-03-29 06:53:54,199 (http-bio-0.0.0.0-8443-exec-28) [ TransactionUtil.java:379:WARN ] ---- exception report ---------------------------------------------------------- [TransactionUtil.setRollbackOnly] Calling transaction setRollbackOnly; this stack trace shows where this is happening: Exception: java.lang.Exception Message: Error in Service [createProductionRunsForProductBom]: No production run is required for product with id 10003 in date 2013-03-28 17:29:59.995; please verify the validity dates of the bill of materials and routing. ---- stack trace --------------------------------------------------------------- java.lang.Exception: Error in Service [createProductionRunsForProductBom]: No production run is required for product with id 10003 in date 2013-03-28 17:29:59.995; please verify the validity dates of the bill of materials and routing. org.ofbiz.entity.transaction.TransactionUtil.setRollbackOnly(TransactionUtil.java:379) org.ofbiz.entity.transaction.TransactionUtil.rollback(TransactionUtil.java:320) org.ofbiz.service.ServiceDispatcher.runSync(ServiceDispatcher.java:529) org.ofbiz.service.ServiceDispatcher.runSync(ServiceDispatcher.java:225) org.ofbiz.service.GenericDispatcher.runSync(GenericDispatcher.java:163) org.ofbiz.manufacturing.jobshopmgt.ProductionRunServices.createProductionRunFromRequirement(ProductionRunServices.java:2243
Reply | Threaded
Open this post in threaded view
|

Re: Problem in approving internal requests thru order manager after MRP run

Atul Vani
In reply to this post by eejaz.ahmed
Comments inline.

On Sun, 07 Apr 2013 21:41:57 +0530, Sharan-F <[hidden email]> wrote:

> Hi Ejaz
>
> For  info - What OFBiz tries to do when you approve the Internal  
> Requirement
> is to create a Production Run.
>
> I did run a test through 12.04 and got an error too so took a copy of the
> log (see below).  I’m not sure if this is the exact same issue you
> encountered.
>
> The first thing to point out is that I’m running OFBiz using a server  
> based
> in New Zealand and I’m in Europe so there is a time difference of 11  
> hours
> as they are ahead of me.
>
> Going through that 5 Step Manufacturing scenario – when I created the BOM
> for the wood, nails and varnish all the default dates and timestamps are
> taken from the NZ server by default (so in my case this was  06.43am on  
> 29th
> March 2013) although in Europe it was  only 16.43 on* 28th March 2013.*
>
> I ran MRP ran but when I tried to approve the Internal Requirement in  
> Order
> Manager for the table (as you did) – I got the error message because it  
> says
> that no production run is required as at 17.29 on 28th March. I think  
> this
> is because the BOM isnt active until 29th March 2013 at 06.43am.
>
> It seems that in some cases the default date used by OFBiz is the system
> date and other times it is the user’s local date and time.

When someone uses a datetime picker, he might select the time according to  
his local clock. However server's clock might differ, one can check the  
server time in the bottom right corner. If he does not select any time at  
all, it is considered as 0:00

>
> Please check to see if this could be the source of your error.  If so  
> then I
> think you’ll be able to correct it by
>
> • Updating the start dates and times for the BOM (don’t forget to do the
> table product linked the BOM and routing too)
> • By waiting until the BOM is active and re-running MRP
>
> Hope this helps.
>
> Thanks
> Sharan
>
> See below for an extract of the log file.
>
> 2013-03-29 06:53:54,136 (http-bio-0.0.0.0-8443-exec-28) [
> ServiceEcaRule.java:157:INFO ] Running Service ECA Service:
> createProductionRunFromRequirement, triggered by rule on Service:
> updateRequirement
> 2013-03-29 06:53:54,190 (http-bio-0.0.0.0-8443-exec-28) [
> ServiceDispatcher.java:525:ERROR] Error in *Service
> [createProductionRunsForProductBom]: No production run is required for
> product with id 10003 in date 2013-03-28 17:29:59.995; please verify the
> validity dates of the bill of materials and routing. *
> 2013-03-29 06:53:54,199 (http-bio-0.0.0.0-8443-exec-28) [
> TransactionUtil.java:379:WARN ] ---- exception report
> ----------------------------------------------------------
> [TransactionUtil.setRollbackOnly] Calling transaction setRollbackOnly;  
> this
> stack trace shows where this is happening: Exception: java.lang.Exception
> Message: Error in Service [createProductionRunsForProductBom]: No  
> production
> run is required for product with id 10003 in date 2013-03-28  
> 17:29:59.995;
> please verify the validity dates of the bill of materials and routing.  
> ----
> stack trace  
> ---------------------------------------------------------------
> java.lang.Exception: Error in Service  
> [createProductionRunsForProductBom]:
> No production run is required for product with id 10003 in date  
> 2013-03-28
> 17:29:59.995; please verify the validity dates of the bill of materials  
> and
> routing.
> org.ofbiz.entity.transaction.TransactionUtil.setRollbackOnly(TransactionUtil.java:379)
> org.ofbiz.entity.transaction.TransactionUtil.rollback(TransactionUtil.java:320)
> org.ofbiz.service.ServiceDispatcher.runSync(ServiceDispatcher.java:529)
> org.ofbiz.service.ServiceDispatcher.runSync(ServiceDispatcher.java:225)
> org.ofbiz.service.GenericDispatcher.runSync(GenericDispatcher.java:163)
> org.ofbiz.manufacturing.jobshopmgt.ProductionRunServices.createProductionRunFromRequirement(ProductionRunServices.java:2243
>
>
>
>
> --
> View this message in context:  
> http://ofbiz.135035.n4.nabble.com/Problem-in-approving-internal-requests-thru-order-manager-after-MRP-run-tp4639893p4640485.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.


--
Using Opera's revolutionary email client: http://www.opera.com/mail/
Reply | Threaded
Open this post in threaded view
|

Re: Problem in approving internal requests thru order manager after MRP run

Sharan-F
Hi Atul

Thanks very much for your response on this and I’ve taken another look at one of the screens that uses the date picker.

The one I used for this test was the BOM screen (manufacturing/control/UpdateProductBom)

In the ‘From Date’ field the help text says that it “Will be set to Now if empty”. In this case if you leave it blank it will take the server time and not the local user time (but if you use the date picker and select ‘Now’ it will default to the user’s local time.)

I think this is a bit confusing.

Thanks
Sharan
Reply | Threaded
Open this post in threaded view
|

Re: Problem in approving internal requests thru order manager after MRP run

Atul Vani
In reply to this post by eejaz.ahmed
That explains the incidence (issue! I disagree) well, thanks.

On Mon, 08 Apr 2013 13:12:11 +0530, Sharan-F <[hidden email]> wrote:

> Hi Atul
>
> Thanks very much for your response on this and I’ve taken another look at
> one of the screens that uses the date picker.
>
> The one I used for this test was the BOM screen
> (manufacturing/control/UpdateProductBom)
>
> In the ‘From Date’ field the help text says that it “Will be set to Now  
> if
> empty”. In this case if you leave it blank it will take the server time  
> and
> not the local user time (but if you use the date picker and select ‘Now’  
> it
> will default to the user’s local time.)
>
> I think this is a bit confusing.
>
> Thanks
> Sharan
>
>
>
>
> --
> View this message in context:  
> http://ofbiz.135035.n4.nabble.com/Problem-in-approving-internal-requests-thru-order-manager-after-MRP-run-tp4639893p4640506.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.


--
Using Opera's revolutionary email client: http://www.opera.com/mail/
Reply | Threaded
Open this post in threaded view
|

RE: Problem in approving internal requests thru order manager after MRP run

Sharan-F
In reply to this post by eejaz.ahmed
Hi Ejaz

Just as quick update on this. I’ve run some more scenarios through and have managed to get the internal requirement approved and run it all the way through to the end.

The main way to achieve this is by making sure that you always use the date picker that Atul mentions and always click the ‘Now’ button so that your true current date is used.

I will update the Manufacturing 5 Steps document with this new information and include some additional screenshots about it.

Thanks
Sharan