sophie: A cartoon-like representation of a girl standing on a hill, with brown hair, blue eyes, a flowery top, and blue skirt. ☀ (Default)
[personal profile] sophie
Hi,

Soon - probably within the next month - I'm planning to add code on the Dreamhack server which will automatically shut down Apache instances when the owner logs out (or at some point thereafter). I'm doing this because running Apache instances do take up resources on the Dreamhack server and a lot of people don't stop their Apache instances when they're not working on them, and it does make things a bit harder.

Currently I'm thinking of either shutting down the Apache instance either 7 days after the owner last logged out (unless they're currently logged in, of course) or shutting it down immediately on logout. If anybody has any issues with either of these options, please let me know in the comments - I'm very willing to listen to people on this.

If you have any other comments or questions, please do also comment. I'd be happy to answer any questions on this.
kaberett: Overlaid Mars & Venus symbols, with Swiss Army knife tools at other positions around the central circle. (Default)
[personal profile] kaberett
All of these will be going live in tonight's code push!

Read more... )

8 total issues resolved
Contributors: [github.com profile] cesy, [github.com profile] kaberett, [github.com profile] kareila, [github.com profile] pinterface
pauamma: Cartooney crab holding drink (Default)
[personal profile] pauamma
It's time for another question thread!

The rules:

- You may ask any dev-related question you have in a comment. (It doesn't even need to be about Dreamwidth, although if it involves a language/library/framework/database Dreamwidth doesn't use, you will probably get answers pointing that out and suggesting a better place to ask.)
- You may also answer any question, using the guidelines given in To Answer, Or Not To Answer and in this comment thread.
kareila: (Default)
[personal profile] kareila
As mentioned previously, we're about to reboot the Dreamhack server. Hopefully it won't be down too long; I'll update this post when it seems to be back up.

Update: seems to be back now.
denise: Image: Me, facing away from camera, on top of the Castel Sant'Angelo in Rome (Default)
[staff profile] denise
The company that hosts the Dreamhack machine has let us know that they're prepping to migrate the machine to their new platform. We've been warned that due to the large number of files on the machine, the migration is likely to take a long time or fail to complete successfully.

In order to minimize migration-related downtime and maximize the chance of not having failures, we're temporarily zipping up the home directories of anyone who hasn't touched any files in their account since 2014. Nothing will be permanently deleted -- just temporarily turned from many files into one file. (The problem isn't with the amount of data, but the number of files.)

We'll let you know when the migration is happening. EDIT: We're going to aim for Thursday night, probably sometime in the evening, but depends on when [personal profile] alierak has the chance to babysit it.
denise: Image: Me, facing away from camera, on top of the Castel Sant'Angelo in Rome (Default)
[staff profile] denise
I'm really sorry for the length of time it's taken me to make a final call on this -- I've been hoping that I would have the brainpower to deal with it, but my physical and mental health have both just been absolute shit lately, and I just have not had the cope. (And it's the kind of thing I can't delegate, not without also handing over the DW card, yadda.)

So, we will not be doing any kind of official DW trip to OSB this year -- I seriously considered a "yes, we will bring people, but you'll have to book your own travel and get reimbursed", but even that level of coordination is just beyond me at the moment. I'll be attending and speaking myself, and I need to reserve my (very few) spare cycles for talk prep and doing my own travel.

If you are attending on your own, I'm happy to meet up with people and hang out during, as long as I don't have to arrange anything! (Jen and I are staying at the Paramount.)

I'm sorry, folks; I'll do my best to make the call earlier next year!
karzilla: a green fist above the word SMASH! (Default)
[staff profile] karzilla
One of the things I want to start doing on a semi-regular basis is encouraging people to come to me with any questions they have about Dreamwidth development, large or small. I want to do this in two ways: for people who prefer real time chat, I have started holding IRC office hours, and for people who prefer threaded comment discussions, use this post as a springboard!

You can ask me absolutely anything related to Dreamwidth and I will answer to the best of my ability. Don't be shy! This is slightly different from the existing monthly question threads in that I will take responsibility for giving at least an initial answer, which others can then expound upon or contradict as they see fit.

If you would like to take advantage of my office hours, http://karzilla.dreamwidth.org/tag/devchat is where to find information about my schedule and how to sign up.
kaberett: Overlaid Mars & Venus symbols, with Swiss Army knife tools at other positions around the central circle. (Default)
[personal profile] kaberett
This is a big one, due in no small part to [github.com profile] pinterface, new to Dreamwidth volunteering and coding up a storm. I've gotta say. A very warm welcome also to [github.com profile] dfabulich, who I am pretty sure is also featured in a code tour for the first time!

Read more... )


