News aggregator
Fatal error
Hi folks. I'm working my way through Bill's AMAZING book on Drupal for Education. Everything has gone swimmingly until I've tried to create an Assignment content type for the teacher role (p. 109, ch. 4).
When I try to save the Assignment type with the new fields, I got the following error:
Fatal error: Call to undefined function: date_create() in /home/birv2/public_html/drupal6/sites/all/modules/date/date_api.module on line 642
I have all the date modules enabled as per instructions.
Any suggestions?
Bob
Drupal in EducationProgrammer/Analyst | EDUCAUSE
EDUCAUSE is seeking qualified candidates for two full-time positions located in either its Boulder, Colorado or Washington D.C. offices. Candidates will be part of a fun, creative team that is responsible for creating web applications atop the Drupal Content Management System.
Required Education and Experience:- 1-2 years experience creating database driven web sites
- Expert knowledge of Javascript and PHP
- Experience with database design, SQL construction and optimization
- Bachelor's degree in CS or equivalent experience
- Ability to think creatively to solve complex problems
- Understanding of social software and emerging trends in web technology
- Experience performance-tuning large, web-based applications
- Experienced contributor to Drupal/maintainer of Drupal contributed modules
- Experience creating and consuming web services with using REST and/or SOAP
- 1 year experience with AJAX/AHAH code
- 6 months experience with JQuery
- Experience with CVS/SVN
- Experience with Microsoft SQL Server and MySQL
Applications and salary requirements should be sent to jobs@educause.edu (please specify "Programmer Analyst " in the e-mail subject line), or by mail to EDUCAUSE, Programmer Job Search, 4772 Walnut St., Suite 206, Boulder, CO 80301-2538.
EDUCAUSE (http://www.educause.edu) is a nonprofit association whose mission is to advance higher education by promoting the intelligent use of information technology.
EDUCAUSE provides a casual work environment, offers an excellent benefits package and is an EOE employer.
Washington, DC DrupalersProgrammer/Analyst | EDUCAUSE
EDUCAUSE is seeking qualified candidates for two full-time positions located in either its Boulder, Colorado or Washington D.C. offices. Candidates will be part of a fun, creative team that is responsible for creating web applications atop the Drupal Content Management System.
Required Education and Experience:- 1-2 years experience creating database driven web sites
- Expert knowledge of Javascript and PHP
- Experience with database design, SQL construction and optimization
- Bachelor's degree in CS or equivalent experience
- Ability to think creatively to solve complex problems
- Understanding of social software and emerging trends in web technology
- Experience performance-tuning large, web-based applications
- Experienced contributor to Drupal/maintainer of Drupal contributed modules
- Experience creating and consuming web services with using REST and/or SOAP
- 1 year experience with AJAX/AHAH code
- 6 months experience with JQuery
- Experience with CVS/SVN
- Experience with Microsoft SQL Server and MySQL
Applications and salary requirements should be sent to jobs@educause.edu (please specify "Programmer Analyst " in the e-mail subject line), or by mail to EDUCAUSE, Programmer Job Search, 4772 Walnut St., Suite 206, Boulder, CO 80301-2538.
EDUCAUSE (http://www.educause.edu) is a nonprofit association whose mission is to advance higher education by promoting the intelligent use of information technology.
EDUCAUSE provides a casual work environment, offers an excellent benefits package and is an EOE employer.
Washington, DC DrupalersReflections on "ThinkGeek: The Interview"
This is not entirely by happenstance. ThinkGeek has a pseudo-policy of shunning the world, partly because they want to maintain an air of mystery about themselves and partly because that's really what geeks do, shun the world. In any event, this stance has made them into a fairly mysterious company and getting in an interview was tricky. I, along with my campus news website, tried to contact them several times, but their desire to remain an enigma ruled the day. Then, I got a break...
One of the sites I write for, GeeksAreSexy, published an article on one of ThinkGeek's new toys, the Van De Graaff Levitation Wand. This thing is kind of amazing and I pause here for a video of this awesome toy (I promise this is not just geeking out, it's also relevant to my story).
As it turns out, our story was picked up by Reddit and we sent over 40,000 hits to ThinkGeek's video. After this, Yan, the owner of GeeksAreSexy, contacted Shane, from ThinkGeek's PR and Marketing Department. Shane was happy with all the free publicity and Yan mentioned that he happened to have a "field correspondent" going to school not 3 blocks from ThinkGeek HQ. Yan asked if it wouldn't be too much trouble to get an interview. Shane said it would be his pleasure.
That "field correspondent" was me.
Now on my end, I had long been aware that ThinkGeek was based in Fairfax, VA (and cruelly close to my University), but I had never been able to get in for any reason. The Mason news website, Connect2Mason, where I have done some freelance work, had been trying for many months to get in contact with ThinkGeek for some kind of interview. Unfortunately, where the major tech press failed, so did our puny student organization (luv you guys!).
One day, back in November, I recieved an email from Yan. His message was actually a forwarded note from Shane that filled me in on all of the publicity we had created with the Van De Graaff video. It also included Shane's permission to do an interview (which could be video-based if we wanted). I just about fell out of my chair!
For the next month or so, I played tag with Shane to get this thing worked out. I made a deal with Yan to cut in Connect2Mason in return for their A/V support: namely beautiful cameraperson Natalia. She's been behind the camera for all my Jimmy Chows Down videos, so I figured if we were gonna do an interview, she should be my wingman...or winggirl...or wingwoman...or whatever.
Finally, the date of the interview arrived. Natalia and I packed up our gear (most of it borrowed from the school's A/V repository) and headed a couple blocks down the road to ThinkGeek World HQ. The building itself, as we would later learn, was an old elementary school, so there is a playground and baseball diamond right behind it. It's not exactly an imposing sight from the exterior.
Upon entering the building, we were met with quite a few "No Place Like 127.0.0.1" doormats and some cardboard cut-outs of Boba Fett. There beyond, it becomes hard to describe. ThinkGeek items are absolutely everywhere - not in a disorderly mess, but in a well-organized arrangement. This isn't their warehouse, so everything is either in use by the staff (for testing or for playing) or a return waiting to be dealt with.
As we prepped our equipment, Natalia informed me that we had absolutely no audio! After changing batteries on things and trying out multiple headphones, we decided to call it a day and apologized profusely to Shane. We had to go back to Mason with heads hung low, planning to come back next week. Even so, both of us were afraid that our hard work would never pay off and that this interview was doomed.
We did go back though. The audio problems, which we did not experience again, were probably fortuitous - the staff was much less busy on our second trip. The first thing we did was take a little tour of the offices. Each little room was different. The T-Shirt Gals had their own area with tons of t-shirt designs on the wall. There were customer support, tech support, and the areas for getting and testing new products. On one of the office windows there was a huge idea space, where the staff collaborated on the next blog post. On another wall, Darth Vader reigned unchallenged.
The crowd was by and large fairly camera shy, so we decided to settle down with one of the friendlier geeks, John Frazier, a ThinkGeek buyer. He was deemed the best man for the job because he actually procures the company's awesome products. John was extremely enthusiastic about our little project and really bent over backwards for us. He's also a Jedi model (for ThinkGeek anyway). That's him on the left!
John's interview made up most of our final video. He answered questions about the ThinkGeek "origin story," where they get their products from, and what it's like to there. Some of the stuff that didn't make it into the video was also very interesting:
-John used to work in a computer store with the guy who now runs the group inside of Google that manages Google's infamous white board (containing their master plan).
-During the taping of my interview questions (we only had one microphone), John still gave answers (fake ones) but they mostly involved how most of ThinkGeek's ideas and apparel come from homeless people. Dumpster diving also appears to be a large portion of his work (hopefully this will find its way into a blooper reel some day).
-That funny flashy thing in the video is a coaster that blinks differently depending on whose drink it is.
At the end of our interview, John took us on a surprise tour of the rest of the building. We got to see where they make the ThinkGeek videos and photograph the products. He also introduced to a lot of the ubergeeks up in the office that manages the site's backend. One of the coolest places was the break room, where just about everything screams geek. The refrigerators are labelled "Can Haz" and "Can Not Haz," the cutting board is actually a Space Invader, and there is an original Tron: The Video Game cabinet in the corner. We taped for about 20 minutes in there, but sadly, not a lot of it got into the final cut for reasons of length.
Overall, it was an awesome experience. I hope everyone will enjoy the video, but I wanted to write up this account to share some of the excitement I have about the place. It's probably, as John says, "a whole lot of work" in order to keep things going, but I'll bet it's also one of the coolest places you could ever work.
Bonus Video:
After a long day of walking around and taping the geeky wonderland that is ThinkGeek, then coming back and reviewing said tape, Natalia and I needed to take a mental break. What follows is the result of that break:
It's been a great experience making "ThinkGeek: The Interview." Make sure you check it out over at GeeksAreSexy.net on January 6th, 2009!
Lazy Loading Theme Variables
When a page.tpl.php file is generated all of the variables are populated with content. This includes all the regions, the css and javascript, and everything. Some of these are never used in some themes (e.g., $mission) and some are often rebuilt later like $styles and $scripts.
I propose we lazy load the content in these variables when the variables are called the first time which will typically be in the template files. Since lazy loading is a feature of objects it will mean these variables will be attached to objects.
So, in drupal 6 you theme would have:
<?php
print $styles;
print $scripts;
?>
The proposed change would make these:
<?php
print $template_object->styles;
print $tempalte_object->scripts;
?>
The name $template_object is just a working name.
The reason for this desired change is performance and scalability. For example, currently (in D5 and D6) all the regions are loaded for a page.tpl.php file. So, if you have a lot of regions they are loaded every time. If we move to lazy loading the variables that means the regions will be lazy loaded. Only when one is printed in a page.tpl.php file will it be loaded.
So, you could have 20 regions on your site. Stick 5 in your page.tpl.php file, put a different 5 in your page-front.tpl.php file, stick a couple in your node.tpl.php file (I use this to stick a related content block between my node and comments on a blog), and stick them where you please. Then, the regions content is only loaded if the variable is printed in a template file.
On top of that, any variables provided in drupal that you don't use won't cause a performance hit against your page. They will never be generated if you don't use them.
Thoughts? Suggestions?
Unofficial Drupal RoadmapExcessive cache_get time
I have noticed (I think) a strange thing. My cache_get times are excessive compared to rest of queries consistently. E.g on front page for logged in user I am seeing these numbers through devl module
203.92 1 cache_get SELECT data, created, headers, expire FROM main_cache WHERE cid = 'locale:mr'
172.59 1 cache_get SELECT data, created, headers, expire FROM main_cache_menu WHERE cid = '1:mr'
41.89 1 eval SELECT COUNT(uid) AS number FROM main_users WHERE status=1
25.56 1 drupal_lookup_path SELECT dst FROM main_url_alias WHERE src = 'front_page1'
.....
Consistently all queries below drupal_lookup_path are in single digit milliseconds. SO Why would cache_get took this long? The configuration is two dedicated server one running drupal and other running mysql.
I already confirmed there is index on cid for mainc_cache and main_cache_menu table and it is being utilized.
I am suspicious of the mysql limitation when a blob field is involved in query, the temp tables will be always disk based and not memory based. Is that happening here (a disk based table for the query)?because I have noticed only all sorts of cache table queries taking significantly longer.
Anybody has seen this before? Or may be http://2bits.com/articles/slow-mysql-queries-multi-server-setup-use-comp... is at play here?
High performanceBest practices for URLs, Titles, etc for SEO
I am redesigning my site using Drupal and am using pathauto, pagetitle, menu breadcrumb, global redirect, and other modules. I am quite new to Drupal and still getting my bearings.
Before I go live, I thought it would be helpful to decide on one pattern that would make sense to human readers and take into account SEO. I've seen pieces of this addressed, but haven't found anything that seems to cover the whole picture.
As I understand it, there are a number of places where one might have identical, or nearly identical, content when using these modules. Each location represents an opportunity for using and reinforcing keywords:
- URL
- Page title
- Menu
- Breadcrumb
- H1 title at top of page (seems to be called just "Title")
- Meta description (I'll include this for completeness, but think it stands more on its own in terms being generated separately and manually)
In addition, if I understand correctly, one or more of these could be derived from a taxonomy vocabulary.
Are there any best practices or favorite patterns for which of these should be the same and which should be different?
I'd appreciate any help. Also, in my particular case the content is on about 30 relatively static pages describing my services, in addition to a blog, so I don't have to worry about hundreds of product pages.
Thanks in advance.
Search Engine OptimizationSilver Spring Youth Media Group Looking for Drupal Sensei (revered teacher)
Gandhi Brigade, a Silver Spring Youth Media project, is looking for a Drupal Sensei. We have a small capacity building grant to renovate our drupal site www.gandhibrigade.org
We dimly perceive the potential of a Drupal site to create a social network around youth media; we want to train our young adults to do the building and need an experienced developer who likes working with youth to advise us on design and roll out. We have some money but that won't be the reason you will help us.
If interested contact Richard Jaeggi
301-588-1999
rjaeggi@gandhibrigade.org
Utilizing Multiple Caching Strategies?
Last night I (finally) updated my (ultra-simple) personal website to 6.0, and while I was at it I decided to try out some caching ideas that had been brewing in the back of my mind for a while.
Though all caching strategies have their pitfalls and drawbacks, the idea I wanted to try -- combining Boost and Memcache -- seems like a real live-wire. However, if it can be made to work, I think it might offer some significant advantages.
The origin for this idea comes from my experience with both modules. Boost's static file caching is the heavyweight champion for anonymous traffic as far as I've seen. It's essentially the poor-man's reverse proxy, preventing the http requests from even being handled by Drupal. This gives the best results I've seen yet in terms of handling big spikes (e.g. a slashdotting).
On the other hand, I've generally experienced Memcache as providing a tangible boost for logged-in users. My thinking is that because it places the load for cached application data (e.g. variables, views, menu tree, etc) into memory rather than on the SQL back-end, the data can be loaded more quickly, and this makes for snappier page execution times.
Running both of these systems seems like a workable idea. So far my site is running just fine, but again it's a very very simple use-case. While there's some redundant caching of pages -- e.g. on a fresh anon pageload, the page will end up cached in the database, memcached, and on the filesystem via boost -- that doesn't seem like a huge drawback. I'm curious if anyone has any experience here, thoughts to add, or holes to poke in this theory.
Below are some benchmarking numbers. I am laying siege to /node with 25 concurrent users in benchmarking mode for 1 minute, a pretty righteous surge of traffic (equivalent to close to a quarter-million visits in an hour). I am also watching top to observe server-load. This is all Drupal 6 on a mid-range VPS slice w/1gb of ram and APC enabled.
Initial System w/Regular Drupal Page Cache
Load under siege: 2.24
Siege result detail:
Transactions: 4135 hits
Availability: 100.00 %
Elapsed time: 59.52 secs
Data transferred: 119.89 MB
Response time: 0.35 secs
Transaction rate: 69.47 trans/sec
Throughput: 2.01 MB/sec
Concurrency: 24.58
Successful transactions: 4135
Failed transactions: 0
Longest transaction: 10.07
Shortest transaction: 0.12
Memcache Enabled (one server w/100Mb of cache; simple simple)
Load: 2.91
Siege result detail:
Transactions: 3477 hits
Availability: 100.00 %
Elapsed time: 60.42 secs
Data transferred: 100.81 MB
Response time: 0.43 secs
Transaction rate: 57.55 trans/sec
Throughput: 1.67 MB/sec
Concurrency: 24.74
Successful transactions: 3477
Failed transactions: 0
Longest transaction: 28.22
Shortest transaction: 0.11
As you can see, this is actually slightly worse. I think this is because of the extra overhead of running memcached and the fact that since my site is so simple and the requests are all for the same page, Drupal's normal/basic page-cache is actually more efficient w/its results already loading into the mysql query cache.
However, in a more complex configuration, this isn't often the case. Also, as I mentioned, memcached provides a speedup for logged-in users since Drupal doesn't need to hit the SQL to load cached application data like the menu tree, variables, block-cache, etc.
Boost
Load: 0.15
Siege result detail:
Transactions: 4527 hits
Availability: 100.00 %
Elapsed time: 60.44 secs
Data transferred: 131.67 MB
Response time: 0.32 secs
Transaction rate: 74.90 trans/sec
Throughput: 2.18 MB/sec
Concurrency: 23.91
Successful transactions: 4527
Failed transactions: 0
Longest transaction: 11.05
Shortest transaction: 0.09
As you can see, Boost is pretty unbeatable when it comes to logged-out page caching. However, it doesn't help at all for logged-in users. I think by combining the two, we can get the best of both worlds.
High performanceNew Hampshire Drives Growth with BPlan Comp
Creative Capitalism and the Continuing Social Entre Debate
Jargon of the Day: NGO, CBO
Jargon: NGO, CBO
Translation: NGO stands for non-governmental organization. CBO stands for community-based organization. The difference between them is that NGOs are generally formally structured organizations, registered with the government. Community based organization is a catch-all for any group of people working together toward a common goal.
Optimizing a Views generated block
I am struggling with the speed on my Views generated blocks. These blocks are essential for the functionality of the front page.
Logged out, with cache enabled both for page and block devel returns horrid page load times:
Executed 144 queries in 59187.65 milliseconds. Queries taking longer than 5 ms and queries executed more than once, are highlighted. Page execution time was 59675.94 ms.
Logged in as admin (uid=1) shows equally horrid page load times:
Executed 182 queries in 59032.05 milliseconds. Queries taking longer than 5 ms and queries executed more than once, are highlighted. Page execution time was 59650.23 ms.
devel module also shows me that the reason is those manic queries that are called for the views blocks. I enabled access to devel result to anonymous so you can see for yourself the horrid results: http://krepputal.elfur.org. (what's up with the seperate count query for the more link?).
I started by posting this post over at drupal.org, but realise that this group is propably the right place for solving the actual problem I have.
I'm building a site that handles two kinds of data:
1) feeds aggregated into nodes via FeedAPI and related modules.
2) nodes created by users via the forum module.
I'm worried that if this is the page load time during development, how will it be when more users will visit?
I've enabled colophon to display the modules used, but apparantly it isn't displaying any modules apart from the core in the module list (see http://krepputal.elfur.org/colophon)
I build the front page using the views module, generating blocks of categorised data for display. As this is feed aggregation and the number of distinct feeds aggregated is in the second hundred (it shows on the colophon page, casual count says 117) the number of nodes in the node table is rising fast.
As I said before, I've enabled cache in all places I can think of. I've even downloaded the cacherouter module and am trying to get that to work (why that doesn't work is another issue for another thread).
I'm basically at my wits end, and the frontpage display is the key to the site, so not displaying all that data is really not an option.
Any suggestions?
High performanceFacebook Breast Controversy Highlights Mommies
Virtual Museum of the Gulag Seized
Technical Architect / Consultant | Oshyn INC
Hi all,
We're looking for a Senior Drupal developer or an Architect who can provide us some Architectural design direction for a Huge site that we're implementing in Drupal.
If someone is interested, please email your resume, highlight your experience in Drupal and provide some references.
Thanks,
Gaurav Bhatt
Technical Project Manager
Oshyn Inc.
First Cache Router release for Drupal 7
Hello Drupal world!
I released beta1 of the 7.x branch of Cache Router over the holiday. The new release passes all Core Cache Tests for APC, File, Database, eAccelerator, and Memcache. XCache is currently broken, and I'm working to get that engine working again as well.
I've ported the admin statistic over as well. This is definitely a "BETA" release since there is still development work being done on Drupal 7 before it is going to be able to be released. The stats are not finished for DB, eAccelerator or File caching although I am open to suggestions on how we could accomplish those as easily as Memcache. APC stats and eA stats might be missing some information as they don't provide as much info as Memcache daemons do.
The last things to get done for a 1.0 release of Cache Router are:
- Finish session handling for Cache Router.
- Finish stats for each engine, or at least making information available that we can and note that the engine does not provide us the information.
- Fix XCache engine to not white screen.
- Clear out the issue queue to make this 1.0 release as stable as possible.
Any one who is interested in testing out the engines in their production environment or at least staging environment is encouraged to do so, but please realize that this is still BETA at this point.
There will be a new beta version of the 5.x and 6.x branches soon, although using this module with Drupal 6.x and up is much easier because of the core cache serialization issues from Drupal 5. I have posted patches for Drupal 5 all the way up to the latest release, but you will have to still patch your custom modules and common contrib modules such as Views and CCK to not serialize your own data for best performance.
Here is the admin stats interface:
Please fill out any issues in the queue for Cache Router here
Thanks,
Steve Rude
High performanceRickrolled IRL - I Think Reality is Collapsing...
Now if you have ever tried to pull packing tape off of shipping plastic, you know it's no picnic. I pulled out the kitchen scissors and after quite a bit of wrestling, I arrived at...more wrapping. This time it was festive wrapping paper. From the size and shape of the package, I could tell it was a CD case of some kind and I made quick work of the final layer.
Before I even got it totally out of the wrapping paper, I realized what it was. I could see this logo [see left] very clearly and I felt a feeling I had felt many times before while surfing the web. One of dread...I had just been Rickrolled.
This was not just any Rickroll though, this was a Rickroll "IRL" or "in real life." I've heard of such things happening, but really, in my own mailbox! What is this world coming to?
I have enlisted the help of the bear on my desk to help me document this crime against the memedom.
Here you can clearly see that this is the album that included "Never Gonna Give You Up" as the top track.
If you have suggestions on how I can get Andrew back, leave a comment or message me on Twitter. I cannot allow this kind of behavior to abide!!!
Looking backward, looking forward
My favorite posts from 2008:
1) Why health matters. My best friends’ daughter died, and in the terrible misery that followed, I did my best to take a lesson from it. My grieving friends liked the post, and people are still linking to it, so maybe it’s a useful lesson. I hope I never have to write a post again informed by such personal pain.
2) Things I believe in: Oral Rehydration Salts. I love talking about ORS. I think everyone needs to know about them.
3) Development 2.0 – more than jargon? This post is still being tossed about on twitter. Thinking about Development 2.0, writing the post, and talking to others about the contents helped me to finally get a grip on the concept. It was a really valuable process for me; I hope the result is valuable to others.
4) When do non-profits do more harm than good? A reader favorite, this post got amazing comments that enlightened me.
5) Things that do damage. My screed against thoughtlessness and poor planning.
6) Why I hate the word sustainability. Another post that helped me think things through, this generated a whole dialogue that I was proud to be part of.
7) Keep your banana to yourself. I love that I finally wrote something with a snappy title, and I think I said something important about the difference between street-corner charity and development work. Also, it got the best comment ever “Good grief. Such control! That's like potty-training your kids at gun point.”
8) Suffering does not make you special. Apparently I like to rant. This time, about how poverty doesn’t ennoble the human spirit, it grinds it down.
9) Ethics and International Development. Just a few more ways that doing good is very hard.
10) Humbling Hospitality Experiences. You can always find a way to give, if you want to.
Bonus Post: A semi-definite guide to my volunteer work and my consulting. I felt like a total jerk writing that post, but based on the feedback it has helped a lot of people set boundaries in their own lives. (And it got me a consulting gig. I’m listing it here just in case it gets me more.)
And here is my thought for 2009:
We're all in this together. We're not in this line of work because we want to help far-away strangers. We're in it because, in the end, we're one big blob of people on one scarred messy planet, and no one is truly healthy when others are bleeding. We are connected; there's no way around it. It's time to make that connectedness a source of strength.
Happy New Year!
*********
(photo credit: NASA/Goddard Space Center, via woodleywonderworks)