Saturday, August 31, 2013

#define QCON_SP_2013 "SUCESSO!!!!"

Hi Internet!

The QCon in SP ended today =(  but the good news the event was a hit! It was very awesome!!! All the lectures and the presenters where very cool! I recommend you to take a look on the @QConSP (Twitter) and the in the slideshare for the slides to have a taste of how good it was =D I loved the agile presentations, they are very close to what I'm going to talk in AgileVale =D (and the others lecture I loved too =D@qmx rocks! )

Well, this is my device today =D Soon I will paste some open source project I created =D

Bye!

Wednesday, August 28, 2013

QCon SP 2013 , the Storm is arriving!

Hi internet!

Just showing my new presentation tomorrow (for early adopter ;) ) , just need to click on this link .

Bye! See you again!
Luan

Monday, August 26, 2013

Time for QCon in Brazil =D


Hi Internet!

29, 30 and 31st  is the day. WHAT!? You Forgot? The QCon in Brazil will be in this week =D Here the link to the web site of QConSP2013. QCon is an awesome event! Only great lectures of great people are there. I would recommend you to visit the InfoQ (here the link for portuguese version), it is in this site that you can find the QCon videos of lectures and the interviews as well. Also in the  InfoQ you can find others great lectures from other events and articles =D It is one of (if it isn't the best ) sources of great knowledge of many technologies.

Ow, I will have a small lecture in the 29th =) I will talk about Storm =DD The tittle is "Criando aplicações mais rápidas e distribuídas com Storm"  and the description about is the following:
O framework Storm pode ser traduzido como "Aplicações paralelas e
distribuídas de baixa latência de forma fácil". Nessa palestra será
dada uma rápida introdução a conceitos de Big Data que impulsionaram a
criação do Storm e a definição de sua arquitetura, além de exemplos
práticos da utilização do framework.
I will share the link here and then give good posts about it, I promise! =)

Bye!

Monday, June 24, 2013

JVM - Problems and Diagnosis, Part One


Hi folks,

