Talk:Mfg Libero migration project

From ADempiere
Jump to: navigation, search
This Wiki is read-only for reference purposes to avoid broken links.

Hi Wight (Tim) I m ready to assist in the 2pack understanding. You should not create the minutes page but use this discussion talk page for those points there instead (u can move those here, so that it is intuitional to find stuff. And need not create link.

About your background i wana ask, have u done Compiere before? Anyway i m happy u are here. Welcome and as i said i m happy to help. Teaching is my forte.

Red1 17:14, 22 November 2006 (EST)

Entry needs to be remaned

I propose Kompiere libero migration project, as this Kompiere libero is the official name in Sourceforge.--Khalid HASSANI 18:04, 22 November 2006 (EST)


Notes on project

Oracle seed dump for libero according to Carlos Ruiz: http://svn.sourceforge.net/viewvc/adempiere/tags/release-2.5.3b-initial/data/seed/Compiere.jar

Progress on 12/19/2006

I installed oracle 10.1 on centos 4.3. I compiled kompiere libero in the contributions directory of the adempiere subversion. I then was also able to execute ./install/Compiere2/RUN_setup.sh. It failed on the database saying it could not login with compiere/compiere and that the database had not been imported. I then tried to run the RUN_ImportCompiere.sh script and that failed. I beleive it is failing because the myEnvironment.sh is not set right. the myEnvironment.sh is set by RUN_setup.sh so I feel like the chicken before the egg thing is occuring. I did unzip Compiere.jar in the data see directory of the kompiere libero data directory so I am close to importing/creating the oracle database.

Progress on 12/20/2006

I talked with Karsten a great deal and he helped me to figure out some problems I was having with installing/build libero. What is interesting to understand is that Karsten said I only had to run 2 scripts:

  • 310 to 311 migration script
  • 311 to 312 migration script

Running these scripts would import the libero database changes into an adempiere 312 oracle install. Karsten also told me that the migration scripts may have some problems as sqlplus can't handle very large lines for some reason. I finally got the kompiere libero server up. When I tried to login I got an error. Victor thinks I have the wrong version of Kompiere libero or Oracle. I have posted in the developer forum about this at:

http://sourceforge.net/forum/forum.php?thread_id=1635853&forum_id=610548

Not exactly - running these scripts will upgrade the libero database to an adempiere 312 preserving :all existing libero customizations. After this make a dump of the migrated database and this will be :and Adempiere+libero seed dmp. And not the scripts have the problems - it's a sqlplus problem ;)
Next step would be to adjust the scripts for postgreSQL, therefore you have to change the datatypes :from oracle to postgresql - there was a document in the wiki about that but I think it got lost in :the backup trouble -- Karsten Thiemann 11:00, 21 December 2006 (GMT+1)

I don't understand what I could have done wrong. Victor says he will handle the migration and it will be done by 12/27/2006.

I finally got in! I added connectionprofile to ad_user and ad_role and got in! Victor said that those fields are from 253d. Victor also said that I don't need to run RUN_ImportCompiere.sh just RUN_DBRestore.sh on the dump he gave me. He said he will verify his dump tomorrow to see if it is correct.

SOLUTION

You must be root to run the RUN_setup.sh ! So do something like sudo bash ./RUN_setup.sh

Progress on 1/5/2007

I made some huge progress on Friday. I was talking with Victor about how I could help him. He sent me an oracle database dump for Oracle 10.2 ( ExpDat.mfgupdate.dmp ). I setup oracle 10.1 previously so I just used that. Victor wanted me to assist him with renaming tables/fields for the specific tables dealing with manufacturing and payroll from libero so they could be more easily migrated to Adempiere. He posted in the adempiere developers forum about this at:

http://sourceforge.net/forum/forum.php?thread_id=1644403&forum_id=610548

To accomplish this he gave me two choices. I could use druid database manager tool or another way I can't remember (think it was modify the ddl raw in text form). I told him I would do it the way he preferred. He preferred the druid way. I then imported the specific tables with beginning mpc_ strings and converted them to pp_. I then saved my druid project and sent it to Victor. He did not like the format and asked me to use the format that Trifon used for his druid project at:

http://adempiere.svn.sourceforge.net/viewvc/*checkout*/adempiere/contributions/253b/comxe/_Project-ID-ComXe_Standard/druid/Project-ID-ComXe_Standard.druid

I ran out of time and told Victor I would continue on Monday.


Oracle Notes

  1. . oraenv
  2. lsnrctl stop
  3. lsnrctl start
  4. sqlplus /nolog
  5. conn / as sysdba
  6. shutdown
  7. startup

To import the dump I used the command:

imp userid=system/compiere file=ExpDat.mfgupdate.dmp full=yes

The import did say it had some problems and I was told that the import would most likely fail if I was trying to import a dump from 10.2 into 10.1. All in all though it appeared to work.


Druid Notes

http://sourceforge.net/projects/druid/

  1. java -jar druid-3.8-install.jar
  2. java -jar druid.jar
  3. Install oracle jdbc driver: ojdbc14.jar from within disk druid

Victor also asked to generate sql.

When importing some of the tables, some of the fields were undefined. I do not know why this occurred. I assume it could be because of the import malfunction(s) from 10.2 to 10.1.

Progress on 1/9/2007

Today was probably one of the best days I have had on this project. One of the core features of MRP is the ability to do the following:

  * Automatic creation of recommended Purchase Orders (Requisition Orders according to Victor) and Manufacturing Orders based on demand.
  * The ability to then approved the recommended Purchase and Manufacturing Orders
  * The ability to schedule the Manufacturing Orders that have assigned materials on the appropriate resource
  * The ability to cancel demand and have the appropriate Manufacturing and Purchase orders be deleted

I will now explain how to do this in the Manufacturing module through a series of questions and answers.

What is the procedure to cause the Manufacturing module to generate purchase and manufacturing orders based on demand?

Manufacturing->Production Planning->MRP->Regenerate Material Plan

What should be done after the Regenerate Material Plan has run?

Look at the notices and Planned Order Approval Areas

What is in the notices area and why is it important?

The notices area will contain messages regarding how to deal with problems that regenerate material plan finds.

How does the regenerate material plan work at a high level?

  1. Deletes all Manufacturing and Purchase Orders that are in a draft status.
  2. It looks at the demand (Sales Orders, Forcasting, Minimum Levels of Stock) to see the needs of Inventory and Manufacutring orders to generate the appropriate products to fill the demand.
  3. It then looks at the Route of a particular product to see what steps, materials, and resources are needed to create the product.
  4. To generate the Purchase Orders it looks at the BOM to see if there are currently enough raw materials to generate the product.  If not it generates a recommendation for a purchase order.
  5. The steps in the route contain resources and durations which are then turned into recommended manufacturing orders.
  6. As the regenerate material plan is running it will send notices of things it finds of interest for the user to know/do.

How does the regenerate material plan handle the use case of cancelled demand?

It will create a notice telling the user to delete Manufacturing/Purchasing Orders as they are no longer needed. (I call this orphaned requests, as the reason they work created in the first place has been taken away).

What states can a Manufacturing Order have?

  1. Draft (Usually a recommendation created by the regenerate material plan will create manufacturing orders with a draft status)
  2. Awaiting materials
  3. In Process (This MO is active and the shop is made aware of it and that it should be scheduled/handled)
  4. Closed (Basically complete)

What is the process to schedule Manufacturing Orders on resources?

Manufacturing->Production Planning->CRP->Capacity Plan Calculation

The user must then choose foward or backward scheduling.

What is the process to see the schedule generated?

Manufacturing->Manufacturing Rules->Management Resource Manufacturing->Manufacturing Resource

Find the resource you want to see the schedule for and then do:

View->Schedule Info

Is it possible to enter a Manufacturing Order manually?

Yes.


What is important to know about a BOM entry as it relates to generation of Manufacturing Orders when the regenerate material plan is run?

A BOM entry must have make to order set for a MO to be created. If it only has order then only a purchase order will be generated.


Progress on 4/3/2007

I have been talking to Victor and Carlos Ruiz and the decision has been made to get libero in as a 2pack module. The problem is that 2pack is missing some functionality. The functionality missing is:

  1. Export and Import of workflows
  2. Export and Import of dynamic validations

I have accomplished the goals of created a 2 pack package, exporting it, and then importing the 2pack package into another adempiere instance. I have also created a new window in adempiere following the new window tutorial on the adempiere wiki. I am now reading:

http://www.google.com/url?sa=t&ct=res&cd=1&url=http%3A%2F%2Fwww.knowledgesuccess.com%2Fcompiere%2Fdoc%2Fcompiere%2FwfAnalysis.pdf&ei=JHURRsXxJaWYgQO-qNT2AQ&usg=__-UwhIIPttwM-tAKPvrKDKx-wlkY=&sig2=v-0JHHqbUA9RDO9ZezEaXA

which docouments how to create a workflow which is my next goal. The nice thing about reading this document is it is giving me good information for creating the test criteria for my 2pack enhancements.

2Pack Enhancements Tests

# Description Notes
1 Simple General Workflow Test Create a general workflow with 2 states, export, and import via 2pack
2 Advanced General Workflow Test Create a general workflow with 10 plus states, export, and import via 2pack
3 Simple Document Process Workflow Test Create a document process workflow with 2 states, export, and import via 2pack
4 Advanced Document Process Workflow Test Create a document process workflow with 10 plus states, export, and import via 2pack
5 Simple Document Value Workflow Test Create a document value process workflow with 2 states, export, and import via 2pack
6 Advanced Document Value Workflow Test Create a document value process workflow with 10 plus states, export, and import via 2pack

Some suggestions for workflow tests:

  • The workflow to export/import needs to use all features (Nodes, Parameter, Transitions and Conditions) with different Attributes (e.g. Workflow Responsible, Action ...) but it doesn't have to be a useful workflow.
  • Export/import of new workflow and of modified standard workflow (e.g. Process_Order with approval for purchase orders)
  • Number of states should be irrelevant

Progress on 4/10/2007

I have made excellent progress today. I created my first workflow and caused a document to go from start state to complete state. I asked Karsten-thieman for help in some problems I had. One of the bigger things I learned was how to actually edit in the workflow editor. The secret is to double right click. This allows for creation of new nodes as well as creating/deleting lines to those nodes.

Image:Wf1editor.png

I asked Karsten his opinion on my test plan. His opinion was that it did not matter as much how many workflows I do but the different types of nodes. He said he would help me flesh out my test plan tomorrow. In short he thinks all I need to do is to take entries out of ad_wf_* tables and export/import them. Support for 2pack transfer of java code, processes, etc... already exists. What is interesting to understand however is that a workflow does depend on a process and some java code at the very least. He suggested a checkbox to auto detect any dependencies the workflow would need and populate the package with those dependencies. According to Karsten all data that needs to be transfered can be found in the application dictionary. Karsten also mentioned a concern that there might be a need to differentiate between a new workflow and a modified standard workflow.

Progress on 6/25/2007

I managed to get Libero in and even scheduled my first manufaucturing order! I am learning some important things about the regenerate material plan:

1. You must load the org.eevolution.model.LiberoValidator in the System Admin -> Client Rules -> Client in the field Model Validation Class. This is necessary to that when a new order line is created it will inject a record into PP_MRP. The PP_MRP table holds all the demand info that the MRP process (regenerate material plan) uses to create requisition orders if the bom specifies a purchased item or a manufaucturing order if the bom specifies a manufactured part/item.

I have been working with Fernando on some of the bugs in my new import approach in XMLImportStructure.java in the extend directory. Victor is anxious for problems with why handleFieldsImport does not work the first time it is invoked. Richard also said he would assist.

Another interesting thing I learned is that before running the regenerate material plan that the calculate low level process must be run. The other bummer is that it doesn't appear that reports have imported for Libero.

My current goal is to get the regenerate material plan to genearate a manufacturing order and/or requisition.

Progress on 6/27/2007

One of my next goals was to find out how to see what nodes of the workflow route were scheduled to what resource and when. I figured this out today. According to Victor when a manufacturing order is created it copies the workflow and workflow nodes (route information) in with the manufacturing order in these tables: pp_order, pp_order_workflow, and ppOrder_node. You can see this graphically by doing the following:

1. login is GardenAdmin/GardenAdmin
2. Create demand by entering a sales order for a product (This creates an entry in the table pp_mrp. pp_mrp holds all demand info used by the regenerate material plan)
3. Manufacturing -> Production Planning -> MRP -> Calculate Low Level
4. Manufacturing -> Production Planning -> MRP -> Regenerate Material Plan
5. Now look to see what manufaucturing order(s) were created by navigating: Manufacturing -> Production Control -> discreet -> Manufacturing Order
6. Now open a manufacturing order and navigate to the node tab. Notice that date start schedule and date finish schedule are blank.
7. Now navigate and execute: Manufacturing -> Production Planning -> CRP -> Capacity Plan Calculation and choose the forward schedule type.

If you now go back to step 6 you will see the date schedule start and date finish fields are populated. I am still looking for an easy way to see what work needs to be done on a particular resource on a particular day. I am sure it is a report, just have to find it.

Progress on 6/28/2007

I didn't see the Planned Order Approval form on my MRP menu so I chased down that issue. I saw this in the libero PackOut.xml:

<menu ADMenuNameID="Planned Order Approval " ADWindowNameID="" ADProcessNameID="" ADFormNameID="Planned Order Approval " ADTaskNameID="" ADWorkbenchNameID="" ADWorkflowNameID="" ADParentMenuNameID="MRP" ADParentSeqno="6" Action="X" Description="Planned Order Approval " EntityType="D" isActive="true" isReadOnly="false" isSOTrx="false" isSummary="false"> <form ADFormNameID="Planned Order Approval " Classname="org.eevolution.form.VOrderPlanning" isBetaFunctionality="false" AccessLevel="3" Description="Planned Order Approval " isActive="true" EntityType="D" Help="" Name="Planned Order Approval "/>

I then checked the AD_Form area of the Application Dictionary and saw that it existed! I then logged in as System/System and it showed up. I then talked with Bahman and Fernando about what the problem could be. Someone told me that the form was not added to my role of GardenAdmin. So Bahman told me to do these steps which did fix it:

1. UPDATE AD_Form SET AccessLevel=7 WHERE AD_Form_ID=(Id of the form Planned Order Approval)
2. then login as SuperUser/System , Role=GA 3. then do a role access update

Now if you login as GardenAdmin now you should see the Planned Order Approval.

I then attempted to approve a manufacturing order and it failed with the following error:

MPPOrder.setKeyInfo: (PK) PP_Order_ID=1000027 [12]
10:22:55.383 MPPOrder.prepareIt: prepareIt - MPPOrder[1000027-1000002,IsSOTrx=false,C_DocType_ID=1000001] [12]
10:22:55.384 MPPOrder.prepareIt: MPPOrder[1000027-1000002,IsSOTrx=false,C_DocType_ID=1000001] [12]
Exception in thread "AWT-EventQueue-0" java.lang.ClassCastException: java.lang.String

        at org.eevolution.model.X_PP_Order.getC_DocTypeTarget_ID(X_PP_Order.java:218) 
at org.eevolution.model.MPPOrder.prepareIt(MPPOrder.java:1056)
at org.eevolution.form.VOrderPlanning.actionPerformed(VOrderPlanning.java:337)

I still don't know how to fix this.

I then attempted to run the MRP Review report. This failed completely. I looked at the Libero PackOut.xml and saw:

<process Name="MRP Review" ADWorkflowNameID="" ADProcessNameID="MRP Review" ADPrintFormatNameID="" ADReportViewNameID="RV_PP_MRP" AccessLevel="3" Classname="" Description="" EntityType="D" Help="" isBetaFunctionality="false" isDirectPrint="false" isReport="true" isActive="true" ProcedureName="" StatisticCount="0" StatisticSeconds="0" Value="RV_PP_MRP" WorkflowValue="">

This imported, but what I discovered was that the ReportView definition was not in the PackOut.xml. No ReportViews were put in the PackOut.xml. As a result no reports will work in the libero manufacturing module.

 I also made my first report with a report view to better understand this with Bahman's help!

Progress on 6/29/2007

I successfully ran a regenerate material plan that created requisitions and a manufacturing order. One of my biggest questions was how to determine the schedule of work on a workcenter on a certain day. I finally figured out how to do this by going to the Shop Floor area under MRP and running the Shop Floor Transactions report. What was disappointing is this report did not seem to work well (at all) by just picking a resource which is what I wanted to do. You have to pick a manufacturing order which kind of defeats the purpose. I hope to fix the code to allow for this. Victor mentioned using the resource load view to "balance" the work on a workcenter. I am totally confused by this. Perhaps he can enlighten me on it.

More team members sighted

  • You might want to add further names to our team. I notice AS, Mutha and Richard-4layers joining the force. But let me take this opportunity to make a more formal statement here. You Rock!!! - Red1 21:47, 27 June 2007 (EDT)