Tuesday, December 7, 2010

Continuous Integration - Drupal way. Part 2 - Build.

Why should you read this article?

  • Developer, Team Leader, Admin:
    • You will find out how to use build script that will save your time, spend on configuration of your project on dev, test, stage and production servers, on local computers of managers and testers. 
    • Build script will allow you to make CI system and get all profits it gaves you.
  • Manager:
    • You have a lot of project in same time, and want to install in on local comp easily.
    • You will get standart way to install projects on some machine in one click. To install new project you have to run $ant in console. Do this on local machine.
    • You can demo machine with Husdon and build script. It will allow you allways have actual version of project to test and to show to client.
  • Tester, QA manager:
    • You have a lot of project in same time, and want to install in on local comp easily.
    • You will get standart way to install projects on some machine in one click. To install new project you have to run $ant in console. Do this on local machine.
    • You can make CI, add there tests and have regression testing easily.

Project page: ci-drupal

Tuesday, October 5, 2010

SQL to update pathes for modules with multisite drupal installation

Problem: 

Modules was setted up for one site from multisite drupal installation. So we have it installed in /sites/test.com/modules/ and that pathes we have in system table in DB. Now we need to see them on other site for example test.org so all pathes should be /sites/test.org/modules/.

Solve:

UPDATE `system` t, (
SELECT REPLACE(filename, 'test.com', 'test.org') as test, name as name, type as type
FROM `system` WHERE `filename` LIKE '%test.com%') AS t2
SET t.filename = t2.test
WHERE t.name = t2.name AND t.type = t2.type

Tuesday, September 28, 2010

Authcache - detailed documentation

Authcache is drupal community contributed module you can find here Authcache project page. The Authcache module offers page caching for both anonymous users and logged-in authenticated users. This allows Drupal/PHP to only spend 1-2 milliseconds serving pages, greatly reducing server resources. Please note that enabling authenticated user caching will require modifying how your user-customized content displays on your pages. You should be an experienced Drupal developer if you choose to implement the full functionality of this module. Anonymous caching won't require any changes and will offer a speed improvement over Drupal core since hitting the database can be completely avoided.

Authcache Installation
To install authcache module you need
  1. Download authcache module and extract it to drupal contrib modules dir (usual /sites/all/modules).


Saturday, March 13, 2010

Continuous Integration - Drupal way. Part 1 - Begining.

Motivation:
   I'm going  to grow quality of products we get  in company I working in.
   I'm going to make ability to show bugs free product when client what.    (functionality that marked "done" realy 100% done)
   I'm going to make code clear and developement process managing.
   I'm going to make regressive testing cheap.
   I'm going to remove trivial round things from my live.

And you?
Are you going to do the same?
If (Yes) {
  let's share out expiriance
}
else  {
  skip this article
}

CI will help us. I think you know what is CI and what goals it allow to reach. (If no, you can read about CI here).
This is the first article about CI in drupal development practice.
Goal of that articles is to describe architecture of CI system and disscuss it's effectivity.
I'm going to create CI infrastructure that will be easy to use on practice of drupal development.

Here is the plan:
1) Ant build scenario.
2) Hudson configuration.
3) Code quality control - Copy/Paste reduce and Code style.
4) Drupal Simple Test and CI.
5) Selenium and Drupal Simple Test module.
6) Effective build configuration.

More detailed about each of this items.