Skip to content

Instantly share code, notes, and snippets.

View aschrijver's full-sized avatar
💭
On the Fediverse as @ smallcircles at https://social.coop

Arnold Schrijver aschrijver

💭
On the Fediverse as @ smallcircles at https://social.coop
View GitHub Profile
@aschrijver
aschrijver / BsonMessage.java
Last active December 20, 2015 11:48
See also the discussion at: https://groups.google.com/forum/#!topic/vertx/R6yteLPghM8 In this gist RxMessage has an implicit parameterless constructor. It is instantiated in a generic version of the RxEventBus by using reflection from the message class that was passed in the constructor (and that equals the generic type element). Tradeoffs are t…
package org.example.vertx.eventbus;
import org.vertx.java.core.buffer.Buffer;
import io.vertx.rxcore.java.eventbus.RxMessage;
public class BsonMessage extends RxMessage<Buffer> {
// Do some interesting stuff here as well.
}
@aschrijver
aschrijver / camel-spring-config.xml
Last active August 29, 2015 14:04
jBPM, Spring, Camel question
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:camel="http://camel.apache.org/schema/spring"
xmlns:kie="http://drools.org/schema/kie-spring"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://camel.apache.org/schema/spring
http://camel.apache.org/schema/spring/camel-spring.xsd
@aschrijver
aschrijver / IntrospectionQuery.java
Last active May 11, 2016 09:16
GraphQL introspection query in graphql-java?
interface IntrospectionQuery {
String INTROSPECTION_QUERY = "\n" +
" query IntrospectionQuery {\n" +
" __schema {\n" +
" queryType { name }\n" +
" mutationType { name }\n" +
" subscriptionType { name }\n" +
" types {\n" +
" ...FullType\n" +
@aschrijver
aschrijver / Local_gradle_build_with_--stacktrace.log
Last active August 21, 2016 19:18
Troubleshooting 'TravicCI build fails but local build is just fine' on project engagingspaces/vertx-dataloader
✔ ~/dev/engagingspaces/vertx-dataloader [master|…1]
20:47 $ gradle clean test --stacktrace
:clean
:docProcessing
warning: The following options were not recognized by any processor: '[docgen.source]'
:compileJava
:processResources UP-TO-DATE
:classes
:compileTestJava
:processTestResources UP-TO-DATE
@aschrijver
aschrijver / index.html
Created July 22, 2017 06:32
Example of incorrect output running protoc-gen-doc with custom html mustache template
<!DOCTYPE html>
<html>
<head>
<title>Protocol Documentation</title>
<meta charset="UTF-8">
<link rel="stylesheet" type="text/css" href="http://fonts.googleapis.com/css?family=Ubuntu:400,700,400italic"/>
<style>
body {
width: 60em;
09:02 $ python build.py --interactive
entering interactive mode...
[0] Docker >> android-x86 >> NODE_ENABLED
[1] Docker >> android-arm >> NODE_ENABLED
[2] Docker >> alpine-linux-x64 >> NODE_ENABLED
[3] Docker >> linux-x64 >> NODE_ENABLED
[4] Docker >> linux-x86 >> NODE_ENABLED
[5] Vagrant >> macosx-x64 >> NODE_ENABLED
In file included from ../deps/v8/src/compiler/ast-graph-builder.cc:16:0:
../deps/v8/src/compiler/node-matchers.h: In member function 'bool v8::internal::compiler::FloatMatcher<T, kOpcode>::IsInteger() const':
../deps/v8/src/compiler/node-matchers.h:171:32: error: 'nearbyint' is not a member of 'std'
return this->HasValue() && std::nearbyint(this->Value()) == this->Value();
^
../deps/v8/src/compiler/node-matchers.h:171:32: note: suggested alternative:
In file included from /build/android-ndk-r13b/std-toolchains/android-17-arm/include/c++/4.9.x/cmath:44:0,
from ../deps/v8/src/utils.h:11,
from ../deps/v8/src/conversions.h:11,
from ../deps/v8/src/ast/ast-types.h:8,
Step 39/39 : EXPOSE 5900
---> Running in 586eb8e740f0
---> 252fbb99cceb
Removing intermediate container 586eb8e740f0
Successfully built 252fbb99cceb
Successfully tagged j2v8-android:latest
DOCKER running android@arm => docker-build-host
docker run --privileged -P -v /home/arnold/Development/misc/J2V8:/j2v8 --name j2v8.android.arm j2v8-android /bin/bash -c "cd /j2v8; python ./build.py --cross-agent docker -t android -a arm -ne nodejs j2v8cmake j2v8jni j2v8optimize j2v8java j2v8junit"
GNU bash, version 4.3.30(1)-release (x86_64-pc-linux-gnu)
Copyright (C) 2013 Free Software Foundation, Inc.
@aschrijver
aschrijver / npm-build-package.log
Created August 16, 2017 06:17
Output of `npm build package` showing `pkg` warnings
08:10 $ npm run package
> dat@13.8.1 package /home/arnold/Development/misc/dat
> pkg package.json -o dist/dat
> pkg@4.2.3
> Fetching base Node.js binaries to PKG_CACHE_PATH
fetched-v8.0.0-linux-x64 [====================] 100%
fetched-v8.0.0-macos-x64 [====================] 100%
fetched-v8.0.0-win-x64 [====================] 100%
@aschrijver
aschrijver / RNNodeService.java
Created August 17, 2017 11:47
React-native-node refactored to use J2V8
package my.example.nodeonandroid;
import android.app.Service;
import android.content.Intent;
import android.content.res.AssetManager;
import android.os.IBinder;
import android.util.Log;
import com.eclipsesource.v8.NodeJS;
import com.eclipsesource.v8.V8;