(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
package com.example | |
import groovy.util.logging.Slf4j | |
import org.springframework.boot.SpringApplication | |
import org.springframework.boot.autoconfigure.EnableAutoConfiguration | |
import org.springframework.context.ApplicationContext | |
import org.springframework.context.annotation.ComponentScan | |
import org.springframework.context.annotation.Configuration | |
import org.springframework.context.annotation.Import | |
import org.springframework.web.servlet.config.annotation.EnableWebMvc |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
import groovy.json.JsonSlurper | |
import org.springframework.test.web.servlet.MockMvc | |
import static org.springframework.test.web.servlet.setup.MockMvcBuilders.* | |
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*; | |
import static org.springframework.http.HttpStatus.* | |
import spock.lang.Specification | |
/** | |
* A Spock Spring MVC Rest unit test that doesn't require a full spring context | |
*/ |
I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!
\
Execute "tishadow run" in your Titanium app directory whenever a JavaScript file changes. Edit your JS files in a text editor, save, then switch to the test device or simulator. Profit.
[sudo] npm install -g supervisor
This example shows how to insert intermediate gateways into a flow, in order to provide a "try/catch"-like block around parts of the flow.
This is necessary when using multi-threaded aggregation with a gateway, so the result (including errors) is returned properly to the original inbound gateway.
It is important to understand that the actual services (and the error transformer) do not send their output to the aggregator directly; by omitting the output-channel, the result (or error) is returned to the intermediate gateway and thence to the aggregator.
EDIT: Added specific tests for one or both messages failing; added a resequencer so the tests are deteministic.
Now that Titanium is starting to have a proper CLI, installing and using Titanium is 67% more awesome. At some of the CLI commands, you will be asked for config information and your Appcelerator login, but these are the high level steps:
sudo npm install -g titanium
titanium sdk install --default
titanium create
#!/usr/bin/env python | |
""" | |
Copyright 2011 William Dawson | |
Licensed under the Apache License, Version 2.0 (the "License"); | |
you may not use this file except in compliance with the License. | |
You may obtain a copy of the License at | |
http://www.apache.org/licenses/LICENSE-2.0 |
Locate the section for your github remote in the .git/config
file. It looks like this:
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = [email protected]:joyent/node.git
Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/*
to this section. Obviously, change the github url to match your project's URL. It ends up looking like this: