<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Get client IP address when request in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265994#M45355</link>
    <description>Could you send a screen of your test job using this tJava code please?</description>
    <pubDate>Fri, 15 Feb 2019 01:54:31 GMT</pubDate>
    <dc:creator>Alpha549</dc:creator>
    <dc:date>2019-02-15T01:54:31Z</dc:date>
    <item>
      <title>Get client IP address when request</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265990#M45351</link>
      <description>&lt;P&gt;Hello everyone !&lt;/P&gt;
&lt;P&gt;I would like to be able to do a simple thing : get the client ip address when requests ?&lt;/P&gt;
&lt;P&gt;I searched for it but I didn't find relevant results...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks !&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 06:35:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265990#M45351</guid>
      <dc:creator>Alpha549</dc:creator>
      <dc:date>2024-11-16T06:35:14Z</dc:date>
    </item>
    <item>
      <title>Re: Get client IP address when request</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265991#M45352</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;is this what you are looking for:&lt;/P&gt; 
&lt;P&gt;&lt;A href="https://community.qlik.com/s/feed/0D53p00007vCozLCAS" target="_self"&gt;https://community.talend.com/t5/Design-and-Development/How-to-get-an-IP-from-the-service-caller/td-p/33140&lt;/A&gt;&amp;nbsp; &amp;nbsp;?&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;regards, Vlad&lt;/P&gt;</description>
      <pubDate>Fri, 15 Feb 2019 00:39:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265991#M45352</guid>
      <dc:creator>vapukov</dc:creator>
      <dc:date>2019-02-15T00:39:41Z</dc:date>
    </item>
    <item>
      <title>Re: Get client IP address when request</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265992#M45353</link>
      <description>Hello&lt;BR /&gt;&lt;BR /&gt;I found this page before but when I try this code in a tJava, I have a NullPointerException at the second line (with the comment //The acquire the Message Context)... &lt;span class="lia-unicode-emoji" title=":confused_face:"&gt;😕&lt;/span&gt;</description>
      <pubDate>Fri, 15 Feb 2019 00:44:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265992#M45353</guid>
      <dc:creator>Alpha549</dc:creator>
      <dc:date>2019-02-15T00:44:39Z</dc:date>
    </item>
    <item>
      <title>Re: Get client IP address when request</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265993#M45354</link>
      <description>&lt;P&gt;can't say anything without information&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;from studio:&lt;/P&gt; 
&lt;PRE&gt;Endpoint deployed at: http://127.0.0.1:8090/services/customers
[statistics] connecting to socket on port 3768
[statistics] connected
[WARN ]: org.eclipse.jetty.server.handler.AbstractHandler - No Server set for org.apache.cxf.transport.http_jetty.JettyHTTPServerEngine$1@587d83f6
Client ip - 127.0.0.1&lt;/PRE&gt; 
&lt;P&gt;from runtime:&lt;/P&gt; 
&lt;PRE&gt;2/15/19 2:50 PM | INFO | 248 - Talend ESB :: Job :: Controller | Adding job DemoREST. | 
2/15/19 2:50 PM | INFO | 248 - Talend ESB :: Job :: Controller | Starting job DemoREST | 
Client ip - 0:0:0:0:0:0:0:1&lt;/PRE&gt;</description>
      <pubDate>Fri, 15 Feb 2019 01:51:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265993#M45354</guid>
      <dc:creator>vapukov</dc:creator>
      <dc:date>2019-02-15T01:51:23Z</dc:date>
    </item>
    <item>
      <title>Re: Get client IP address when request</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265994#M45355</link>
      <description>Could you send a screen of your test job using this tJava code please?</description>
      <pubDate>Fri, 15 Feb 2019 01:54:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265994#M45355</guid>
      <dc:creator>Alpha549</dc:creator>
      <dc:date>2019-02-15T01:54:31Z</dc:date>
    </item>
    <item>
      <title>Re: Get client IP address when request</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265995#M45356</link>
      <description>&lt;BLOCKQUOTE&gt;
 &lt;HR /&gt;
 &lt;A href="https://community.qlik.com/s/profile/0053p000007LP0EAAW"&gt;@Alpha549&lt;/A&gt;&amp;nbsp;wrote:
 &lt;BR /&gt;Could you send a screen of your test job using this tJava code please?
 &lt;HR /&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;we are looking for errors in my code or in yours? &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;P.S.&lt;/P&gt;
&lt;P&gt;I just copy past code and edit&amp;nbsp;print message&lt;/P&gt;</description>
      <pubDate>Fri, 15 Feb 2019 01:56:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265995#M45356</guid>
      <dc:creator>vapukov</dc:creator>
      <dc:date>2019-02-15T01:56:59Z</dc:date>
    </item>
    <item>
      <title>Re: Get client IP address when request</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265996#M45357</link>
      <description>&lt;P&gt;Stupid mistake... I put the code in a tJava instead of a tJavaRow. It was logical...&lt;/P&gt; 
&lt;P&gt;The problem is solved. I put here a complete and simple example of the solution for those who also want to get the IP of the service caller &lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009MA9p.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/138034i5F552429DA646D6F/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009MA9p.png" alt="0683p000009MA9p.png" /&gt;&lt;/span&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;STRONG&gt;Thank you vapukov !&lt;/STRONG&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;The code of the tJavaRow :&lt;/P&gt; 
&lt;PRE&gt;//You need to retrieve the restRequest Map from the globalMap
java.util.Map request = (java.util.Map)globalMap.get("restRequest");

//The acquire the MessageContext from that Map
org.apache.cxf.jaxrs.ext.MessageContext messageContext = (org.apache.cxf.jaxrs.ext.MessageContext)request.get("MESSAGE_CONTEXT");

//The acquire the the HttpServletRequest object and call the getRemoteAddr method from that.
//Display the IP Address
System.out.println(messageContext.getHttpServletRequest().getRemoteAddr());

//Save the IP in the schema
output_row.ipadr = messageContext.getHttpServletRequest().getRemoteAddr().toString();&lt;/PRE&gt; 
&lt;P&gt;Pictures :&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="The whole job" style="width: 513px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M38G.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/153526iAA7035DCA2C60E02/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M38G.png" alt="0683p000009M38G.png" /&gt;&lt;/span&gt;&lt;SPAN class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;The whole job&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="tRestRequest" style="width: 738px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M2wk.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/139344iA190060F5C296258/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M2wk.png" alt="0683p000009M2wk.png" /&gt;&lt;/span&gt;&lt;SPAN class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;tRestRequest&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="tRestRequest schema" style="width: 524px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M38L.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/137518i567724C2D2E6BD63/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M38L.png" alt="0683p000009M38L.png" /&gt;&lt;/span&gt;&lt;SPAN class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;tRestRequest schema&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="tXMLMap" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M38Q.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/133165i5E97384827141CB2/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M38Q.png" alt="0683p000009M38Q.png" /&gt;&lt;/span&gt;&lt;SPAN class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;tXMLMap&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="5.PNG" style="width: 747px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M38V.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/147805i64E3F948D7130304/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M38V.png" alt="0683p000009M38V.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Console of the studio, the ip address is displayed" style="width: 407px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M2zh.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/147012i0D579274BF7035CF/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M2zh.png" alt="0683p000009M2zh.png" /&gt;&lt;/span&gt;&lt;SPAN class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Console of the studio, the ip address is displayed&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="In the browser :)" style="width: 769px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M38a.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/148004i0977CFEECC0CE5FB/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M38a.png" alt="0683p000009M38a.png" /&gt;&lt;/span&gt;&lt;SPAN class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;In the browser &lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009MACn.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/154443iC5B8CACEF3D12C6A/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009MACn.png" alt="0683p000009MACn.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 15 Feb 2019 02:40:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265996#M45357</guid>
      <dc:creator>Alpha549</dc:creator>
      <dc:date>2019-02-15T02:40:10Z</dc:date>
    </item>
    <item>
      <title>Re: Get client IP address when request</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265997#M45358</link>
      <description>&lt;P&gt;great!&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;welcome onboard! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 15 Feb 2019 02:48:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265997#M45358</guid>
      <dc:creator>vapukov</dc:creator>
      <dc:date>2019-02-15T02:48:58Z</dc:date>
    </item>
    <item>
      <title>Re: Get client IP address when request</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265998#M45359</link>
      <description>&lt;P&gt;Hi, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can anyone help to get ip address for a soap service.&lt;/P&gt;&lt;P&gt;The above one is for rest.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 22 Apr 2021 09:48:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Get-client-IP-address-when-request/m-p/2265998#M45359</guid>
      <dc:creator>Lakshmi_M</dc:creator>
      <dc:date>2021-04-22T09:48:32Z</dc:date>
    </item>
  </channel>
</rss>

