官术网_书友最值得收藏!

Setting up internet connectivity

If you are working in an enterprise and have to access internet through a proxy, this can be a pain based on what your enterprise policies limits you to do.

For our development purposes, we need internet connectivity for the following:

  • Downloading dependency libraries such as Log4j and Spring that are configured as part of the Maven repository. This is a one-time activity, as the libraries become part of the local Maven repository once downloaded. If your organization has a repository, you need to configure that.
  • Eclipse plugins from the marketplace as we evolve our sample application.
  • Your program calls a service or APIs that are in the public cloud.

For writing our first service, only the first point is important. Please get your proxy details and configure them in the Maven settings from the main menu, WindowsPreferences, as follows:

Make changes to the settings.xml file in User Settings and add a proxy section:

<proxies> 
<proxy>
<id>myproxy</id>
<active>true</active> <protocol>http</protocol> <host>proxy.yourorg.com</host> <port>8080</port> <username>mahajan</username> <password>****</password> <nonProxyHosts>localhost,127.0.0.1</nonProxyHosts> </proxy> <proxy> <id>myproxy1</id> <active>true</active> <protocol>https</protocol> <host> proxy.yourorg.com</host> <port>8080</port> <username>mahajan</username> <password>****</password> <nonProxyHosts>localhost,127.0.0.1</nonProxyHosts> </proxy>

Save the file and restart Eclipse. We will know whether it worked when we create a project.

主站蜘蛛池模板: 昌都县| 彰化县| 安西县| 玉田县| 鄂托克旗| 金华市| 雷州市| 黑河市| 杭锦后旗| 汝阳县| 盱眙县| 岢岚县| 大姚县| 和政县| 临洮县| 嘉黎县| 刚察县| 开化县| 海原县| 广灵县| 南丰县| 二连浩特市| 阿巴嘎旗| 安徽省| 延津县| 江孜县| 昌平区| 吴川市| 惠州市| 广东省| 绥德县| 泗水县| 平顺县| 南宫市| 长武县| 汽车| 永兴县| 罗源县| 海阳市| 临城县| 庄河市|