Skip to content

Instantly share code, notes, and snippets.

View FabioBatSilva's full-sized avatar

Fabio Silva FabioBatSilva

View GitHub Profile
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You 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
*
@FabioBatSilva
FabioBatSilva / SymlinkManifestWriter.java
Last active December 6, 2019 18:54
Delta lake SymlinkTextInputFormat Manifest Generation
package com.a3k.dw.tracking.driver;
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.fs.FSDataOutputStream;
import org.apache.hadoop.fs.FileSystem;
import org.apache.hadoop.fs.Path;
import org.apache.spark.SparkContext;
import org.apache.spark.sql.SparkSession;
import org.apache.spark.sql.delta.DeltaLog;
import org.apache.spark.sql.delta.Snapshot;
run:
@echo "[run] Start run"
mondrian.olap.MondrianException: Mondrian Error:Error while loading/reloading aggregates.
at mondrian.resource.MondrianResource$_Def3.ex(MondrianResource.java:1025)
at mondrian.rolap.aggmatcher.AggTableManager.initialize(AggTableManager.java:92)
at mondrian.rolap.RolapSchema.load(RolapSchema.java:465)
at mondrian.rolap.RolapSchema.<init>(RolapSchema.java:217)
at mondrian.rolap.RolapSchemaPool.get(RolapSchemaPool.java:214)
at mondrian.rolap.RolapSchemaPool.get(RolapSchemaPool.java:66)
at mondrian.rolap.RolapConnection.<init>(RolapConnection.java:160)
at mondrian.rolap.RolapConnection.<init>(RolapConnection.java:90)
at mondrian.olap.DriverManager.getConnection(DriverManager.java:112)
curl 'http://192.168.56.101:8983/solr/my_collection/select?wt=json&fl=id&fq=index_type:foobar&group=true&group.field=year_make_model&group.facet=true&facet=true&facet.field=year'
ull:org.apache.solr.common.SolrException: Exception during facet.field: year
at org.apache.solr.request.SimpleFacets$3.call(SimpleFacets.java:627)
at org.apache.solr.request.SimpleFacets$3.call(SimpleFacets.java:612)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at org.apache.solr.request.SimpleFacets$2.execute(SimpleFacets.java:566)
at org.apache.solr.request.SimpleFacets.getFacetFieldCounts(SimpleFacets.java:637)
at org.apache.solr.request.SimpleFacets.getFacetCounts(SimpleFacets.java:280)
at org.apache.solr.handler.component.FacetComponent.process(FacetComponent.java:106)
// CREATE COLLECTION
solr create_collection -c my_collection -shards 2 -d path-to-my-conf
// CHECK COLLECTION SCHEMA
curl http://solr-host.dev:8983/solr/my_collection/schema?wt=schema.xml
// SCHEMA ITS GOOD
// UPDATE SCHEMA

Summary

I'm trying to figure out how to use rebar to:

  • create erlang project
  • add a dependency on an erlang module from github
  • start the app via the erl console
  • create a release and start the app from the release (via the generated scripts)
@FabioBatSilva
FabioBatSilva / account.json
Last active August 29, 2015 14:08
Query flat data when indexing a document with conceptually many 'children':
{
"id": 1,
"username": "Box2Account",
"profiles": [
{
"id": "24029",
"gender": "1",
"birthday": "1982-05-03T04:00:00Z"
},
{
@FabioBatSilva
FabioBatSilva / carte-start-three-cluster-nodes.sh
Created June 3, 2013 18:36
Exercise 18: Clustering and Partitioning Example for starting carte with 3 instances on port 8081, 8082, 8083.
#!/bin/sh
### ====================================================================== ###
## ##
## Pentaho Start Script ##
## Example for starting carte with 3 instances on port 8081, 8082, 8083. ##
## ##
### ====================================================================== ###
cd "/Applications/pentaho/design-tools/data-integration"
@FabioBatSilva
FabioBatSilva / join-pdf.sh
Created March 26, 2013 01:25
join pdf files
gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=all.pdf *.pdf