In this post I want to give a quick guide over the JVM internals. I will describe about memory internals (the naming is following HotSpot, Oracle's JVM, and JVM specification, so the concepts can be applied in many different JVM vendors ). I will also talk some *unix tools that can help to solve a problem. I don't have intent for a deep tutorial and explaining how to tune a JVM, the objective is to give an overview that may help someone which encounter an odd problem with Java and also give some orientation where to get more information. Let's begin! (less talk and more action =) )

In this first part, let's try to understand some basic concepts/terms in JVM internals. Let's start with an overview of JVM memory:


click to enlarge

The diagram above summarize the basically structure of the JVM. In the Stack is a memory that each thread have that contains the Frames, like the state of each call you are doing in with that specific thread (each dotted rectangle is representing a thread). This guy you set using the -Xss JVM option (Also, you need to do some calculation to get the memory used by the JVM, one of them is multiplying the number of thread by the size of this memory pool). You can remind this space when you see StackOverFlowError, it happens due the JVM used the whole stack of that thread, so it will kill that thread due the failure to not keep running the process (due some bugs, the JVM can/could stop its own process due a crash, but the JVM stop is not a expected behavior).

There are some shared memory in the JVM. The Method Area (known as PermGen) is the area where the definition of classes and it meta information (for example the JIT references (JIT is the native code generated by the JVM which is faster than interpreted code)) are available. The PermGen can give OutOfMemory when you loaded too many classes. Like other features in the JVM, there are many options that you can use to optimize the throughput/latency.

But one of the most famous part of the JVM is the Heap. It is stored there the live objects. It is very complex (specially to optimize it, there are people who just work monitoring and enhancing the performance of JVM), so I will try to put in a simple way (removing some difficult concepts that it have). Basically when you create any object, the JVM will save it in the Heap, inside the Young area, and due it is very new, it will be in Eden space. If your object is not in use, it will be removed by Garbage Collector (GC) (this happens in all the spaces, only in the Stack space it doesn't). As the time goes, the objects are migrating to another spaces in the Heap. It will move to the Survivor Space (SS#1)(SS#2) and then (finally) to Old/Tenured Space. The expected JVM behavior is that each of those moves between spaces, less objects are removed. There is two special events associate with the Heap, I just called "removed" but there is two types of it (and a lot of things more in the following links): Scavenge and Stop-the-world events. The Scavenge is when the JVM do a normal job (removing objects of the Heap), but in some cases it need to guarantee that no thread will interfere in its job, so all thread stop working to the GC collect some objects in the Heap.

As I said, I will not cover too many details leaving some links and the comments section of this post to you can get further help. I will give some description with the link, that might help giving an preview what you will see.

#1 - http://en.wikipedia.org/wiki/Jvm#Heap - It is a very sumarized overview of the Heap, but the entire wiki page is very nice to you get a bit more familar of what happens inside your JVM. To get more familiar with some term used here and other details see also http://en.wikipedia.org/wiki/Java_performance .

#2 - http://www.slideshare.net/dougqh/jvm-internals-key-note and http://www.slideshare.net/caroljmcdonald/java-garbage-collection-monitoring-and-tuning - Very cool links. They cover most of things you might want to know about the JVM, such as memory spaces, collector's algorithms, JVM tuning and monitoring (the order of the links is due the complexity).

#3 - http://docs.oracle.com/javase/specs/jvms/se7/html/jvms-2.html#jvms-2.5.3 - This is the JVM specification. The link is to the memory section, I would also suggest to take a look into the Table of Contents to give an idea of how big the JVM is http://docs.oracle.com/javase/specs/jvms/se7/html/index.html )

#4 - http://www.slideshare.net/aszegedi/everything-i-ever-learned-about-jvm-performance-tuning-twitter and http://www.slideshare.net/aragozin/garbage-collection-in-jvm-mailru-fin - These links are awesome! Unbelievable that we can find this kidn of thing in the internet =D! There presentes go very deep in the JVM internals subject. It is a good resource to see if you want to tuning a JVM and your Java application. If you like this subject, you can follow the site http://www.javaperformancetuning.com/ .

#5 - http://www.infoq.com/news/2013/03/java-8-permgen-metaspace - This link shows that some internals of JVM are changing in Java 7 (and much more in Java 8)

#6 - http://www.oracle.com/technetwork/java/javase/gc-tuning-6-140523.html#available_collectors.selecting - This is a Oracle's guide of how to tune its JVM. See also this blog post https://blogs.oracle.com/jonthecollector/entry/our_collectors .

I have others links that I'd like to share, but I have to dig more in my bookmark.

I will post the next post I will cover problem solving aspects of JVM problems (how to identify and solve most of cases).

Goodbye internet!

Luan

Saturday, June 22, 2013

Spring cleaning

I will make some new posts soon! I will give an idea what is coming:

  • A JVM post
  • Cache post
  • Cloud post
  • English post (for Brazilian to learn english)
  • Camel post
  • and others =) 
Best regards!
Luan

Sunday, April 21, 2013

Presentations: an update


Hi guys!

An update:

I changed some links inside of the presentations that I made in JUDCon that to make more clear where the projects are in GitHub. Also I updated the main page of GitHub to have such information

Above the links of the presentations:

https://github.com/luan-cestari/judcon2013_bigdata
https://github.com/luan-cestari/judcon2013_switch
https://github.com/luan-cestari/judcon2013_fuseesb

Thanks for reading!
Luan

Note:
Hit 's' doring the presentation [1,2,3] to see some notes I put there. I also have a doc in Google Drive with many information, articles, videos and so on. I will format that and made it public available.
[1] http://luan-cestari.github.io/judcon2013_bigdata/#/
[2] http://luan-cestari.github.io/judcon2013_fuseesb/#/
[3] http://luan-cestari.github.io/judcon2013_switch/#/

Thursday, April 18, 2013

Three presentations in JUDCon 2013 Brazil


Hi Guys!!!!

Here are the links for the 3 presentations I made for JUDCon 2013 Brazil:

http://luan-cestari.github.io/judcon2013_bigdata/#/
http://luan-cestari.github.io/judcon2013_fuseesb/#/
http://luan-cestari.github.io/judcon2013_switch/#/

Hope you enjoy it =D Any question or an example you want from a specific technology, just call me that we can provide =D

[Note] Until JUDCon finish, there are not the last version yet ;) Have to wait a bit more to I execute the final "git push" =)

Saturday, March 30, 2013

I'm preparing a presentation about JBoss Fuse (http://fusesource.com/redhat/) that will be an overview and help to understand SOA patterns and how to use the main features of the product and its components.

Coming soon....

Saturday, May 12, 2012

