Abuse Melding

Je hebt een klacht over de onderstaande posting:

08-09-2016, 00:39 door Anoniem

Hard coding van een IP is een slecht idee, waarom? O.a. https://sbforge.org/sonar/rules/show/squid:S1313?layout=false IP addresses should not be hardcoded squid : S1313 Hardcoding an IP address into source code is a bad idea for several reasons: a recompile is required if the address changes it forces the same address to be used in every environment (dev, sys, qa, prod) it places the responsibility of setting the value to use in production on the shoulders of the developer Noncompliant Code Example String ip = "127.0.0.1"; Socket socket = new Socket(ip, 6667); Compliant Solution String ip = System.getProperty("myapplication.ip"); Socket socket = new Socket(ip, 6667);

Beschrijf je klacht (Optioneel):

captcha