Skip to content

Instantly share code, notes, and snippets.

View wezell's full-sized avatar

Will Ezell wezell

View GitHub Profile
@wezell
wezell / dotcms-get-demo-site-starter-urls.sh
Created April 13, 2022 21:59 — forked from yolabingo/dotcms-get-demo-site-starter-urls.sh
Gets the CUSTOM_STARTER_URL for a specific version of dotCMS
#!/bin/bash
# https://gist.github.com/yolabingo/f11e81b2cbdb00fff9b1ae0ef8076263
# checks out dotcms/core GH repo, then prints the CUSTOM_STARTER_URL for demo site content
# for each tagged version release
# output formatted for docker-compose.yml
# local_ip=$(ifconfig | grep "inet " | grep -Fv 127.0.0.1 | awk '{print $2}')
gitdir=/var/tmp/dotcms-get-starter-urls-repo

GraphlQL introspection query via curl

cat introspection_query.json

{ 
  "query": "query IntrospectionQuery {
      __schema {
        queryType { name }
        mutationType { name }
SELECT blocked_locks.pid AS blocked_pid, blocked_activity.usename AS blocked_user, blocking_locks.pid AS blocking_pid, blocking_activity.usename AS blocking_user,
@wezell
wezell / index.html
Last active October 30, 2017 23:14
<html>
<head>
<script>
function getUrl(){
var url = (window.location.hash.length==0)
? "/about-us/index"
: window.location.hash.substr(1);
if(!url.startsWith("/")){
url = "/" + url;
@wezell
wezell / 0_reuse_code.js
Created June 17, 2017 23:46
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
/html/js/dojo/release/dojo/dijit/BackgroundIframe.js
/html/js/dojo/release/dojo/dijit/Calendar.js
/html/js/dojo/release/dojo/dijit/CalendarLite.js
/html/js/dojo/release/dojo/dijit/CheckedMenuItem.js
/html/js/dojo/release/dojo/dijit/Destroyable.js
/html/js/dojo/release/dojo/dijit/Dialog.js
/html/js/dojo/release/dojo/dijit/DialogUnderlay.js
/html/js/dojo/release/dojo/dijit/DropDownMenu.js
/html/js/dojo/release/dojo/dijit/Menu.js
/html/js/dojo/release/dojo/dijit/MenuItem.js
hot-fries:core will$ ab -n 1000 -c 25 http://127.0.0.1:8080/about-us/
This is ApacheBench, Version 2.3 <$Revision: 1748469 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking 127.0.0.1 (be patient)
Completed 100 requests
Completed 200 requests
Completed 300 requests
hot-fries:core will$ ab -n 10000 -c 25 http://127.0.0.1:8080/about-us/
This is ApacheBench, Version 2.3 <$Revision: 1748469 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking 127.0.0.1 (be patient)
Completed 1000 requests
Completed 2000 requests
Completed 3000 requests
Completed 4000 requests
objc[20702]: Class JavaLaunchHelper is implemented in both /Library/Java/JavaVirtualMachines/jdk1.8.0_101.jdk/Contents/Home/bin/java (0x1002144c0) and /Library/Java/JavaVirtualMachines/jdk1.8.0_101.jdk/Contents/Home/jre/lib/libinstrument.dylib (0x10032b4e0). One of the two will be used. Which one is undefined.
2017-03-09 10:12:18.278 INFO org.glowroot - Glowroot version: 0.9.12, built 2017-02-27 03:05:14 +0000
2017-03-09 10:12:20.829 INFO org.glowroot - plugins loaded: Cassandra Plugin, Executor Plugin, Grails Plugin, Hibernate Plugin, HTTP Client Plugin, JAX-RS Plugin, Jdbc Plugin, JMS Plugin, JSF Plugin, JSP Plugin, Logger Plugin, Play Plugin, Netty Plugin, Quartz Plugin, Redis Plugin, Servlet Plugin, Spray Plugin, Spring Plugin, Struts Plugin
Mar 09, 2017 10:12:28 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Valve} Setting property 'resolveHosts' to 'false ' did not find a matching property.
Mar 09, 2017 10:12:28 AM org.apache.catalina
2017-03-05 09:40:53
Full thread dump Java HotSpot(TM) 64-Bit Server VM (25.101-b13 mixed mode):
"Glowroot-Aggregate-Flushing" #50 daemon prio=5 os_prio=31 tid=0x00007fa2b5577000 nid=0x9f0b waiting on condition [0x0000700004924000]
java.lang.Thread.State: WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x0000000700308fb8> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039)
at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442)