This file has been truncated, but you can view the full file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*! | |
* Angular Material Design | |
* https://github.com/angular/material | |
* @license MIT | |
* v1.1.1 | |
*/ | |
(function( window, angular, undefined ){ | |
"use strict"; | |
(function(){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isAuth(req, res, next) { | |
var token = req.body.token || req.param('token') || req.headers['x-access-token']; | |
//check whether request has token ! | |
if (token != undefined) { | |
// decode token | |
if (token) { | |
// verifies secret and checks exp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--create new column to create sequences | |
alter table modnames add id serial; | |
---update new column serial column with existing value | |
UPDATE modnames m | |
SET id = m0.modnameid | |
FROM modnames m0 | |
where m.modnameid=m0.modnameid | |
---now tricky part is to tell new serial to start from max(existingid) for referential integrity | |
--scenarios | |
---to figure out your serial sequence |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bootstrap.memory_lock: false | |
cluster.name: elasticsearch | |
http.port: 9200 | |
node.data: true | |
node.ingest: true | |
node.master: true | |
node.max_local_storage_nodes: 1 | |
node.name: MEH | |
path.data: C:\ProgramData\Elastic\Elasticsearch\data | |
path.logs: C:\ProgramData\Elastic\Elasticsearch\logs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
DIR="/cygdrive/C/elasticsearch-jdbc-2.3.4.1/" | |
bin=${DIR}/../bin | |
lib=${DIR}/../lib | |
echo '{ | |
"type" : "jdbc", | |
"jdbc" : { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[20:19:00,649][INFO ][importer.jdbc ][pool-2-thread-1] strategy standard: settings = {index_settings.elasticsearch.cluster=elasticsearch, index_settings.elasticsearch.host=localhost, index_settings.elasticsearch.port=9200, index_settings.index.number_of_shards=10, password=abc123, sql=select * from srt, url=jdbc:postgresql://localhost:5432/demodb?loglevel=0, user=postgres}, context = org.xbib.elasticsearch.jdbc.strategy.standard.StandardContext@b174f2c | |
[20:19:00,657][INFO ][importer.jdbc.context.standard][pool-2-thread-1] found sink class org.xbib.elasticsearch.jdbc.strategy.standard.StandardSink@15919ffa | |
[20:19:00,662][INFO ][importer.jdbc.context.standard][pool-2-thread-1] found source class org.xbib.elasticsearch.jdbc.strategy.standard.StandardSource@db207f0 | |
[20:19:00,694][INFO ][org.xbib.elasticsearch.helper.client.BaseTransportClient][pool-2-thread-1] creating transport client on Windows 8.1 Java HotSpot(TM) 64-Bit Server VM Oracle Corporation 1.8.0_131-b11 25.131-b11 with effective settings { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var elasticsearch = require('elasticsearch'); | |
var ElasticsearchWritableStream = require('elasticsearch-writable-stream'); | |
var connections = require('./config/db'); | |
var client = new elasticsearch.Client({ | |
host: 'localhost:9200', | |
log: 'trace' | |
}); | |
client.ping({ | |
requestTimeout: 30000, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
COPY srt (starttime, endtime) FROM STDIN delimiters E'\t' | |
1 4 | |
6 12.074 | |
13.138 16.183 | |
17.226 21.605 | |
22.606 24.733 | |
24.816 27.027 | |
31.657 33.617 | |
34.66 37.204 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*my normal promise function looks like this | |
normalfunc.then(function (data){ | |
}).error(function (){ | |
}) | |
function normalfunc(data) | |
{ | |
return new Promise(function(resolve, reject) { | |
resolve/reject | |
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
do | |
$$ | |
DECLARE _sql text; | |
BEGIN | |
WITH all_sequences | |
AS | |
( | |
SELECT | |
pg_namespace.nspname AS schema_name, | |
pg_class.relname AS table_name, |
OlderNewer