CLICLItypeA command you run, rather than a dependency you import.See every one →What this type is →independently maintainedindependently maintainedoriginPublished by one person or a small company outside SAP. Says nothing about quality; the readings say that.See every one →

striezl/VariScan

An ABAP program, Z_VARI_SCAN, that searches program variants for a value or pattern, doing for variants what RS_ABAP_SOURCE_SCAN does for source code, with each variant checked in a parallel task.

Z_VARI_SCAN searches ABAP program variants for a value or pattern, described by the maintainer as doing for variants what the standard report RS_ABAP_SOURCE_SCAN does for source code, useful during a refactor to find every variant a change touches. Each variant is generated at runtime and checked in its own parallel task, and system programs are excluded, along with, on S/4HANA, programs blacklisted in table ABLM_BLACKLIST or SAP Note 2249880. The maintainer warns that setting the task count too high can slow the whole system, and recommends starting conservatively.

Facts

Last pushLicenceMIT

Where it sits

Lives in
Provides
Searching code in a systemABAPSearching code in a systemcapabilityFinding where a string, pattern or name occurs across source code and development objects held in a system. Raising findings against rules is [static analysis](capability:abap-static-analysis); reading an individual change is [code review](capability:abap-code-review).
Requires
abapGitabapGitartifactClones and installs the repository into the system; the Prerequisites section names it as the step to take first.

Who is behind it

Bernhard HaberstetterBernhard HaberstetterPersonMaintains this
In the atlas: maintains 1, contributes to 2
@striezl
maintainer

Before choosing this

Signals

ActivityQuietNo published releases; repository quiet for 62 months

It publishes no releases, and its repository has been quiet for at least 24 full months. This may be normal for stable software; check whether its current state still fits your use.

What it declares

Every artifact

Type
CLI
Origin
Independently maintained

As a CLI

Distributed through
abapGit

Connections2

Where striezl/VariScan runsBy its type: a CLI is run from a terminalcallsdocumentedrequiresYour terminal, actorYour terminalstriezl/VariScan, modulestriezl/VariScanabapGit, moduleabapGit
SAPnot SAP's, or the project's ownstated in the documentdocumented only

README

quoted from striezl/VariScan under MIT, read
striezl/VariScan/README.mdOn GitHub

VariScan is a fast search tool for SAP program variants

Z_VARI_SCAN is supposed to be something like RS_ABAP_SOURCE_SCAN for program variants - so for example if you are doing some kind of refactoring and therefore want to find a certain value or pattern in all variants it could be your weapon of choice. Never again check variants manually!

Manual, Screenshots

See Wiki.

Prerequisits

Install abapgit if you have not done so yet.

Installation

Clone the VariScan repo using abapgit. Create a package first, we recommend Z_VARI.

Authorization

Variant 1

Per default, the program Z_VARI_SCAN checks for the following authorization at the INITIALIZATION event:

  • Object = ZVARI
  • Field = ZVARI
  • Field Value = X

Note that SAP_ALL might need regenaration (transaction su21) due to the new authority object ZVARI that comes with installing VariScan.

Variant 2

Alternatively you can choose to use the standard object S_PROGRAM (P_ACTION = "VARIANT", P_GROUP = <TRDIR-SECU>) for authority check. Therfore build an implementation in enhancement spot (se18) for BAdI Z_VARI_AUTH that is copied from the example implementation Z_VARI_AUTH_S_PROGRAM. The check for the custom object ZVARI will then be discarded. If you use S_PROGRAM each program (respectivly the authorization group of each program) will be checked seperately. If then at least one authority check fails, the message "Due to missing authorization not all programs could be checked" will be displayed.

In general

The Program Z_VARI_SCAN uses RFC function module Z_VARI_SCAN for parallel processing. Note that this FM does not have an implicit authority check, authorization S_RFC should be set accordingly.

Constraints

System programs (trdir-rstat = S) are out of scope.

S/4: Blacklisted programs (see Table ABLM_BLACKLIST or SAP Note 2249880) will not be checked, even if execution is temporarily allowed.

Troubleshooting

Dumps occur

To get the variant content, each examined program must be generated at runtime which can cause various errors. Try to exclude programs / packages that cause dumps via selection in Z_VARI_SCAN. Try to find those programs by examining dumps in transaction st22. At runtime each variant is checked in an exklusive tasks, so if one or more tasks fail (with runtime error) the overall reporting will still complete.

Slow scan

Normally the program should work quite fast of course depending on your database, available tasks, the number of scanned packages and so on. Under good circumstances even a scan of the entire program repository can be possible within minutes or less. However single programs can cause a long runtime and slow down the analysis. For the moment those are quite hard to find, it might help to use the default exclusions with which Z_VARI_SCAN is delivered. Furthermore, if you can narrow the scope of your search to certain packages or programs. Another reason for a slow scan might be a too high or too low number of max tasks, both leading to inefficient processing, see Warning.

Warning

Beware of setting parameter "Max. number of tasks" too high, it might slow down the entire system! Always make sure not to consume most of your available dialog process (see transaction sm50), maybe a rule of thumb for dev system might be half of them max., of course heavily depending on your individual setup. Set the parameter to "1" if you want the most conservative setup (at the price of a longer runtime).

Contribution

Your contribution is very welcome!

FAQ

For questions/comments/bugs/feature requests/wishes please create an issue.

MIT, read
Searching code in a system
  1. sapguiThirty classic transactions rebuilt as abap2UI5 appsfrom ABAP
  2. alwinvandeput/zscv_search_cds_viewsIn-system search tool for CDS viewsfrom ABAP
  3. abapwuluRefreshes the where-used list for objects in one packagefrom ABAP
  4. boy0korea/ZWD_CODE_SCANNERCode scanner for Web Dynpro ABAPfrom ABAP
  5. bryanmcain/zcode_scannerEnhancement extending ECC's code scanner to more object typesfrom ABAP
  6. coreline/ZDDIC_FINDERFinder for ABAP Dictionary objectsfrom ABAP
  7. abap-code-search-toolsIn-system ABAP source search by string or regular expressionfrom ABAP
  8. ABAP Code SearchEclipse plugin searching ABAP sources from the search dialogfrom ABAP
  9. ABAP Search and Analysis ToolsEclipse plugin for ABAP object search and CDS view analysisfrom ABAP
  10. abap-search-toolsADT backend for the ABAP Search and Analysis Tools pluginfrom ABAP
  11. ABAP remote filesystemVS Code extension editing ABAP systems over ADT as a filesystemfrom ABAP
  12. Source Code FinderReport searching ABAP source in methods, enhancements, DTPs and morefrom ABAP
  13. sap-russia/ZRS_ABAP_SOURCE_SCANA report that searches code inside modifications and enhancements without depending on SAP HANA.from ABAP

Details

Sources3
Added by handdiscovered herechecked
github.com/striezl/VariScantree, pushes, contributors, CIchecked
README.mdquoted, and what the entry declareschecked

Sources are graph entities: the same page may back several entries, and an unreachable source flags every row that rests on it.

Compatibility and provenance
discovered viaAdded by hand
first seen in the atlas
ecosystem and domainabap, developer-experience
abaplint
issues under its own abaplint configuration207
lines609
statements381
objects25
files18
analysed, main
abaplint version2.120.84
History in the atlas1
  1. First seen.
For your agent
Ref
artifact:striezl-variscan
JSON
/artifacts/striezl-variscan.json
MCP
Connecting an agent