Creating Application: #1 = HTML5 (Video) + Maven + Netbeans + jQuery + Java + Git

Hi Guys!

It's been a long time! How are you doing? =) Well, due I got many project to do I didn't post anything =P.

But, let's go to the main propose of this post. I created a very detailed well documented project to provide an example of how to use technologies such as  HTML5 (Video), Maven (POM), Java (Servlet, Architecture, Design (OO, DRY, etc)), Netbeans and jQuery. With it, I hope people can use have a basic idea of use of HTML5 Video tag to create a playlist (it will not be required to use flash player to play medias such as videos and audio). The playlist that refer is a list of video to be loaded to server a client and can be used to simulate a unique merged video. For example, imagine that can be used to create an application that given an audio it can create the speaking , put the videos of each word in the playlist and the result would be a merged version of it, without any additional processing in the server side. Another example it could be used to create a playlist of videos of sign language (ASL, LIBRAS, etc).

Well, the business of the application is, given a text to translate, it will be displayed the translation and display a playlist of videos or an error message, all using jQuery AJAX request. I created the project with emphasis on the HTML5 video, using javacript callback functions to create a chain that makes all the videos play and load in parallel , like as a video is loaded, the next one will be loaded an so on. The objective was to mimic a one big video instead of any need of merging files on the server side. I'll improve this project later, using more cache, HTML5 resources, JSON, CDI and create some diagrams to be easy to understand.

Here is the link to the project source code https://github.com/luan-cestari/HTML5VideoTest Well, any problem, just call me or send a message! =)

See ya!

Luan

Sunday, March 13, 2011

Back in black!

Hi everyone!

The topic's title is inspired in AC/DC's song.

Let's puts some objectives that I'm thinking these days. One of them is to continue the posts about OCJP. Another technologies that I saw theses days and I will share here are:

  • GWT / GAE
  • Spring Roo / others Spring stuff
  • Weld / Seam
  • Java 1.7
  • Groovy / Ruby / Others languages 
  • JS
  • Lucene
  • Maven
  • Design Patterns
  • WS / SOA / RESTful
  • Mobile stuff (like the SDK and frameworks for Android and iOS)
  • Things about Agile / Software Engineering / Project Management  
  • and many others things
I'll probably pickup one of these and write about with example here =).

Bye ! (I wrote "Buy" haha )

Saturday, February 19, 2011

BRB

Got many thing to do for now. In the Monday I'll begin to post again. But the good news was that I read an training material and I leaned a lot =D

CY

Sunday, February 13, 2011

Some more topics

Continuing...

JavaBeans Standards
Properties (private instance of variables) can only be accessed by getters and setters methods that is respectively getName and setName. In the case of boolean properties can use isName as the getter method. Those methods must be public. The return/argument type must matches for the type of the property.

Listeners (objects that receives informations when some specific event occurs) must end the methods with "Listener". There is the addXXXListener method to register and the removeXXXListener to remove it. Both have argument and returns void. The XXX is the type of the listener. If we have some like "removeJusticeListener(TestListener t)" is wrong due instead of "TestListener" it should be "JusticeListener".

Let's resume the couse =)

My last post was long long ago (2~3 days lol). But let's keep the training (of course I didn't stop to read the SB*, I just didn't post what I read in those days)

Well, this is a summary what I'm reading and understanding, so do not have a details or something that I think that not aggregate a "knowledge" value to me.

I'll try to attach the project that I'm testing things here...

Legal Identifiers
- Java is case sensitive (like names "TestCaseSensitive" and "testCaseSensitive" will different)
- Must not start with number!
- Can use any letter (including using unicode like \u0420), number, currency charactere ($), connecting character such as underscore (I didn't find any other).
- No limit of number of characters
- You can't use keywords (above will be a list of it)

Keywords

(I just wrote down here the same list present in the SB*, Also i tried in the eclipse that pointed as )
abstract boolean break byte case catch
char class const continue default do
double else extends final finally float
for goto if implements import instanceof
int interface long native new package
private protected public return short static
strictfp super switch synchronized this throw
throws transient try void while assert enum

Hmmm Just put a test of code syntax highlight


I'll post some more thing in next few hours ... cya guys =)

References:
* = I prefer call SB because the Surname of both author of SCJP Sun Certified Programmer for Java 6 Exam 310-065, Katherine Sierra and Bert Bates, referring to this link