In the Vagrantfile, do :
# Create a public network, which generally matched to bridged network.
# Bridged networks make the machine appear as another physical device on
# your network.
config.vm.network :public_network
#!/bin/bash | |
# for use with cron, eg: | |
# 0 3 * * * postgres /var/db/db_backup.sh foo_db | |
if [[ -z "$1" ]]; then | |
echo "Usage: $0 <db_name> [pg_dump args]" | |
exit 1 | |
fi |
import sys | |
import xml.etree.cElementTree as et | |
from io import BytesIO | |
from django.core.exceptions import ValidationError | |
from django.core.validators import ( | |
FileExtensionValidator, | |
get_available_image_extensions, | |
) | |
from django.forms import ImageField as DjangoImageField |
@Override | |
public void run(TestDropwizardConfiguration configuration, Environment environment) | |
throws Exception | |
{ | |
env.lifecycle().addLifeCycleListener(new AbstractLifeCycleListener() | |
{ | |
@Override | |
public void lifeCycleStarting(LifeCycle event) | |
{ | |
if (!(event instanceof Server)) |
#http://googledevjp.blogspot.com/2011/04/google-code-jam-2011.html | |
def solve(rest, boards, counts): | |
if boards == []: | |
return rest == 0 | |
board = boards[-1] | |
count = rest / board | |
rest = rest % board | |
while count >= 0: | |
if solve(rest, boards[0:-1], counts): |
By: @BTroncone
Also check out my lesson @ngrx/store in 10 minutes on egghead.io!
Update: Non-middleware examples have been updated to ngrx/store v2. More coming soon!
If you have two days to learn the very basics of modelling, Domain-Driven Design, CQRS and Event Sourcing, here's what you should do:
In the evenings read the [Domain-Driven Design Quickly Minibook]{http://www.infoq.com/minibooks/domain-driven-design-quickly}. During the day watch following great videos (in this order):
/** | |
* Author: Ian Gallagher <igallagher@securityinnovation.com> | |
* | |
* This code utilizes jBCrypt, which you need installed to use. | |
* jBCrypt: http://www.mindrot.org/projects/jBCrypt/ | |
*/ | |
public class Password { | |
// Define the BCrypt workload to use when generating password hashes. 10-31 is a valid value. | |
private static int workload = 12; |
Hibernate documentation - https://docs.jboss.org/hibernate/core/4.2/devguide/en-US/html/ch16.html#d5e4669
Multi-Tenant Data Architecture - http://msdn.microsoft.com/en-us/library/aa479086.aspx
Hibernate: Discriminator based multi tenancy using filter? - http://stackoverflow.com/questions/12894357/hibernate-discriminator-based-multi-tenancy-using-filter
Manage Connection Pooling in multi-tenant web app with Spring, Hibernate and C3P0 - http://stackoverflow.com/questions/21223894/manage-connection-pooling-in-multi-tenant-web-app-with-spring-hibernate-and-c3p
Using Hibernate to Implement Multi-tenant Cloud Architecture - http://www.devx.com/Java/Article/47817