Social Icons

Pages

Featured Posts

Wednesday, 21 November 2012

How to build a svn release using Maven.

Hey guys today I will teach you or rather guide you through the steps to create a temporary and a major release using SVN Subversion and using maven.
You may choose a list of IDE's in order to write the code for your project.
I use Intelllij however, I have also developed a project in eclipse. Now before doing too much chatterboxing let me show you a detailed explaination of how to build your very own release using maven

1.Complete your project ready for packaging for the client. :)

2. Download SVN client
    There is a list of SVN clients to choose from and the following wikipedia link will guide you as to which one to choose.

http://en.wikipedia.org/wiki/Comparison_of_Subversion_clients

3. I personally chose Tortoise as it was simple.However, you can make your own choice by choosing from the others too.

Install the SVN client on your machine.

4. For tortoise
   To check if it is working or not
      ->   Create  a new folder
      ->   Right click on the folder
      ->   Click on svn Checkout
      ->  Enter the URL of the place where your project was created.
            Usually in company settings it is a server's URL link followed by the name of your project.
            For example :
            https://companyname.com/ProjectName/
      -> If the link exists then the project will get checked out in this location.
      -> Do also keep in mind that the URL link you enter is case sensitive for Tortoise.
 
TEMPORARY RELEASE
5.Do not check in the code.
Simply build the project using either command line or the IDEA maven build.
From command line

5.1 COMMAND:
                         D:\ProjectFolder\rootOfProject> mvn clean install
5.2 Obtain the war file in the target source folder of your project
5.3 Deploy the war file on the  glassfish server on the server where you have the project running.


FORMAL RELEASE (INCLUDES PATCHES)
1.For formal releases
Steps are as follows:
1. Check all code is checked in
2. Maintain your own build folder.
3. Inside your development environment ProjectRELEASE Folder
4. Check out the code in this folder
5. After check out a folder called trunk will be created
    D:\ProjectFolder\ProjectRELEASE> cd trunk
6. D:\ProjectFolder\ProjectRELEASE>mvn release:prepare
 What will this command do  ?
  -> CREATE the version for the formal release
  ->Update all the POM’s in your project
Link in maven
http://maven.apache.org/plugins/maven-release-plugin/examples/prepare-release.html
Check to see that this step is SUCCESSFUL
7. Release perform
 D:\ProjectFolder\ProjectRELEASE > Mvn release:perform
This will recheckout all the code and do a formal build of the project. Remember the  POM’s were update by the prepare step.
Check to see that this step is SUCCESSFUL
8. You will see ProjectRelease/projectname/target/checkout










Monday, 8 October 2012

SEO in Magento



I was looking for SEO support provided in Magento. Then I came to know about some nice articles.
Here I would not write anything about Magento SEO,  as already some awesome articles has been written on SEO in Magento.

Here are they :

Sunday, 7 October 2012

Always good to reserve ports for glassfish.

When you encounter any problem on your glassfish server and have to manually change the port numbers your glassfish server may tend to start and stop.

This is usually because the port numbers you have changed to already are in use .
You may encounter any of the following error messages each of which indicates that your port is in use:

SEVERE: java.net.BindException: Address already in use: JVM_Bind        
 
OR
 
Shutting down v3 due to startup exception : Address already in use: bind: 8181=com.sun.enterprise.v3.services.impl.monitor.MonitorableSSLSelectorHandler@1513e285|#]
 
SOLUTION:
Reserve the range of the ephermal ports 
 
LINK for Microsoft solution:
http://support.microsoft.com/kb/812873


 
 
 
 
 

Thursday, 4 October 2012

Glassfish admin-listener disabled by mistake.

Glassfish has a set of network listeners which are named are follows:
1.http-listener1
2.http-listener2
3.admin-listener
 
An HTTP listener named admin-listener, associated with the virtual server named __asadmin. For this listener, security is not enabled.
The admin-listener is used to listen  to the administrative Glassfish console  where you can configure all the settings for the  specific Glassfish domain.

HTTP listeners associated with the virtual server named server:  
The listener named http-listener-1 does not have security enabled.
The listener named http-listener-2 has security enabled.

Now we will focus on the error in which you might encounter when you by mistake disable the admin-listener.

SOLUTION is:

1. in command prompt run this command
 tasklist
 It will get the list of all the tasks and their process Id's.