40 total issues resolved
Contributors: [github.com profile] cesy, [github.com profile] chrisboyle, [github.com profile] dfabulich, [github.com profile] kaberett, [github.com profile] kareila, [github.com profile] me-and, [github.com profile] pinterface, [github.com profile] rahaeli, [github.com profile] zorkian

(... I swear I am never going six weeks between code tours again, I am NICE and DON'T DESERVE THIS...)
pauamma: Cartooney crab holding drink (Default)
[personal profile] pauamma
It's time for another question thread!

The rules:

- You may ask any dev-related question you have in a comment. (It doesn't even need to be about Dreamwidth, although if it involves a language/library/framework/database Dreamwidth doesn't use, you will probably get answers pointing that out and suggesting a better place to ask.)
- You may also answer any question, using the guidelines given in To Answer, Or Not To Answer and in this comment thread.
kaberett: Overlaid Mars & Venus symbols, with Swiss Army knife tools at other positions around the central circle. (Default)
[personal profile] kaberett
[personal profile] cesy has just been tripped up by my pull request #1751: she updated dw-free but not dw-nonfree, and as a consequence Apache wouldn't start. This suggests that you may need to update -nonfree at this point regardless of whether you actually use it; here are the instructions.
kaberett: Overlaid Mars & Venus symbols, with Swiss Army knife tools at other positions around the central circle. (Default)
[personal profile] kaberett
Hi folk,

The May contributor weekend is underway. Feel free to show up in person if you're local and at a loose end, or hop onto IRC and say hi :-)

We can also do Skype sessions for telecommuting!
[personal profile] pinterface

Summary

The present config system is ... non-ideal. It should be better.

Problems / Pain Points

The existing config system is all-or-nothing: if you want to tweak one thing in config.pl—$USE_ACCT_CODES or @SCHEMES, say—you have to copy the entire thing, and will no longer get tweaks made to the base config.

As you might imagine, this makes upgrading painful. "Oh, they added an option and ... now it's all broken because I don't set it."

The existing config system also fails to compose. While it loads three config files—config-private.pl, config-local.pl, and config.pl—it only loads one of each. If you clone, say, dw-nonfree into ext/, it will load config-local.pl from that. Unless you already have your own config-local.pl in ext/local, in which case it won't use nonfree's at all. So even though you only wanted to make one or two changes over the baseline, now you're stuck merging all three config-local.pl files manually.

And just forget about adding bobs-awesome-dw-plugin. I don't know if anything beyond dw-nonfree exists, but hey, maybe at some point.

It also brings up the question of what config variable goes into which file? @SCHEMES and @LANGS are pretty darned site-specific, but they're in config.pl. $HOME is set to the LJHOME env variable in config-local.pl, but when are you ever going to change that? (In fact, things are likely to break if you ever did!)

Good Things

One of the nice things about the existing config system is that it is pure Perl, bringing with it all the flexibility that provides. (Though some might argue that a turing-complete configuration file is also a drawback.)

Proposal

Summary

Let's move to a Debian-style conf-available/conf-enabled split system, where all config files are loaded, and then merged.

Technical Details

Directory Structure

Similar to the existing structure, except the provided config files would be placed into directories called something like "conf-available" or "conf.d". Config files would be loaded, in lexicographical order, from a single "conf-enabled" directory, which is populated with symlinks to the actual config files.

  • etc/conf-available/
    • private.example.pl
    • local.example.pl
    • defaults.pl
    • down-for-maintenance.pl
    • schemes.pl
  • ext/local/conf-available/
    • private.pl
    • local.pl
  • ext/dw-nonfree/conf-available/
    • nonfree.pl
    • schemes.pl
  • etc/conf-enabled/
    • 00-private.pl → $LJHOME/ext/local/conf-available/private.pl
    • 10-local.pl → $LJHOME/ext/local/conf-available/local.pl
    • 50-nonfree.pl → $LJHOME/ext/dw-nonfree/conf-available/nonfree.pl
    • 50-free-schemes.pl → $LJHOME/etc/conf-available/schemes.pl
    • 50-nonfree-schemes.pl → $LJHOME/ext/dw-nonfree/conf-available/schemes.pl
    • 90-defaults.pl → $LJHOME/etc/conf-available/defaults.pl

Config Files

Config files would each return a hash of values. It would be the responsibility of the config system to merge them all together appropriately. Essentially, this would be done in the same manner as used by Config::FromHash. However, because a number of config values are defaulted using prior values, it would be necessary to provide a dynamically-scoped variable containing the config-as-loaded-thus-far, to support that (hopefully that will be made clear by the examples).

# ext/local/conf-available/private.pl
{
    DOMAIN => "example.dreamhack.net",
    DBINFO => {
        # ...
    },
    # ...
};
# ext/local/conf-available/local.pl
{
    IS_DEV_SERVER => 1,
    SITENAME => "My Awesome DW Site",
    # ...
};
# ext/dw-nonfree/conf-available/schemes.pl

use DW::Config::FromHash qw( $CONF );

# Manually append schemes
$CONF->{SCHEMES} = [
    @{$CONF->{SCHEMES}},
    { scheme => 'neato', 'title' => 'Neato' },
    # ...
];

{
    # ...
    # Or, a potentially abstracted way to add things
    add_SCHEMES => [
        { scheme => 'neato', 'title' => 'Neato' },
    ],
    # ...
};
# etc/conf-available/defaults.pl

use DW::Config::FromHash qw( $CONF );

my $www = "www.{$CONF->{DOMAIN}}";
{
    DOMAIN_WEB => $www,
    SITEROOT => "http://$www",
    # ...
};

Merging, and Post-Merge

As mentioned, the config files would be loaded and merged in a manner similar—if not entirely identical—to Config::FromHash.

After the config files are loaded and merged, it would be the responsibility of the Config system to populate all of the appropriate variables in the LJ and DW packages.

Pros

Much simpler to use! You can create a file to override a single value and re-use the existing configuration for everything else. And it works more like you'd expect if you're used to conf.d directories.

Easier manual testing. While automated tests are obviously best, if you need to test something works without and without X service, you can add and remove a symlink to a conf file enabling that service, restart apache, and poke at things.

Paves the way for better support of plopping things into ext/ and having it work. No more "copy these config values into your existing file", just symlink and go.

Cons

Harder to fully comprehend. It's more files floating around, more state to keep track of (-available, -enabled, symlinks galore!).

It's dramatically different, and converting an existing installation would be a pain. (But see below.)

Config reloading (see start_request_reload in Config.pm) is more involved. Far more files to stat, and a lot more work to reload them all. One possibility would be to drop config reloading: how often are config changes made that don't involve a code change that would necessitate restarting apache anyway? ($SERVER_DOWN maybe? But that could easily be converted into a flag file check.)

Not Breaking Existing Installations

It would be preferable to avoid breaking existing installations. I think this is possible: after performing the above, follow that up by running the current config system. While that does mean having multiple config systems running, it gives people time to migrate at their leisure, rather than breaking things immediately.

After some time with the new system, we could then add deprecation notices in the event the old system is still in use. After sufficient time has passed, we could then eliminate it entirely.

Or, we could treat it like ripping off a band-aid and break things and be all "hey, sorry about the one-time pain but we're eliminating the smaller pains you almost never have anyway because really how often do we change these things?".

Why Not Just //= Everything?

One thing you might be thinking is "Well, why not just //= everything in the default config*.pl files?

That's definitely much easier to implement! And it brings with it many of the same benefits—people could simply add their overrides to config-local.pl or config-private.pl and never need to create or edit a config.pl (4f8258a does that for @LANGS, it's totally viable).

