1. Home
  2. Docs
  3. Shared profile
  4. Creation guidelines

Creation guidelines

Follow the below steps to bootstrap any new shared profile :

  1. Create the shared profile
  2. Adapt your build
  3. Test it with the Jeyzer Analyzer
  4. Deploy it to a repository

All steps are detailed hereafter.


Shared profiles can be versioned.
See the Versioning section for more details.

Shared profile template

In every Jeyzer installation, a shared template profile is made available in the profiles/external/shared/template directory.
It contains two files : the template_patterns.xml and the template_rules.xml.
Feel free to re-use it.

Shared profile creation

  1. Copy the shared template directory under any local shared profile root directory
  2. Rename the template directory to the desired profile name
  3. In the new profile directory, rename all the files by replacing the template prefix with the desired profile name.
    For the automatic profile loading, use the artefactId of your project as profile name.
  4. Edit the <new shared profile>_patterns.xml :
    1. Set the name with the desired profile name.
    2. Set the version to blank or adapt it to your versioning needs.
    3. Add any dummy analysis pattern for testing (if you want to achieve the annotations phase at later stage).
  5. Edit the <new shared profile>_rules.xml :
    1. Set the group_name with the desired group name.
    2. Add any stickers if necessary
    3. Add any important rule : follow these guidelines.
  6. If you need to add static conditions on the previous rules, edit the <new shared profile>_stickers.xml.
    You should mainly use process jar version stickers or process module version stickers in this context.

Adapt your build

Adapt your build to get the analysis patterns – issued from the annotations – injected automatically in the shared profile you created.

As prerequisite, you must use the Jeyzer annotations in your code.
See the Annotations section for more details.

For a Maven based build, you must use the Maven Jeyzer profile updater plugin : follow the setup instructions in the related section.

For a Gradle based build, you must use the Gradle Jeyzer profile updater plugin : follow the setup instructions in the related section.

For the automatic profile loading, you can add the Jeyzer-Repository attribute as part of the Manifest of the built jar file.


In the master profile that references this shared profile, add a profile dependency in the analysis file (<master profile>_analysis.xml) :

  <pattern_set file="${JEYZER_BASE_SHARED_PROFILES_DIR}/<new shared profile>/analysis/<new shared profile>_patterns.xml">

Use any path of your choice if it’s temporary.
The above example assumes we put it in the local repository.

Start the Jeyzer Web Analyzer and perform any analysis.
To guarantee the matching, perform an endless wait or sleep call in a method of your library and add a fake operation annotation on that method : you must see it in the JZR report, for example in the Histogram sheets.


This step is required if your shared profile is used elsewhere in your company.
If not the case, you could stay with the local repository which could be a location shared with other developers.

Once the shared profile is ready, adapt your build to push it on the profile repository.
As the repository storage is yours (could be Github, Nexus, any web server..), use the right deployment method.

Shared profiles can be accessed within the repository either through dependencies declared in the master profile or through the automatic profile loading.

Update the analysis profile to add this new dependency (and remove the previous temporary path) :

  <set id="my_company-shared-deps" profiles="other_profile, my_new_shared_profile"/>

Automatic profile loading
Update the analysis profile to declare the automatic profile loading (and remove the previous temporary path) :

  <dynamic_pattern_sets declared_repository_only="true"/>

Important : this must also be reflected in the monitoring rules and stickers if you decide to do so. See the automatic profile loading for more details.

Note that you will have to do it only once as automatic loading will also apply to any new shared profile required by your application.


A good practice is to store your shared profile in a SCM repository under a shared profile root directory.

If your shared profile concerns an open source project, feel free to submit it to the Jeyzer community : it would be a good candidate for the Jeyzer base repository.
Feel free also to drop a message in the community forum.