Skip to content

Instantly share code, notes, and snippets.

View muehlburger's full-sized avatar
:octocat:

Herbert Mühlburger muehlburger

:octocat:
View GitHub Profile

Keybase proof

I hereby claim:

  • I am muehlburger on github.
  • I am muehlburger (https://keybase.io/muehlburger) on keybase.
  • I have a public key ASAhhpcYitwAT7pElhEBnbYJABp039r30Jwfb4Ay7ItXSQo

To claim this, I am signing this object:

@muehlburger
muehlburger / main.go
Created January 7, 2018 20:26 — forked from enricofoltran/main.go
A simple golang web server with basic logging, tracing, health check, graceful shutdown and zero dependencies
package main
import (
"context"
"flag"
"fmt"
"log"
"net/http"
"os"
"os/signal"
import nanotec.*;
class Stellantrieb
{
public static void main()
{
int current = drive.GetCurrent(); //übernimmt den eingestellten "Phasenstrom während der Fahrt"
public String createAttachment(String caseId, String path, String filename) throws Exception {
Path file = Paths.get(path);
byte[] data = Files.readAllBytes(file);
JSONObject obj = new JSONObject();
obj.put("ParentId", caseId);
obj.put("Name", filename);
obj.put("body", new String(Base64.encodeBase64(data)));
List<JSONObject> response = doPost("Attachment", obj.toString());
> db.shorties.find()
{ "_id" : "fyXu", "clickCount" : 2, "createdAt" : ISODate("2011-06-23T09:10:38.456Z"), "url" : "http://www.tugraz.at", "visitors" : [
{
"_id" : ObjectId("4e03030e25f59ace05000001"),
"httpUserAgent" : "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_7) AppleWebKit/534.30 (KHTML, like Gecko) Chrome/12.0.742.100 Safari/534.30",
"remoteAddr" : "127.0.0.1",
"remotePort" : 56814,
"requestMethod" : "GET",
"requestTime" : ISODate("2011-06-23T09:10:38Z")
},
/*
Provide the XMLHttpRequest constructor for Internet Explorer 5.x-6.x:
Other browsers (including Internet Explorer 7.x-9.x) do not redefine
XMLHttpRequest if it already exists.
This example is based on findings at:
http://blogs.msdn.com/xmlteam/archive/2006/10/23/using-the-right-version-of-msxml-in-internet-explorer.aspx
*/
if (typeof XMLHttpRequest == "undefined")
XMLHttpRequest = function () {