grunt installation with npm error

Use this ‘sudo npm install grunt’  instead of  ‘npm install grunt’ if you get the error below

receiving error: ‘Error: SSL Error: SELF_SIGNED_CERT_IN_CHAIN’ while using npm

creating soap messages manually


If you have VersionMismatchException on weblogic server it is the best way to create soap messages manually, there is a code sample below which prepares soapmessages;


MessageFactory mf;
mf = MessageFactory.newInstance();
SOAPMessage message = mf.createMessage();

SOAPBody body = message.getSOAPBody();
SOAPHeader header = message.getSOAPHeader();

SOAPPart soapPart = message.getSOAPPart();

// below code prepares env tag

// <env:Envelope xmlns:env=”; xmlns:tem=””>SOAPEnvelope envelope =

envelope.addNamespaceDeclaration(“tem”, “;);

//  <env:Header>
// <tem:Authenticate> code below prepares header and authanticate tag

QName auth = new QName( “;, “Authenticate”, “tem”);
SOAPElement authEl = header.addChildElement(auth);


// below code prepares body content

QName activities= new QName( “;, “activities”, “tem”);
SOAPElement acEl= body.addChildElement(activities);

QName uCode = new QName( “;, “userCode”, “tem”);
SOAPElement uCodeEl = userActi.addChildElement(uCode);


useful linux commands

chmod -R 777 xyzfolder

changes folder permissions to mode 777 right set. -R is used as a recursion signature  means that commands will be executed for all inner folders and files inside this folder. 777 is a abbrevation of triple permission blocks and can be widen as

Read  Write  Execute

7 –> 1        1         1

first 7 works for owner

second 7 works for group

third for world

777 –> drwxrwxrwx

d means directory and the others are permissions, directory can be read execute and write by all type of users.

Another example:

chmod -R 651 xyzfolder

7 = 4+2+1 (read/write/execute)
6 = 4+2 (read/write)
5 = 4+1 (read/execute)
4 = 4 (read)
3 = 2+1 (write/execute)
2 = 2 (write)
1 = 1 (execute)

Owner can read and write

Group can read and execute

World can only executes


grails pagination

Grails documentation is not giving the solution on pagination thats why i’m writing pagination steps here;


probably you are sending instance list from controller


def index() {
        params.max = 10
        params.offset = 0
        redirect(action:”list”, params:params)


def list (){


def max = 10
        def offset = 0
            max = params.max
            offset = params.offset
        [fooList: Foo.list(max:max, offset:offset),




            <g:paginate total=”${fooList.size()}” action=”list” controller=”price”  />



grails tips

  • changing server startup port param: -Dserver.port
  • put application version to gsp files: <g:meta name=”app.version”/>
  • getting application parameter values: if you want to use application parameters on your application, do it in a service class , inject grailsApplication to your service class and type;

google announced android ide (based on idea)

while eclipse is a well-known ide for android developers for now on they have another option for developing. google announced a new ide for android developers. android studio is based on great idea. some new features of this ide;

  • page preview and layout editing capability
  • performance on android api integration
  • resources handling

ide using gradle for building process. about repository management svn,cvs and git are avaible within

is quoted from