2.Run netstat -a -o -n and check which process is using the port of your glassfish listener.
It will usually be a java process. End that java process if you know what it is.
3.If this does not work follow the following methods :

Glassfish always has its server log in the specific domain folder
The file structure will usually be something like glassfishv3/glassfish/domains/domain1/config/domain.xml.

Edit the domain.xml file. First check there is no process which is locking the file otherwise you will not be able to edit it.

Study the file beforehand and you will see there is a specification at the bottom like this
<network-listeners><network-listener port="8080" protocol="http-listener-1" transport="tcp" name="http-listener-1" thread-pool="http-thread-pool" />
  <network-listener port="8181" protocol="http-listener-2" transport="tcp" name="http-listener-2" thread-pool="http-thread-pool" />
  <network-listener port="4848" enabled="false"  protocol="admin-listener" transport="tcp" name="admin-listener" thread-pool="http-thread-pool" />
  </network-listeners>

Check whether these ports are open using the nestat -a command.
If  the ports are used you might see in the server logs which are located in
glassfishv3/glassfish/domains/domain1/logs/server.log there will be a message stating that the ports are already used.

In that case simply change the port number which has been specified in the error to something else.

Now focusing on our main problem if you have changed the  enabled="false" to enabled="true" it should solve your problem. :)

If you make a mistake in editing the domain.xml there is a domain.xml.bak which you can simply rename to the domain.xml file.

Cheers mate .. Hope this helps.
Any other problems simply email them to my email address and I will get back as soon as possible

jos.sanika@gmail.com




Tuesday, 2 October 2012

How to solve or improve Search functionality in Magento

Many of you might have faced problem with searching in Magento based website. Although Magento has improved it in recent versions.
Here I will just point 2 issues with Magento search functionality and their solution.

NOTE: In admin panel at Catalog - Manage Products - Product Name - General location you must set Visibility as Search or Catalog,Search . Otherwise product will not be visible in search results.

Issue 1: Search results are returning 0 results even though products are available in catalog.
Solution: This issue come due to incorrect indexes. Please apply below steps to get rid of this.
In admin panel go to System - Index Management. There Select All and re index all data.
In admin panel go to System - Cache Management. There Select All and refresh all data.

After this you will be able to see search results on your Magento based website.

Issue 2: How to enhance search results?
Solution:  To enhance results you have do small change in admin panel.
In admin panel go to System - configuration - Catalog - Catalog Search and then change Search Type to Combine (Like and Full text)

I hope above solution will solve your problem. In case you have any other problem feel free to ask me.

Sunday, 23 September 2012

Run a database upgrade script for your maven project.

If you build your project using maven but use ant to upgrade the database following will be a guideline to configure the environment if you get an error as ANT_HOME Not found.

Background description:
The first time you check out the project from the svn repository and build it the database scripts will get unpacked in a folder. In most large projects the folder name is database for correct location.

Whenever you wish to access the database upgrade script and run it from the command line you will have to use the following steps.

1.If ant is used to build the scripts then the first step to perform is to set the ANT_HOME.
I have to perform research as to if there are two project with their own ant instances how does it specifically work. But,however in order to set the ANT_HOME specify the path in the environment variables to point to the specific ant.bat file location.

For example :
DriveName:\ProjectName\database\target\sqlserver\bin -> this is the location of the ant.bat file.

If you set the ANT_HOME correctly you will not get the following error:
ANT_HOME not found.

2.After that open a fresh instance of the command prompt and then run the script again which should work great.


Problem solved. 


Friday, 21 September 2012

Remove index.php from magento url

If you’re working with magento it may be the case that index.php is visible in all the URLs of your magento based website. You’ll most likely want to remove index.php from the URL when you go live.
Here are the steps that will work for you :
  •  From Magento’s admin panel go to System > Configuration > Web and in Search Engine Optimization tab just change “Use Web Server Rewrites” to Yes
  •  Make sure both Base URLs for Secure and Unsecure tab don’t contain index.php
  •  Go to your site root folder and you will find the .htaccess file there. Open it on text editor and find the line #Rewrite Base/ magento. Just replace it with Rewrite Base/
  •  Go to Cache management page (system > cache management ) just refresh your cache and refresh the Web Rewrites also.

Hope all the above steps will work for you. If they don't please let me know.

 

Contact Us

info@intellozene.com

Our Website:
www.intellozene.com