16 September 2013

Java Web Services: Up and Running by Scott Berkun; O'Reilly Media


Java Web Services: Up and Running by Scott Berkun; O'Reilly Media
http://shop.oreilly.com/product/0636920029571.do

2nd edition: RESTful context and more:
 
It has been recently released The second edition of Java Web Services: Up & Running, this means full new content (almost a trend in O'reilly Java titles), and not only an update of bugs and reader's comments.

This new edition focuses in the (not new, but fashion) RESTful services. Today, it is clear the current trend is to use less restrictive REST services and lightweight JSON. Keeping most chapters under this context, it get along with examples and info about WADL, Security JSON, etc.

Also, mentions different implementation Jersey, CXF, among others, so it reach a wider crowd for any doubts and details on these implementations. While in the client side has references to JAXB, Amazon, XStream, Axis.

SOAP Handler, using JAX-WS handlers, shows examples in how an incoming/outcoming SOAP message can be handled to implement business logic in the middle of the conversation; very useful for some security constraint inside of a typical workflow.

Last, but not Least, Security, another important tier on WS, it is covered with simple JAAS and SSL (or better said HTTPS), WS-Security.

Interesting is to mention several (perhaps most important) Java Application Servers, because most examples are using Tomcat, however take time and space to describe tips on
Source code, which is available to be downloaded from Git directly.

At the end, similar to the first edition, a not-so deep introduction the current de facto spec for webservices, giving a compass a quick answer about it.

Small and easy to read, not a cookbook, although several examples could be considered recipes.

10 September 2013

WebLogic Server Default Encoding

A good question was asked at JavaRanch, regarding to parameter webapp.encoding.default

In the specification of JSP/Servelts set default to ISO-8859-1

There is a good summary in Japanese WebLogic Server documenttion, that for their context is a concurrent doubt.

http://otndnld.oracle.co.jp/document/products/wls/docs90/en/relnotes_ja.html#1110412

Component Name Default Encoding
Servlet ISO-8859-1
JSP ISO-8859-1
XML format JSP Document UTF-8
Tag File ISO-8859-1
XML format Tag File UTF-8

Since ISO-8859-1 encoding is extensively used as default encoding except for XML components, encoding setting is essential for the use of multibyte characters. The details of settings for each Web component are shown below. The meaning of each column in the table is as follows:
  • Setting Location: Location where encoding is set.
  • Effective Area: Area where the setting is effective.
  • Setting Value: Character string used for setting.
  • J2EE Compliant: YES for J2EE compliant, NO for WebLogic Server proprietary specification.
  • Priority: The priority with which set value is used (the smaller the value, the higher priority). The lower priority will be overwritten by higher priority. In general, the one with smaller effective area will have higher priority, and vice versa.
  • Setting Example: Examples of encoding setting.

29 August 2013

Oracle WebLogic Server Schema home

A not very known, but useful page:

A list of WLS schemas, from 10.3.1 till 12.1.3 :

http://www.oracle.com/webfolder/technetwork/weblogic/index.html

http://xmlns.oracle.com/weblogic/weblogic-ejb-jar
http://xmlns.oracle.com/weblogic/weblogic-web-app

Among others...

Different info can be retrieved from these schema URLs, and check their version progression, i.e.:

weblogic-application.xml

List of schema versions for http://xmlns.oracle.com/weblogic/weblogic-application

1.0 : Released with WLS v10.3.1.0
1.1 : Released with WLS v10.3.3.0
1.2 : Released with WLS v10.3.4.0
1.3 : Released with WLS v10.3.6.0
1.4 : Released with WLS v12.1.1.0
1.5 : Released with WLS v12.1.2.0
1.6 : Released with WLS v12.1.3.0


30 July 2013

Oracle WebLogic Server 12c Advanced Administration Cookbook

The last book of WLS 12.1.1, Packt brings us a 285 pages product, a comfortable size, not very big neither a flyer, so, easy to read and search as a reference, kind of cookbook with high availability and clustering point of view.


First pages are very detailed in how to install and run a vanilla WLS domain (including Node Manager, Machines, etc.). Including WLST and Admin Console. Some aesthetic tips, but not sure if this ha Administrator flavor.

Later comes deployments in different approaches (tools actually:) ). Next Chapter about High Availability and Clustering fine grained; address listen, Broadcasting, Unicast, Multicast, etc.


Then JDBC, again with HA/Clustering thru WLST/Admin Console... here it is more verbose about algorithms, Parameters of Data Sources, Gridlink, Multidatasource, a must for any Admin.


JMS, focused to HA again, using all typical resources of it: Bridges, Persistent Stores, etc.


A good, perhaps more useful , about monitoring, tips & tricks on this which is not very documented, and this time is very admin focused. Then recipes for WLS 12.1.1 troubleshooting for OutOfMemory (a very common scenario).


Finishing with security & SSL, concurrent questions and answer on this topic (X.509 certificates, keystore, etc.)

I can say that has some known areas, but improves in another that many times are left for the user, and it doesn't appear in the official documentation.  




10 May 2013

Eclipse Juno GUI (Theme)

1.
To change to older theme:

General --> Appearance --> Theme: Classic.

2.
Also, I found in this blog that it can be changed at lower level:


plugins\org.eclipse.platform_4.2.0.v201206081400\css

to something like,
plugins\org.eclipse.platform_4.2.0.v201206081400\css.old





Eclipse & Proxy Config

Necessary config when being behind a Firewall/Proxy:

use MANUAL Active-provider under General->Network Connections.

Clean the SOCKS option and only set HTTP & HTTPS with proxy values.


Probably related to bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=281472

10 April 2013

Dudeney's Star Puzzle

Tomado textual de mathpuzzle.com Alex Ravsky encontro una solucion mejor para un puzzle de Dudeney.

Similar como el caso de Klondike de Sam Loyd en los 70s.


The task of the star puzzle, ((X36 = AM329) according to the list [Knu] by Donald E.
Knuth) published a century ago in The Strand Magazine [Dud2], is to construct a path,
consisting of 14 straight strokes, on the following field of stars from one light star to the
other such that all the stars lay on the path.


Paper original puede ser obtenido en http://arxiv.org/abs/1205.0747


Four on a Match

Kadon has many fun puzzles and some contests.

by solving one of them, I received Four on a Match two years ago:


I think it was good time to publish it :P

Combinatorial Explosion

I think the discussion should have more emphasis in the best practice of using this kind of tool; Just like it is mentioned and used in the MatrixGame & TheLuckyString problems, we need to generate certain rules/filters to optimize the search. To look for all n! possibilities probably never will be a feasible solution. This is also called Combinatorial Explosion which verbatim refers to a growth almost impossible to sustain for the time of this type of TC problems.

So more important than the implementation ( which is assumed know -next_permutation()- that this is called Algorithm L in Knuth's TAOCP 4: 7.2.1.2) it is the good use some criteria for pruning combinations (permutations) and at the end we obtain a reasonable running time.

Many problems use this kind of booby-trap to let the programmer to try to solve with a plenty quick solution which runs over all permutations (or combinations) that finish with a timeout or an unnecessary overhead as resources used (such us memory).

Blog Archive

Disclaimer

The views expressed on this blog are my own and do not necessarily reflect the views of Oracle.