One of the drawbacks of that approach is that it requires a developer updating the default config*.pl files to never make a mistake. Accidentally used = instead? Tried to use //= to set a list, even though //= only works for scalars? Well, now things are quietly broken in other people's installs. By automating the merge behavior, we can largely avoid that. Whether the additional complication of a split config brings enough benefits over conditional sets to be worthwhile is another matter.

Thoughts? Questions? Alternative proposals?

kaberett: A sleeping koalasheep (Avatar: the Last Airbender), with the dreamwidth logo above. (dreamkoalasheep)
[personal profile] kaberett
Hello folk!

A reminder that I am running a Dreamwidth contributor weekend on the 14th of May, with spillover to the 15th. To get a sense of what goes on at these events, you can take a look at the November event summary and the February event summary.

If you need the physical address, please let me know and I'll PM it you along with instructions on how to get here by public transport. This is not the same address as the last time I hosted, so please do make sure you know where you're going!

If you'd like to attend remotely, find us on IRC or add me on Skype (ekabrett): I'm intending to have a spare machine running a video Skype call to interested folk from the corner of one of the rooms from about 11am on the Saturday (i.e. if you're attending in person and would rather not participate in the Skype call this will be avoidable).

More logistics! )
sophie: A cartoon-like representation of a girl standing on a hill, with brown hair, blue eyes, a flowery top, and blue skirt. ☀ (Default)
[personal profile] sophie
As a reminder, the Dreamhack machine is going to be taken offline at some time between 1am EDT and 6am EDT on April 28th for up to an hour, as the datacenter will be doing maintenance work!

You can use the links in the above paragraph to check when this is in your local timezone.
pauamma: Cartooney crab holding drink (Default)
[personal profile] pauamma
It's time for another question thread!

The rules:

- You may ask any dev-related question you have in a comment. (It doesn't even need to be about Dreamwidth, although if it involves a language/library/framework/database Dreamwidth doesn't use, you will probably get answers pointing that out and suggesting a better place to ask.)
- You may also answer any question, using the guidelines given in To Answer, Or Not To Answer and in this comment thread.
denise: Image: Me, facing away from camera, on top of the Castel Sant'Angelo in Rome (Default)
[staff profile] denise
The datacenter where the Dreamhack box is hosted will be taking the machine offline for up to an hour on the morning of April 28, sometime between 1AM and 6AM EST, for datacenter maintenance.

I'll try to remember to post a reminder closer to the date, but if I don't, somebody either poke me or post the reminder!
kaberett: A sleeping koalasheep (Avatar: the Last Airbender), with the dreamwidth logo above. (dreamkoalasheep)
[personal profile] kaberett
... well I meant to get this code tour together before the code push went live, but I totally didn't.

AND THEN, right, this unruly rabble of devs, would you believe it, wrote more fixes post-push. RUDE.

Which is to say, this code tour is getting separated out into fixes that are live on the site, and fixes that will be going into the next push...

... and, of course, a warm welcome to [github.com profile] dteklavya, whose first patch (I think!) is in this code tour!

Already up and running! )

For next time! )

13 total issues resolved
Contributors: [github.com profile] azurelunatic, [github.com profile] cesy, [github.com profile] chrisboyle, [github.com profile] dteklavya, [github.com profile] kareila
kareila: Rosie the Riveter "We Can Do It!" with a DW swirl (dw)
[personal profile] kareila
Every few months, I run through [site community profile] changelog compiling a list of who has been contributing patches to our code repository, with the understanding that this is not a competition, or any sort of "high score" list. It's intended as a guide for casual developers, to discern not only our most prolific contributors, but also those who have contributed to the project most recently and therefore would be more likely to provide a timely, informed response to development questions. That is why the list is sorted by "Latest" instead of "Changes".

