2011 Nov 19 6:25 PM
Hi,
I have requirement where my client is deciding whether to use implict enhancement inside an exit like MV45AFZZ. We are validating whether this is a right approach. Can you guys tell me the pro and cons of the same.
A few things we have been debating so far are like:
1. One developer does not need to wait for the object to be released by another developer while using enhancement. but if we get the key for MV45AFZZ, then we will have to wait for every developer to complete his task and move the development before another developer can touch the same exit.
2. While point 1 is a clear advantage, the same time one developer might not be aware of what someone else is doing on the same object which might cause issues related to regression.
3. Can some one tell me if there are any performance related issues between the two?
4. If there are multiple implementations under the same subroutine, do these get executed in the same order or do they follow the BAdi approach and can get executed in any order?
Please provide any other things that you can think of as well...
Thanks.
2011 Nov 21 4:38 AM
Hi,
Please create a badi definition( not implicit enhancement) with required methods and call it inside the exit.. I have read an article in SDN which demonstrates this.
Here its is [Implementing a badi in an enhancement project|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/d0456c54-0901-0010-f0b3-cd765fb99702?QuickLink=index&overridelayout=true] - Here the badi is implemented in a customer exit and you can also follow this approach for an user exit. Read the part under Historic Problem you will get the answer to your questions.
For execuitng the badi implementation in the order read [Need to control sequence of calls of Business Add In|http://www.google.co.in/url?sa=t&rct=j&q=badi%20sorter&source=web&cd=3&ved=0CDUQFjAC&url=http%3A%2F%2Fwww.sdn.sap.com%2Firj%2Fscn%2Findex%3Frid%3D%2Flibrary%2Fuuid%2Fe0d2f214-b1a5-2a10-f3a0-98c95afcf281%26overridelayout%3Dtrue&ei=G-LJTvDuH8XoOenOiLUL&usg=AFQjCNHyBqBKxEiBsvoxIke3nvsPLHdjhQ&sig2=ggqKb76zqoZ8F03NkbcGwQ&cad=rja]
Kesav
Edited by: Keshav.T on Nov 21, 2011 10:23 AM
Hi,
Please create a badi definition( not implicit enhancement) with required methods and call it inside the exit.. I have read an article in SDN which demonstrates this.
Here its is [Implementing a badi in an enhancement project|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/d0456c54-0901-0010-f0b3-cd765fb99702?QuickLink=index&overridelayout=true] - Here the badi is implemented in a customer exit and you can also follow this approach for an user exit. Read the part under Historic Problem you will get the answer to your questions.
For execuitng the badi implementation in the order read [Need to control sequence of calls of Business Add In|http://www.google.co.in/url?sa=t&rct=j&q=badi%20sorter&source=web&cd=3&ved=0CDUQFjAC&url=http%3A%2F%2Fwww.sdn.sap.com%2Firj%2Fscn%2Findex%3Frid%3D%2Flibrary%2Fuuid%2Fe0d2f214-b1a5-2a10-f3a0-98c95afcf281%26overridelayout%3Dtrue&ei=G-LJTvDuH8XoOenOiLUL&usg=AFQjCNHyBqBKxEiBsvoxIke3nvsPLHdjhQ&sig2=ggqKb76zqoZ8F03NkbcGwQ&cad=rja]
Kesav
Edited by: Keshav.T on Nov 21, 2011 10:23 AM
2011 Nov 19 8:35 PM
Hi,
This is not the best approach to be followed, there are other ways of doing it. For example you can create a subroutine program which will include subroutine with the parameters you need and you can write the logic inside that. This subroutine program and routine is stored in a custom table against the actual user exit name (MV45AFZZ), In the user exit you will write a select query to this custom table and to get the actual program and routine name and you will use that variable to pass it to the statement which calls this subroutine using PERFORM dynamic statement. You can have a field for priority and also you can have other attributes depending on your requirement. This can be used inside any kind of enhancements to separate the logic and to avoid regression testing.
Answer for your queries.
1. One developer does not need to wait for the object to be released by another developer while using enhancement. but if we get the key for MV45AFZZ, then we will have to wait for every developer to complete his task and move the development before another developer can touch the same exit.
--->This advantage can be achieved by different ways as mentioned above, also, this is a rare scenario and project development plan can be prepared in a way that it does need two developers working on the same object
2. While point 1 is a clear advantage, the same time one developer might not be aware of what someone else is doing on the same object which might cause issues related to regression.
--->If both are writing the logics which are dependent on each other then definitely they should be combined together
3. Can some one tell me if there are any performance related issues between the two?
--->*Yes, there could be performance issue but not that very high unless you bring in alot of such enhancements *
4. If there are multiple implementations under the same subroutine, do these get executed in the same order or do they follow the BAdi approach and can get executed in any order?
---> They will be executed in the same order.
Cheers,
2011 Nov 19 9:16 PM
Prasanna, Thanks for the reply.
Would you be able to elaborate the point where you have mentioned about performance? How does having multiple enhancements impact performance?
Thanks,
Vikram.M
2011 Nov 19 10:20 PM
Let me re frame my answer, it won't affect the performance at a significant level. But i was trying to say is IMPLICIT ENHANCEMENTS are not recommended by SAP..
The performance is only about loading the enhancement programs when you call VA01 transaction which will be least significant that you would notice.
Cheers,
Prasanna
2011 Nov 20 7:14 PM
Is there any pros or cons that someone else can think of?
Thanks,
Vikram.M
2011 Nov 20 7:33 PM
Implicit enhancements since they function through BADI (new CLASSes / methods added to memory call stack) may make a little addition to memory requirements also. Although it would still be negligible considering how large the SAPMV45A program is with all its tables and variables.
As for pros, I like the idea of using implicit enhancements in MV45AF* user exits as it would definitely standardized the way coding will be done and of course multiple projects can make their changes and if one project gets delayed they can simply inactivate their enhancement implementation when the other goes live.
Though this will still not preclude coordination between competing teams, coordination that is required not just for resolving coding conflicts but also coordination during parallel testing in the QA environment.
Moreover, implicit enhancement options appear only at particular position like after FORM and before ENDFORM etc. This will be bit restrictive. If strictly direct coding in MV45AF* includes is prohibited then we can overcome this as SAP allows multiple enhancement implementations for each enhancement option.
Having said that, I have conveniently managed multiple teams modifying MV45AFZZ and MV45AFZB in one of my previous projects. Idea was to create multiple blank includes and put them in various forms of MV45AFZZ and MV45AFZB and transport them to production. A blank include doesn't impact anything.
The key here is to have all the blank includes transported to production before any project uses them. Later when needed we assign the blank includes separately to each competing project.
If a project gets delayed and won't go live whereas another is tested and ready for go live. The project going live can safely do their transport with only their include containing their changes, whereas the other include remains in dev and test.
If we want to inactivate coding of a particular project we can simply comment out the INCLUDE statement. This is similar to making an enhancement implementation inactive.
2011 Nov 21 4:38 AM
Hi,
Please create a badi definition( not implicit enhancement) with required methods and call it inside the exit.. I have read an article in SDN which demonstrates this.
Here its is [Implementing a badi in an enhancement project|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/d0456c54-0901-0010-f0b3-cd765fb99702?QuickLink=index&overridelayout=true] - Here the badi is implemented in a customer exit and you can also follow this approach for an user exit. Read the part under Historic Problem you will get the answer to your questions.
For execuitng the badi implementation in the order read [Need to control sequence of calls of Business Add In|http://www.google.co.in/url?sa=t&rct=j&q=badi%20sorter&source=web&cd=3&ved=0CDUQFjAC&url=http%3A%2F%2Fwww.sdn.sap.com%2Firj%2Fscn%2Findex%3Frid%3D%2Flibrary%2Fuuid%2Fe0d2f214-b1a5-2a10-f3a0-98c95afcf281%26overridelayout%3Dtrue&ei=G-LJTvDuH8XoOenOiLUL&usg=AFQjCNHyBqBKxEiBsvoxIke3nvsPLHdjhQ&sig2=ggqKb76zqoZ8F03NkbcGwQ&cad=rja]
Kesav
Edited by: Keshav.T on Nov 21, 2011 10:23 AM
2011 Nov 22 2:57 AM
Keshav,
Thanks a lot. The idea of implementing a BAdi would solve the problem to a big extent.
Vikram.M
2011 Nov 22 6:06 AM
Hello Vikram,
2. While point 1 is a clear advantage, the same time one developer might not be aware of what someone else is doing on the same object which might cause issues related to regression.
I'm not sure how implementing the BAdI helps you resolve this problem? Also it adds an overhead of controlling the sequence of BAdI implementations.
IMHO the article referenced by Keshav was published for a release(4.6c) which did not have Enhancement framework. If you're working for Release > 6.0, i think you should use implicit enhancements rather than creating a custom BAdI.
Actually we've created implicit enhancement(s) in the standard FI validation program RGGBR00 for plugging in our user-exits.
Let me know your thoughts!
BR,
Suhas
2011 Nov 22 6:43 AM
Hi suhas,
Nothing related to the question from OP. Just want to point out something on your quote
Actually we've created implicit enhancement(s) in the standard FI validation program RGGBR00 for plugging in our user-exits.
Do we really need to have an implicit enhacement for standard validation program RGGBR000 ? AFAIK, you can copy the standard one to Z program and assign the customized program using transaction code GCX2.
Regards, Vinod
P.S : Applogies for taking this thread to a different direction...
Edited by: Vinod Kumar on Nov 22, 2011 12:14 PM
2011 Nov 22 7:34 AM
Hello Vinod,
AFAIK, you can copy the standard one to Z program and assign the customized program using transaction code GCX2.
Sorry for not mentioning the reason explicitly
If i remember correctly there is a comment in the program where it is mentioned to copy it to implement the user-exits. Even in my previous project(ECC5.0), we followed the same approach
Then came ECC6.0 & along with it brought fancy "implict" enhancement points. So why bother copy the program?
You get one less custom object to worry about, actually. Let me know your thoughts!
BR,
Suhas
PS: Actually it was me who hijacked the thread. But if it is for a constructive discussion, i don't mind
2011 Nov 22 7:46 AM
Hi Suhas,
You get one less custom object to worry about, actually
Completely agree with you.
In my earlier project, the instruction from project lead was "Touch SAP standard objects/implicit enhacement only if there is no alternative". GCX2 was the alternative for me add new user exists for FI validation.
Regards, Vinod
2021 Dec 25 3:35 PM
One disadvantage I know is in that case always use retrieve version mechanism to get back previous state.
If ever any of non trained abaper used a copy paste operation with any intention to retrieve some old code,your enhancement implementations will be lost as enhancement implementations will not come in clipboard.
Further it bring more work to you during upgrades if SENH is needed to adjust those.
I have seen this practice been adopted in some earlier clients I worked with but frankly speaking I am strongly against total oops and the way sap is organizing it.
Sap is not making life of people easier but more and more miserable with every day.
2021 Dec 27 8:31 AM
adiforsap24 I find that programming in OOPS in SAP makes my life much happier. Been doing it since 2000.
Perhaps you could consider a different career if SAP makes you unhappy.
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |