<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <p>Hello Fréderic,</p>
    <p>there are two distinct concepts:</p>
    <ol>
      <li>System Configuration object in midPoint repository,</li>
      <li>configuration in config.xml file.</li>
    </ol>
    <p>The first one is the "main" one. Here e.g. deployment information
      (that you'd like to change) resides.</p>
    <p>The second one is used for low-level information (e.g. where to
      find the repository) or for node-specific information (e.g. node
      id). <br>
    </p>
    <p>Java system properties can be used to override information in
      config.xml, not in System Configuration object. That's why <b>-Dmidpoint.system.deploymentInformation.name=DEV</b>
      does not work.</p>
    <p>As far as I know, it is currently not possible to set the
      deployment name from the command line.</p>
    <p>The following approach works in similar situations
      (unfortunately, not in this particular one):</p>
    <p><a moz-do-not-send="true"
href="https://wiki.evolveum.com/display/midPoint/Configuration+and+Use+of+Constants">https://wiki.evolveum.com/display/midPoint/Configuration+and+Use+of+Constants</a></p>
    <p>You can define a constant in your config.xml file. (So its value
      is settable using -D ... switch.) And you can use this constant in
      your mappings or resource configurations. In the system config it
      would be like this (if it worked):</p>
    <p><tt><deploymentInformation></tt><tt><br>
      </tt><tt>        <name></tt><tt><br>
      </tt><tt>            <expression></tt><tt><br>
      </tt><tt>                <const>systemName</const></tt><tt><br>
      </tt><tt>            </expression></tt><tt><br>
      </tt><tt>        </name></tt><tt><br>
      </tt><tt></deploymentInformation></tt></p>
    <p>It's doable, but not there yet. You can always consider <a
        moz-do-not-send="true"
href="https://wiki.evolveum.com/display/midPoint/Subscriptions+and+Sponsoring">https://wiki.evolveum.com/display/midPoint/Subscriptions+and+Sponsoring</a>
      :)</p>
    <p>...as for your question on config.xml schema. Unfortunately,
      nothing like that exist yet. We read the file programatically,
      looking for specific keys. Something is here:</p>
    <ul>
      <li> <a moz-do-not-send="true"
href="https://github.com/Evolveum/midpoint/blob/master/infra/common/src/main/java/com/evolveum/midpoint/common/configuration/api/MidpointConfiguration.java">https://github.com/Evolveum/midpoint/blob/master/infra/common/src/main/java/com/evolveum/midpoint/common/configuration/api/MidpointConfiguration.java</a><br>
      </li>
      <li><a moz-do-not-send="true"
href="https://github.com/Evolveum/midpoint/blob/master/repo/task-quartz-impl/src/main/java/com/evolveum/midpoint/task/quartzimpl/TaskManagerConfiguration.java#L52">https://github.com/Evolveum/midpoint/blob/master/repo/task-quartz-impl/src/main/java/com/evolveum/midpoint/task/quartzimpl/TaskManagerConfiguration.java#L52</a></li>
      <li><a class="moz-txt-link-freetext" href="https://github.com/Evolveum/midpoint/blob/master/repo/repo-sql-impl/src/main/java/com/evolveum/midpoint/repo/sql/SqlRepositoryConfiguration.java#L249">https://github.com/Evolveum/midpoint/blob/master/repo/repo-sql-impl/src/main/java/com/evolveum/midpoint/repo/sql/SqlRepositoryConfiguration.java#L249</a></li>
    </ul>
    <p>but it's not a complete reference.<br>
    </p>
    <p>Best regards,<br>
    </p>
    <pre class="moz-signature" cols="72">Pavol Mederly
Software developer
evolveum.com
</pre>
    <div class="moz-cite-prefix">On 10/12/2019 08:18, Gómez Martínez,
      Elsa wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:VI1P193MB0285916D57C6E433CFC2C0E1A25B0@VI1P193MB0285.EURP193.PROD.OUTLOOK.COM">
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
      <meta name="Generator" content="Microsoft Word 15 (filtered
        medium)">
      <style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman",serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman",serif;}
