понедельник, 6 апреля 2015 г.

WebSphere Application Server 8.5 Jax-rs annotations support.

WebSphere Application Server 8.5 Jax-rs supports Jackson 1.
The Jackson library is included in the runtime environment of the product. You do not need to bundle any additional libraries.

The following Jackson annotations are supported and can be used to annotation POJOs:
 
org.codehaus.jackson.annotate.JsonAnySetter
org.codehaus.jackson.annotate.JsonAutoDetect
org.codehaus.jackson.annotate.JsonClass
org.codehaus.jackson.annotate.JsonContentClass
org.codehaus.jackson.annotate.JsonCreator
org.codehaus.jackson.annotate.JsonGetter
org.codehaus.jackson.annotate.JsonIgnore
org.codehaus.jackson.annotate.JsonIgnoreProperties
org.codehaus.jackson.annotate.JsonKeyClass
org.codehaus.jackson.annotate.JsonProperty
org.codehaus.jackson.annotate.JsonPropertyOrder
org.codehaus.jackson.annotate.JsonSetter
org.codehaus.jackson.annotate.JsonSubTypes
org.codehaus.jackson.annotate.JsonSubTypes.Type
org.codehaus.jackson.annotate.JsonTypeInfo
org.codehaus.jackson.annotate.JsonTypeName
org.codehaus.jackson.annotate.JsonValue
org.codehaus.jackson.annotate.JsonWriteNullProperties
org.codehaus.jackson.map.annotate.JsonCachable
org.codehaus.jackson.map.annotate.JsonDeserialize
org.codehaus.jackson.map.annotate.JsonSerialize
org.codehaus.jackson.map.annotate.JsonTypeIdResolver
org.codehaus.jackson.map.annotate.JsonTypeResolver
org.codehaus.jackson.map.annotate.JsonView

четверг, 12 марта 2015 г.

Backbone.js. Remove model from collection without a reference to collection.

What if you have a model in a collection and in a model view you need to remove model from the collection. You can call destroy method on a model, but this will trigger the ajax delete method to the server.
Well, you can trigger the destroy event on a model like this: this.model.trigger('destroy',this.model).
And you model will be deleted from the collection and no DELETE method will be sent to the server.

понедельник, 2 марта 2015 г.

Joel Spolsky. And on Diverse and Occasionally Related Matters That Will Prove of Interest to Software Developers, Designers, and Managers, and to Those Who, Whether by Good Fortune or Ill Luck, Work with Them in Some Capacity

The world of IT is not about programming. This is all about making money. To stay profitable companies should understand the clients needs. Who can understand the clients needs better: programmers or program managers? How the development process should be organized? How the company's internal process should be organized? Should managers be on the way of programmers and throw away all the written code and start from the ground?

Some answers to this questions can be found in the book Joel on Software: And on Diverse and Occasionally Related Matters That Will Prove of Interest to Software Developers, Designers, and Managers, and to Those Who, Whether by Good Fortune or Ill Luck, Work with Them in Some Capacity . Although is a bit outdated it is still actual. It is actual because it contains the description of people errors and relations between people in it-business.

Personally, here are some minds I like:
The desire for rewriting  program from scratch is in inverse proportion to the experience of the programmers.

The most important ability of program manager - is to learn how to make programmers do what he needs by convincing them as this was their own idea. 

понедельник, 23 февраля 2015 г.

Last read book: Functional JavaScript Introducing Functional Programming with Underscore.js

During reading the documentation on underscore.js I found out the link to the book Functional javascript. For a long time I had postponed the learning of this theme and now I can fill the gap in my knowledge of functional programming and javascript techniques.

This book has positive and negative reviews, but in my opinion this book is more of a practical approach. Can I recommend to to anyone? In my opinion, yes. Of course, you cannot master the functional programming only by this book. It gives you a lot of information and directions in where to find more information.

What I like about this book is a good bibliography and a reference to useful javascript libraries.

воскресенье, 22 февраля 2015 г.

Unit testing EJB3

One thing I like EJB3 is the use of annotations. So, if you want to unit test your EJB you can use the annotations and reflective programming to mock the dependencies and inject them.

воскресенье, 15 февраля 2015 г.

суббота, 7 февраля 2015 г.

Share files on Linux through one time HTTP server

It is easy to share files files on Linux. You have a lot of options, like scp, ftp. But I've found out a very simple way - create your simple http server.

If you want to expose the directory to the internet you can start the server in your directory like the following:
python -m SimpleHTTPServer

Open up your browser on http://127.0.0.1:8000 and this is it - your directory.

пятница, 30 января 2015 г.

EAR and dependencies

On the new project our team decided to make a switch from spring to ejb3.
We have created the EAR project, web module and ejb module. We have faced with a problem of classpath. Here is a cheat sheet of organizing the EAR project: