abapGit icon indicating copy to clipboard operation
abapGit copied to clipboard

SAP Notes installation check feature

Open larshp opened this issue 3 years ago • 1 comments

Some stuff requires some SAP notes to be installed to work properly. Suggest gathering a list with the note numbers.

Plus in the future possibly implement a feature to help checking the system automatically.

Current list

Note 3117150, AIFC, ref https://github.com/abapGit/abapGit/pull/5267#issuecomment-1012946565 Note 2859159, XSLT, ref https://github.com/abapGit/abapGit/issues/5262#issuecomment-1012426663

larshp avatar Jan 20 '22 13:01 larshp

#5163 requires SAP Note

  • 3138721 - Remove Feature Toggle for ABAP File Formats
  • 3145107 - Write posix EOF and EOL (for JSON)
  • 3138884 - Update CHKO, CHKC and CHKV to recent ABAP file format and CHKV JSON-based UI
  • 3150975 - Add more parameter options for ATC checks in ATC Variants

albertmink avatar Jan 21 '22 08:01 albertmink

#5163 requires SAP Note

  • 3138721 - Remove Feature Toggle for ABAP File Formats
  • 3145107 - Write posix EOF and EOL (for JSON)
  • 3138884 - Update CHKO, CHKC and CHKV to recent ABAP file format and CHKV JSON-based UI
  • 3150975 - Add more parameter options for ATC checks in ATC Variants

Requires SAP Note: 3279295 [ATC / abapGit] Dump while importing Import of ATC Objects

burcuka avatar Dec 12 '22 16:12 burcuka

Unfortunately, detecting if an SAP Note is missing and needs to be implemented is a rather complex task. The problem is that SAP Notes are valid only for specific release and SP ranges which can also change at any time if the note contains new correction instructions.

During my time at SAP, I implemented this (see Z_SAP_BW_NOTE_ANALYZER attachment to SAP Note 2383530). It requires that the most recent version of the SAP Note is downloaded and available in the system (SNOTE) or a separate way to get the note metadata. The Note Analyzer uses both methods (metadata is provided as an XML file and cross-referenced with SNOTE implementation status). Overall, about 10k lines of code.

Instead of an automated check for SAP Notes, I suggest implementing only general checks in the constructor of the serializer class. For example, does a class or interface exist. But instead of a generic error like below, point to a (collective) SAP Note that contains instructions on how to gain support for the object type:

https://github.com/abapGit/abapGit/blob/526162ed6ef03d060bdc477a2e72ca958bc618f8/src/objects/zcl_abapgit_object_aifc.clas.abap#L167

Example: AIFC is not supported. See SAP Note xyz for details

Alternatively, enhance the docs to include instructions or a list of SAP Notes per object type.

mbtools avatar Dec 14 '22 19:12 mbtools

I was thinking of something like

download_note( 123 ).
if status( 123 ) = can_be_implemented. " ?
  give error
endif.

larshp avatar Dec 14 '22 19:12 larshp

  • won't work with offline systems (it's a small number that don't even have OSS connection to SAP but they do exist)
  • won't work if note is required for code correctness but outside of validity (system = SP 1, note validity = SP 3-10)
  • might not take all note dependencies into consideration
  • won't be fast since you have to check if notes are out-of-date and potentially download again

mbtools avatar Dec 14 '22 21:12 mbtools

also consider the cases where it will work, it will help users IMHO

we can keep the list of note numbers in the code and display it to users, instead of users having to manually check for issues online

larshp avatar Jan 17 '23 14:01 larshp

Another case:

https://github.com/abapGit/abapGit/issues/6010#issuecomment-1408539292

No doubt, a check would be very helpful. I'm just not convinced it needs to or should happen during runtime. Maybe a separate prg like for the ssl test.

mbtools avatar Jan 30 '23 19:01 mbtools

yea, trying as a separate program is a good start

larshp avatar Jan 31 '23 07:01 larshp

There is a new Note related to object type CHKV 3353061

schneidermic0 avatar Jul 07 '23 15:07 schneidermic0

During my time at SAP, I implemented this (see Z_SAP_BW_NOTE_ANALYZER attachment to SAP Note 2383530). It requires that the most recent version of the SAP Note is downloaded and available in the system (SNOTE) or a separate way to get the note metadata. The Note Analyzer uses both methods (metadata is provided as an XML file and cross-referenced with SNOTE implementation status). Overall, about 10k lines of code.

Transaktion SNOTE supports a SAP Note analyzer. See https://launchpad.support.sap.com/#/notes/3200109. This functionality is based on an XML file which contains relevant SAP note numbers.

You can see two examples of such XML files attached to SAP Note https://launchpad.support.sap.com/#/notes/2436688

schneidermic0 avatar Jul 07 '23 15:07 schneidermic0

https://docs.abapgit.org/user-guide/reference/note-analyzer.html

Closed by https://github.com/abapGit/docs.abapgit.org/pull/176

mbtools avatar Dec 01 '23 17:12 mbtools