Skip to content

Instantly share code, notes, and snippets.

View MPriess's full-sized avatar
🏠
Working from home

Michael Prieß MPriess

🏠
Working from home
View GitHub Profile
@MPriess
MPriess / karaf-maven-plugin
Last active October 19, 2016 10:35
org.apache.karaf.tooling:karaf-maven-plugin
[ERROR] Failed to execute goal org.apache.karaf.tooling:karaf-maven-plugin:4.0.6:assembly (default-assembly) on project xxxx-karaf: Unable to build assembly: Unable to resolve root: missing requirement [root] osgi.identity; osgi.identity=xxx-kar; type=karaf.feature; version=1.0.0.SNAPSHOT; filter:="(&(osgi.identity=xxx-kar)(type=karaf.feature)(version>=1.0.0.SNAPSHOT))" [caused by: Unable to resolve xxx-kar/1.0.0.SNAPSHOT: missing requirement [xxx-kar/1.0.0.SNAPSHOT] osgi.identity; osgi.identity=xxx.backend; type=osgi.bundle; version="[1.0.0.SNAPSHOT,1.0.0.SNAPSHOT]"; resolution:=mandatory [caused by: Unable to resolve xxx.backend/1.0.0.SNAPSHOT: missing requirement [xxx.backend/1.0.0.SNAPSHOT] osgi.wiring.package; filter:="(&(osgi.wiring.package=org.osgi.service.blueprint)(version>=1.0.0)(!(version>=2.0.0)))"]] -> [Help 1]
#### Private Share ####
[sharepoint-export]
path = /opt/myshare
guest ok = yes
guest account = fs5
writable = no
guest only = yes
browsable = yes
create mask = 0707
directory mask = 0707
input {
log4j {
port => 4712
}
}
output {
loggly {
key => abcdef12-3456-7890-abcd-ef0123456789
proxy_host => myproxy.com # string (optional)
proxy_port => 8080 # number (optional)
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>
<script src="http://raw.github.com/jzaefferer/jquery-validation/1.11.1/jquery.validate.js"></script>
<script src="http://raw.github.com/jzaefferer/jquery-validation/1.11.1/additional-methods.js"></script>
</head>
<body>
function createFooLayer() {
return new OpenLayers.Layer.Vector(" foo", {
minZoomLevel: 7,
maxZoomLevel: 10,
styleMap: new OpenLayers.StyleMap(incidentStyle),
strategies: [new OpenLayers.Strategy.BBOX()],
protocol: new OpenLayers.Protocol.WFS({
url: geoserverUrl,
featureType: "foo",
featureNS: "http://www.foo.com",
public FooWS getEndpoint() throws MalformedURLException {
if (webservice == null) {
FooWS client = new FooWSService(new URL(wsEndpoint)).getFooWSPort();
if (timeout != -1)
{
Client cl = ClientProxy.getClient(client);
HTTPConduit http = (HTTPConduit)cl.getConduit();
@MPriess
MPriess / latency.markdown
Created June 19, 2012 09:27 — forked from hellerbarde/latency.markdown
Latency numbers every programmer should know

Latency numbers every programmer should know

L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns             
Compress 1K bytes with Zippy ............. 3,000 ns  =   3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns  =  20 µs
SSD random read ........................ 150,000 ns  = 150 µs

Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs

@MPriess
MPriess / gist:2873822
Created June 5, 2012 09:23
ConnectionPool Test
public class JUnitTest
{
private PGPoolingDataSource dataSource;
@Before
public void setup() {
dataSource = new PGPoolingDataSource();
dataSource.setServerName("localhost:5432/foo");
dataSource.setUser("postgres");
dataSource.setPassword("postgres");
@MPriess
MPriess / gist:1620048
Created January 16, 2012 09:54
Java Hibernate
public class UnicodeSQLServerDialect extends SQLServerDialect {
public UnicodeSQLServerDialect() {
super();
registerColumnType(Types.VARCHAR, 255, "nvarchar($l)");
registerColumnType(Types.CHAR, "nchar(1)");
registerColumnType(Types.CLOB, "nvarchar(max)");
}
}
@MPriess
MPriess / gist:1566121
Created January 5, 2012 16:57
Bundle Manifest
Bundle headers:
Bnd-LastModified = 1324388798185
Build-Jdk = 1.6.0_21
Built-By = doe
Bundle-Description = sqljdbc4-osgi
Bundle-ManifestVersion = 2
Bundle-Name = sqljdbc4-osgi
Bundle-SymbolicName = com.microsoft.sqlserver.sqljdbc4-osgi
Bundle-Version = 3.0.0
Created-By = Apache Maven Bundle Plugin