Samples JDK
Packages
Here are the packages with brief descriptions (if available):
[detail level 123456]
 ▼Ncom
 ▼Nfreemindcafe
 ▼Napache
 ▼NcommonsCAS rest invoker client
 ▼NbeanutilsBeanUtils and PropertyUtils samples
 Nsample1PropertyUtils Samples. To set and read from indexed properties
 Nsample2BeanUtils Samples. To set and read from indexed properties
 ▼NcxfUse soapUI to send the soap requests and jaxrs requests involving the SSL
 ▼Njaxrs
 Nsample2We need annotations on data object, otherwise the response will not be written
 Nsample3Data object should have a public constructor
 Nsample4Setting List<V> in response
 Nsample5Wrapping List<V> in one container object
 Nsample6Returning xml as application/xml and application/json
 Nsample7JaxRs servie running behind BasicAuth interceptor. ExceptionMappers example
 Nsample8Returning xml as application/xml and application/json
 Nsample9 Incomplete ??
 ▼Nwsdl
 Nsample1Generates java code from xsd and wsdl. Verifies basic, wsse token and 2 way auth interceptors. Uses soap out and fault interceptors. Uses SOAP UI as a client
 Nsample2 Incomplete ??
 Nsample3 Incomplete ??
 ▼Nlog4j
 Nsample1Additivity can turn off the appender chaining
 Nsample2Log4j uses dot notation to build logger hierarchy
 ▼Nvelocity
 Nsample1Expression that were used in settlement grid area condition check
 ▼Napt
 Nsample1Annotation Processing Tool examples
 ▼NconcurrencyConcurrency Samples
 Nsample1ThreadpoolExecutor having Runnable
 Nsample2ThreadpoolExecutor having Callable
 Nsample3FutureTask samples
 Nsample4Throttling sender example
 Nsample5Rendezvous example
 Nsample6Barrier example
 Nsample7ConcurrentHashMap example
 Nsample8Calling a code after some delay using ScheduledExecutorService
 ▼Nformat
 Nsample1System.out.printf samples
 ▼NjdbcJDBC and database related concepts
 Nsample1Global temporary table with on commit preserve rows; Incomplete ??
 Nsample2Global temporary table with on commit delete rows; Incomplete ??
 Nsample3Global temporary table with on commit delete rows; 1) create table using basicDataSource and then resuse 2) Create temporary table using jdbcTemple and then reuse 3) Create table using jdbcTemplate via sql script file and then reuse
 Nsample4
 ▼Njmx
 Nsample1This sample does not use JMXConnectorServer and the MBean can be accessed from jconsole
 Nsample2This sample uses JMXConnectorServer and client uses JMXConnector to access MBean
 Nsample3Accessing ActiveMQ BrokerViewMBean
 ▼Nquartz
 Nsample1Cron expression is used to define the constraints
 ▼Nrmi
 Nsample1Rmic and rmiregistry is used. This one does not uses SecurityManager
 Nsample2Rmic and rmiregistry is used. This one uses SecurityManager. But SecurityManager is not a must
 Nsample3Registry can be started from java code.rmic is not needed as well
 ▼NsecuritySamples for protection domain, SecurityManager, AccessController, private key, certificate, jar signing etc
 Nsample1 Incomplete ??
 Nsample2To obfuscate and deobfuscate password using Jetty utility. Decrypt the text
 ▼NserializationXstream and Jettison based serialization Jackson is arguably the standard Java Library for processing JSON
 Nkryo Incomplete ??
 Nsample1Xml and json serialization. Serialization of POJO
 Nsample2Difference between map wrapper and pure map. Jettison is not ideal for JSON stuff
 Nsample3This example uses jackson library to generate JSON. Jackson is 100% JSON library
 Nsample4If a map has null value, serialization fails
 Nsample5Default ReflectionProvider skips constructor code or to be more detailed - the object initializer code
 ▼Nsocket
 NsimplePlain socket examples. Incomplete ??
 ▼NsslSSL socket examples
 Nsample1Client and server do not share public certificates, hence client auth fails
 Nsample2Client and server share each others public certificate hence client auth succeeds
 Nsample3Client and server share each others key+public certificate hence client auth succeeds
 Nsample4Server has clients public certificate but it also has additional serverkey1. This keys public certificate is not imported in clients store. Hence client auth fails as server sends the certficate for serverkey1. Since the key selection is based upon the hashcodes of the keys, the keys will not be predictably picked
 Nsample5Server has clients public certificate but it also has additional serverkey1. This keys public certificate is not imported in clients store. We use custom key manager to select serverkey. If there is no custom key manager, key selection is based on some hashing algorithm which will return the keys in random order
 ▼Ntimezone
 Nsample1DST examples.Settlements one, consult with Neha Incomplete ??
 Nsample2Creation of TimeZone objects using Timezone ids
 Nsample3Calendar using TimeZone objects
 Nsample4TimeZone vs ZoneInfo. Incomplete ??
 ▼Nxml
 ▼NxsdXMLBean samples
 Nsample1'po.xsd' is in 'purchase' namsespace. Without elementFormDefault="qualified" all local elements are in default namespace and not in target namespace
 Nsample2'po.xsd' is in 'purchase1' namsespace and elementFormDefault is "qualified"
 Nsample3Xsd:anyType can contain any payload. Schema validation check samples
 Nsample4Xsd:anyType can contain any payload. Reading the anyType payload using XmlObject Incomplete ??
 ▼Norg
 ▼Napache
 Nhello_world_soap_http