In general, one commit on Github equals one point in the "Changes" column, but fractional points are awarded for collaborative efforts — the most common example being a new S2 theme, where usually half credit is awarded to the theme author and the other half to the person who converts the theme into a code patch. Due to the nature of development, some changes are massive contributions of new code, and others are tiny tweaks; there is no correlation with the amount of effort involved. We are grateful to everyone who helps to improve Dreamwidth, in ways large or small.

I last compiled this list at the beginning of October. Since that time, we have welcomed four new contributors: [github.com profile] fastbean-au, [github.com profile] ljacob, [github.com profile] chrisboyle, and [github.com profile] srukle. Congratulations and thank you again!

  #  User                      Changes     Latest
  1. kareila                     946.5     Fri Apr 01 07:28:03 2016 UTC
  2. azurelunatic                    8     Mon Mar 28 05:54:30 2016 UTC
  3. srukle                          7     Wed Mar 23 16:44:54 2016 UTC
  4. kaberett                       36     Tue Mar 22 12:05:56 2016 UTC
  5. me_and                         29     Tue Mar 15 12:10:57 2016 UTC
  6. sgsabbage                      17     Wed Feb 24 20:45:39 2016 UTC
  7. cesy                        23.83     Sun Feb 21 12:20:46 2016 UTC
  8. sophie                         58     Sun Feb 14 18:19:32 2016 UTC
  9. hotlevel4                      50     Sun Jan 03 18:59:57 2016 UTC
 10. chrisboyle                      4     Sun Nov 08 01:43:26 2015 UTC

 11. ljacob                          1     Sat Nov 07 12:13:45 2015 UTC
 12. fastbean-au                     1     Tue Oct 27 09:13:57 2015 UTC
 13. ninetydegrees              697.93     Tue Oct 20 21:15:19 2015 UTC
 14. mark                        544.5     Sun Aug 30 03:12:20 2015 UTC
 15. pseudomonas                     3     Sat Aug 08 09:45:06 2015 UTC
 16. angelikitten                    1     Wed Aug 05 19:50:20 2015 UTC
 17. exor674                     349.5     Tue Aug 04 21:03:54 2015 UTC
 18. dteklavya                       3     Fri Jul 17 11:51:30 2015 UTC
 19. fu                         2167.5     Tue Jul 14 23:44:50 2015 UTC
 20. momijizukamori             222.66     Thu Jun 25 23:01:08 2015 UTC
The rest of the list... (154 total) )
kaberett: A sleeping koalasheep (Avatar: the Last Airbender), with the dreamwidth logo above. (dreamkoalasheep)
[personal profile] kaberett
TOURING COD. Quite a lot of cod, because this round of code tour contains most of the pull requests that were made during the contributor event at the end of February!

These will all be going live in the next code push.

Read more... )


21 total issues resolved
Contributors: [github.com profile] Sophira, [github.com profile] azurelunatic, [github.com profile] cesy, [github.com profile] kaberett, [github.com profile] kareila, [github.com profile] me-and, [github.com profile] sgsabbage, [github.com profile] srukle
kaberett: Overlaid Mars & Venus symbols, with Swiss Army knife tools at other positions around the central circle. (Default)
[personal profile] kaberett
My previous was INEPT, by which I mean "I am very sorry, I had failed to adequately get my head round familial obligations including celebrating a 98th birthday party"; consequently the dates are instead the 14th and 15th of May, and questions of whether to hold this round in a hackerspace resolve to "no, because I'll have spent a week in the depths of Cornwall" (half a mile down a grass lane outside the village, for serious, and while the neighbour's just paid to have cable laid down the lane my grandfather does not quite believe in the Internet, and whether there's mobile signal at all is entirely dependent on which way the wind is blowing).

So to reiterate, apologies for the misadvertisement, and the next contributor weekend will be the 14th and 15th of May.

Profile

dw_dev: The word "develop" using the Swirly D logo.  (Default)
Dreamwidth Open Source Development

June 2016

S M T W T F S
    12 34
567891011
1213 1415 1617 18
1920 2122232425
2627282930  

Syndicate

RSS Atom

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Jun. 27th, 2016 11:08 am
Powered by Dreamwidth Studios