p.msonormal0, li.msonormal0, div.msonormal0
        {mso-style-name:msonormal;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman",serif;}
span.EstiloCorreo19
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 3.0cm 70.85pt 3.0cm;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
      <div class="WordSection1">
        <p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">Hello!<o:p></o:p></span></p>
        <p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"
            lang="EN-US">Have you tried to change midpoint.sh file?<o:p></o:p></span></p>
        <p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"
            lang="EN-US"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"
            lang="EN-US">I have to change it to modify the MIDPOINT_PORT
            because I tried in all of the files and it only worked in
            midpoint.bat (I’m running in Windows, I suppose it’s the
            same to Linux.)<o:p></o:p></span></p>
        <p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"
            lang="EN-US"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"
            lang="EN-US">Hope it helps.<o:p></o:p></span></p>
        <p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"
            lang="EN-US"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span
style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"
            lang="EN-US">Elsa</span><span
style="font-size:8.0pt;font-family:"Arial",sans-serif;color:#004254"><o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
        <p class="MsoNormal"><b><span
              style="font-size:11.0pt;font-family:"Calibri",sans-serif">De:</span></b><span
style="font-size:11.0pt;font-family:"Calibri",sans-serif">
            midPoint <a class="moz-txt-link-rfc2396E" href="mailto:midpoint-bounces@lists.evolveum.com"><midpoint-bounces@lists.evolveum.com></a>
            <b>En nombre de </b>Frédéric Lohier<br>
            <b>Enviado el:</b> lunes, 9 de diciembre de 2019 18:56<br>
            <b>Para:</b> midPoint General Discussion
            <a class="moz-txt-link-rfc2396E" href="mailto:midpoint@lists.evolveum.com"><midpoint@lists.evolveum.com></a><br>
            <b>Asunto:</b> [midPoint] Overriding systemConfiguration
            attributes in config.xml file or using java system
            properties<o:p></o:p></span></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <div>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif">Hello,<o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif"> <o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif">Following
              my last message, I would like to override
              systemConfiguration attributes using config.xml or java
              system properties as explained here <a
href="https://wiki.evolveum.com/display/midPoint/Overriding+config.xml+parameters"
                moz-do-not-send="true"><span style="color:#4285F4">https://wiki.evolveum.com/display/midPoint/Overriding+config.xml+parameters</span></a><o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif"> <o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif">Looking
              at <a
href="https://github.com/Evolveum/midpoint/blob/master/infra/common/src/main/java/com/evolveum/midpoint/common/configuration/api/MidpointConfiguration.java"
                moz-do-not-send="true"><span style="color:#4285F4">https://github.com/Evolveum/midpoint/blob/master/infra/common/src/main/java/com/evolveum/midpoint/common/configuration/api/MidpointConfiguration.java</span></a><o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif"> <o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif">I
              tried the following in midpoint/bin/setenv.sh<o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif"> <o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif">JAVA_OPTS="$JAVA_OPTS<o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif">-<a
href="http://dmidpoint.system.deploymentinformation.name/"
                moz-do-not-send="true"><span style="color:#4285F4">Dmidpoint.system.deploymentInformation.name</span></a>=DEV”<o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif"> <o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif">But
              it doesn’t work after a restart. Any though of how I could
              make this work?<o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif"> <o:p></o:p></span></p>
          <p><span
              style="font-size:9.5pt;font-family:"Arial",sans-serif">-Frederic<o:p></o:p></span></p>
        </div>
      </div>
      <br>
      <hr>
      <font size="1" face="Arial" color="Gray"><br>
        Este correo electrónico y, en su caso, cualquier fichero anexo
        al mismo, contiene información de carácter confidencial
        exclusivamente dirigida a su destinatario o destinatarios. Si no
        es vd. el destinatario indicado, queda notificado que la
        lectura, utilización, divulgación y/o copia sin autorización
        está prohibida en virtud de la legislación vigente. En el caso
        de haber recibido este correo electrónico por error, se ruega
        notificar inmediatamente esta circunstancia mediante reenvío a
        la dirección electrónica del remitente.<br>
        Evite imprimir este mensaje si no es estrictamente necesario.<br>
        <br>
        This email and any file attached to it (when applicable)
        contain(s) confidential information that is exclusively
        addressed to its recipient(s). If you are not the indicated
        recipient, you are informed that reading, using, disseminating
        and/or copying it without authorisation is forbidden in
        accordance with the legislation in effect. If you have received
        this email by mistake, please immediately notify the sender of
        the situation by resending it to their email address.<br>
        Avoid printing this message if it is not absolutely necessary.<br>
      </font>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <pre class="moz-quote-pre" wrap="">_______________________________________________
midPoint mailing list
<a class="moz-txt-link-abbreviated" href="mailto:midPoint@lists.evolveum.com">midPoint@lists.evolveum.com</a>
<a class="moz-txt-link-freetext" href="http://lists.evolveum.com/mailman/listinfo/midpoint">http://lists.evolveum.com/mailman/listinfo/midpoint</a>
</pre>
    </blockquote>
  </body>
</html>