From 64f371e2da6240bcbe2a594ff411a50fdf135e24 Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Wed, 29 Apr 2015 12:10:53 -0700 Subject: [PATCH 01/14] Update to new version. --- core-js/pom.xml | 2 +- mindplot/pom.xml | 2 +- pom.xml | 4 ++-- web2d/pom.xml | 2 +- wise-editor/pom.xml | 2 +- wise-webapp/pom.xml | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/core-js/pom.xml b/core-js/pom.xml index 0740f46b..05076de6 100644 --- a/core-js/pom.xml +++ b/core-js/pom.xml @@ -9,7 +9,7 @@ org.wisemapping wisemapping ../pom.xml - 4.0.2-SNAPSHOT + 4.0.3-SNAPSHOT scm:git:git@bitbucket.org:wisemapping/wisemapping-open-source.git diff --git a/mindplot/pom.xml b/mindplot/pom.xml index 922d0853..d12df9c6 100644 --- a/mindplot/pom.xml +++ b/mindplot/pom.xml @@ -9,7 +9,7 @@ org.wisemapping wisemapping ../pom.xml - 4.0.2-SNAPSHOT + 4.0.3-SNAPSHOT diff --git a/pom.xml b/pom.xml index df68d9f2..6c703824 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ http://maven.apache.org/xsd/maven-4.0.0.xsd"> - 4.0.2-SNAPSHOT + 4.0.3-SNAPSHOT ${project.basedir}/wise-webapps @@ -16,7 +16,7 @@ org.wisemapping wisemapping WiseMapping Project - 4.0.2-SNAPSHOT + 4.0.3-SNAPSHOT pom diff --git a/web2d/pom.xml b/web2d/pom.xml index d43fef61..bc940ba7 100644 --- a/web2d/pom.xml +++ b/web2d/pom.xml @@ -9,7 +9,7 @@ org.wisemapping wisemapping ../pom.xml - 4.0.2-SNAPSHOT + 4.0.3-SNAPSHOT diff --git a/wise-editor/pom.xml b/wise-editor/pom.xml index 905b8da2..8bce716d 100644 --- a/wise-editor/pom.xml +++ b/wise-editor/pom.xml @@ -9,7 +9,7 @@ org.wisemapping wisemapping ../pom.xml - 4.0.2-SNAPSHOT + 4.0.3-SNAPSHOT diff --git a/wise-webapp/pom.xml b/wise-webapp/pom.xml index 6c90277c..d0717085 100644 --- a/wise-webapp/pom.xml +++ b/wise-webapp/pom.xml @@ -9,7 +9,7 @@ org.wisemapping wisemapping ../pom.xml - 4.0.2-SNAPSHOT + 4.0.3-SNAPSHOT From d2a6312b7c0531360f8829ac38a99b40c22b5584 Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Sat, 9 May 2015 02:43:46 -0300 Subject: [PATCH 02/14] fix bug WA-794: submitDialogForm not defined issue WA #resolve --- wise-webapp/src/main/webapp/jsp/mindmapEditorKeyboard.jsp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/wise-webapp/src/main/webapp/jsp/mindmapEditorKeyboard.jsp b/wise-webapp/src/main/webapp/jsp/mindmapEditorKeyboard.jsp index 59605d8b..f598b094 100644 --- a/wise-webapp/src/main/webapp/jsp/mindmapEditorKeyboard.jsp +++ b/wise-webapp/src/main/webapp/jsp/mindmapEditorKeyboard.jsp @@ -25,6 +25,9 @@ color: #ffffff; } +
From cec637afbe63afcc122cc4792fedaed0e2471a83 Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Sat, 9 May 2015 02:44:28 -0300 Subject: [PATCH 03/14] fix underscorejs.min.map not found --- .../src/main/javascript/libraries/underscorejs/underscore-min.js | 1 - 1 file changed, 1 deletion(-) diff --git a/mindplot/src/main/javascript/libraries/underscorejs/underscore-min.js b/mindplot/src/main/javascript/libraries/underscorejs/underscore-min.js index 3434d6c5..ab5fbd8b 100644 --- a/mindplot/src/main/javascript/libraries/underscorejs/underscore-min.js +++ b/mindplot/src/main/javascript/libraries/underscorejs/underscore-min.js @@ -3,4 +3,3 @@ // (c) 2009-2014 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors // Underscore may be freely distributed under the MIT license. (function(){var n=this,t=n._,r={},e=Array.prototype,u=Object.prototype,i=Function.prototype,a=e.push,o=e.slice,c=e.concat,l=u.toString,f=u.hasOwnProperty,s=e.forEach,p=e.map,h=e.reduce,v=e.reduceRight,g=e.filter,d=e.every,m=e.some,y=e.indexOf,b=e.lastIndexOf,x=Array.isArray,w=Object.keys,_=i.bind,j=function(n){return n instanceof j?n:this instanceof j?void(this._wrapped=n):new j(n)};"undefined"!=typeof exports?("undefined"!=typeof module&&module.exports&&(exports=module.exports=j),exports._=j):n._=j,j.VERSION="1.6.0";var A=j.each=j.forEach=function(n,t,e){if(null==n)return n;if(s&&n.forEach===s)n.forEach(t,e);else if(n.length===+n.length){for(var u=0,i=n.length;i>u;u++)if(t.call(e,n[u],u,n)===r)return}else for(var a=j.keys(n),u=0,i=a.length;i>u;u++)if(t.call(e,n[a[u]],a[u],n)===r)return;return n};j.map=j.collect=function(n,t,r){var e=[];return null==n?e:p&&n.map===p?n.map(t,r):(A(n,function(n,u,i){e.push(t.call(r,n,u,i))}),e)};var O="Reduce of empty array with no initial value";j.reduce=j.foldl=j.inject=function(n,t,r,e){var u=arguments.length>2;if(null==n&&(n=[]),h&&n.reduce===h)return e&&(t=j.bind(t,e)),u?n.reduce(t,r):n.reduce(t);if(A(n,function(n,i,a){u?r=t.call(e,r,n,i,a):(r=n,u=!0)}),!u)throw new TypeError(O);return r},j.reduceRight=j.foldr=function(n,t,r,e){var u=arguments.length>2;if(null==n&&(n=[]),v&&n.reduceRight===v)return e&&(t=j.bind(t,e)),u?n.reduceRight(t,r):n.reduceRight(t);var i=n.length;if(i!==+i){var a=j.keys(n);i=a.length}if(A(n,function(o,c,l){c=a?a[--i]:--i,u?r=t.call(e,r,n[c],c,l):(r=n[c],u=!0)}),!u)throw new TypeError(O);return r},j.find=j.detect=function(n,t,r){var e;return k(n,function(n,u,i){return t.call(r,n,u,i)?(e=n,!0):void 0}),e},j.filter=j.select=function(n,t,r){var e=[];return null==n?e:g&&n.filter===g?n.filter(t,r):(A(n,function(n,u,i){t.call(r,n,u,i)&&e.push(n)}),e)},j.reject=function(n,t,r){return j.filter(n,function(n,e,u){return!t.call(r,n,e,u)},r)},j.every=j.all=function(n,t,e){t||(t=j.identity);var u=!0;return null==n?u:d&&n.every===d?n.every(t,e):(A(n,function(n,i,a){return(u=u&&t.call(e,n,i,a))?void 0:r}),!!u)};var k=j.some=j.any=function(n,t,e){t||(t=j.identity);var u=!1;return null==n?u:m&&n.some===m?n.some(t,e):(A(n,function(n,i,a){return u||(u=t.call(e,n,i,a))?r:void 0}),!!u)};j.contains=j.include=function(n,t){return null==n?!1:y&&n.indexOf===y?n.indexOf(t)!=-1:k(n,function(n){return n===t})},j.invoke=function(n,t){var r=o.call(arguments,2),e=j.isFunction(t);return j.map(n,function(n){return(e?t:n[t]).apply(n,r)})},j.pluck=function(n,t){return j.map(n,j.property(t))},j.where=function(n,t){return j.filter(n,j.matches(t))},j.findWhere=function(n,t){return j.find(n,j.matches(t))},j.max=function(n,t,r){if(!t&&j.isArray(n)&&n[0]===+n[0]&&n.length<65535)return Math.max.apply(Math,n);var e=-1/0,u=-1/0;return A(n,function(n,i,a){var o=t?t.call(r,n,i,a):n;o>u&&(e=n,u=o)}),e},j.min=function(n,t,r){if(!t&&j.isArray(n)&&n[0]===+n[0]&&n.length<65535)return Math.min.apply(Math,n);var e=1/0,u=1/0;return A(n,function(n,i,a){var o=t?t.call(r,n,i,a):n;u>o&&(e=n,u=o)}),e},j.shuffle=function(n){var t,r=0,e=[];return A(n,function(n){t=j.random(r++),e[r-1]=e[t],e[t]=n}),e},j.sample=function(n,t,r){return null==t||r?(n.length!==+n.length&&(n=j.values(n)),n[j.random(n.length-1)]):j.shuffle(n).slice(0,Math.max(0,t))};var E=function(n){return null==n?j.identity:j.isFunction(n)?n:j.property(n)};j.sortBy=function(n,t,r){return t=E(t),j.pluck(j.map(n,function(n,e,u){return{value:n,index:e,criteria:t.call(r,n,e,u)}}).sort(function(n,t){var r=n.criteria,e=t.criteria;if(r!==e){if(r>e||r===void 0)return 1;if(e>r||e===void 0)return-1}return n.index-t.index}),"value")};var F=function(n){return function(t,r,e){var u={};return r=E(r),A(t,function(i,a){var o=r.call(e,i,a,t);n(u,o,i)}),u}};j.groupBy=F(function(n,t,r){j.has(n,t)?n[t].push(r):n[t]=[r]}),j.indexBy=F(function(n,t,r){n[t]=r}),j.countBy=F(function(n,t){j.has(n,t)?n[t]++:n[t]=1}),j.sortedIndex=function(n,t,r,e){r=E(r);for(var u=r.call(e,t),i=0,a=n.length;a>i;){var o=i+a>>>1;r.call(e,n[o])t?[]:o.call(n,0,t)},j.initial=function(n,t,r){return o.call(n,0,n.length-(null==t||r?1:t))},j.last=function(n,t,r){return null==n?void 0:null==t||r?n[n.length-1]:o.call(n,Math.max(n.length-t,0))},j.rest=j.tail=j.drop=function(n,t,r){return o.call(n,null==t||r?1:t)},j.compact=function(n){return j.filter(n,j.identity)};var M=function(n,t,r){return t&&j.every(n,j.isArray)?c.apply(r,n):(A(n,function(n){j.isArray(n)||j.isArguments(n)?t?a.apply(r,n):M(n,t,r):r.push(n)}),r)};j.flatten=function(n,t){return M(n,t,[])},j.without=function(n){return j.difference(n,o.call(arguments,1))},j.partition=function(n,t){var r=[],e=[];return A(n,function(n){(t(n)?r:e).push(n)}),[r,e]},j.uniq=j.unique=function(n,t,r,e){j.isFunction(t)&&(e=r,r=t,t=!1);var u=r?j.map(n,r,e):n,i=[],a=[];return A(u,function(r,e){(t?e&&a[a.length-1]===r:j.contains(a,r))||(a.push(r),i.push(n[e]))}),i},j.union=function(){return j.uniq(j.flatten(arguments,!0))},j.intersection=function(n){var t=o.call(arguments,1);return j.filter(j.uniq(n),function(n){return j.every(t,function(t){return j.contains(t,n)})})},j.difference=function(n){var t=c.apply(e,o.call(arguments,1));return j.filter(n,function(n){return!j.contains(t,n)})},j.zip=function(){for(var n=j.max(j.pluck(arguments,"length").concat(0)),t=new Array(n),r=0;n>r;r++)t[r]=j.pluck(arguments,""+r);return t},j.object=function(n,t){if(null==n)return{};for(var r={},e=0,u=n.length;u>e;e++)t?r[n[e]]=t[e]:r[n[e][0]]=n[e][1];return r},j.indexOf=function(n,t,r){if(null==n)return-1;var e=0,u=n.length;if(r){if("number"!=typeof r)return e=j.sortedIndex(n,t),n[e]===t?e:-1;e=0>r?Math.max(0,u+r):r}if(y&&n.indexOf===y)return n.indexOf(t,r);for(;u>e;e++)if(n[e]===t)return e;return-1},j.lastIndexOf=function(n,t,r){if(null==n)return-1;var e=null!=r;if(b&&n.lastIndexOf===b)return e?n.lastIndexOf(t,r):n.lastIndexOf(t);for(var u=e?r:n.length;u--;)if(n[u]===t)return u;return-1},j.range=function(n,t,r){arguments.length<=1&&(t=n||0,n=0),r=arguments[2]||1;for(var e=Math.max(Math.ceil((t-n)/r),0),u=0,i=new Array(e);e>u;)i[u++]=n,n+=r;return i};var R=function(){};j.bind=function(n,t){var r,e;if(_&&n.bind===_)return _.apply(n,o.call(arguments,1));if(!j.isFunction(n))throw new TypeError;return r=o.call(arguments,2),e=function(){if(!(this instanceof e))return n.apply(t,r.concat(o.call(arguments)));R.prototype=n.prototype;var u=new R;R.prototype=null;var i=n.apply(u,r.concat(o.call(arguments)));return Object(i)===i?i:u}},j.partial=function(n){var t=o.call(arguments,1);return function(){for(var r=0,e=t.slice(),u=0,i=e.length;i>u;u++)e[u]===j&&(e[u]=arguments[r++]);for(;r=f?(clearTimeout(a),a=null,o=l,i=n.apply(e,u),e=u=null):a||r.trailing===!1||(a=setTimeout(c,f)),i}},j.debounce=function(n,t,r){var e,u,i,a,o,c=function(){var l=j.now()-a;t>l?e=setTimeout(c,t-l):(e=null,r||(o=n.apply(i,u),i=u=null))};return function(){i=this,u=arguments,a=j.now();var l=r&&!e;return e||(e=setTimeout(c,t)),l&&(o=n.apply(i,u),i=u=null),o}},j.once=function(n){var t,r=!1;return function(){return r?t:(r=!0,t=n.apply(this,arguments),n=null,t)}},j.wrap=function(n,t){return j.partial(t,n)},j.compose=function(){var n=arguments;return function(){for(var t=arguments,r=n.length-1;r>=0;r--)t=[n[r].apply(this,t)];return t[0]}},j.after=function(n,t){return function(){return--n<1?t.apply(this,arguments):void 0}},j.keys=function(n){if(!j.isObject(n))return[];if(w)return w(n);var t=[];for(var r in n)j.has(n,r)&&t.push(r);return t},j.values=function(n){for(var t=j.keys(n),r=t.length,e=new Array(r),u=0;r>u;u++)e[u]=n[t[u]];return e},j.pairs=function(n){for(var t=j.keys(n),r=t.length,e=new Array(r),u=0;r>u;u++)e[u]=[t[u],n[t[u]]];return e},j.invert=function(n){for(var t={},r=j.keys(n),e=0,u=r.length;u>e;e++)t[n[r[e]]]=r[e];return t},j.functions=j.methods=function(n){var t=[];for(var r in n)j.isFunction(n[r])&&t.push(r);return t.sort()},j.extend=function(n){return A(o.call(arguments,1),function(t){if(t)for(var r in t)n[r]=t[r]}),n},j.pick=function(n){var t={},r=c.apply(e,o.call(arguments,1));return A(r,function(r){r in n&&(t[r]=n[r])}),t},j.omit=function(n){var t={},r=c.apply(e,o.call(arguments,1));for(var u in n)j.contains(r,u)||(t[u]=n[u]);return t},j.defaults=function(n){return A(o.call(arguments,1),function(t){if(t)for(var r in t)n[r]===void 0&&(n[r]=t[r])}),n},j.clone=function(n){return j.isObject(n)?j.isArray(n)?n.slice():j.extend({},n):n},j.tap=function(n,t){return t(n),n};var S=function(n,t,r,e){if(n===t)return 0!==n||1/n==1/t;if(null==n||null==t)return n===t;n instanceof j&&(n=n._wrapped),t instanceof j&&(t=t._wrapped);var u=l.call(n);if(u!=l.call(t))return!1;switch(u){case"[object String]":return n==String(t);case"[object Number]":return n!=+n?t!=+t:0==n?1/n==1/t:n==+t;case"[object Date]":case"[object Boolean]":return+n==+t;case"[object RegExp]":return n.source==t.source&&n.global==t.global&&n.multiline==t.multiline&&n.ignoreCase==t.ignoreCase}if("object"!=typeof n||"object"!=typeof t)return!1;for(var i=r.length;i--;)if(r[i]==n)return e[i]==t;var a=n.constructor,o=t.constructor;if(a!==o&&!(j.isFunction(a)&&a instanceof a&&j.isFunction(o)&&o instanceof o)&&"constructor"in n&&"constructor"in t)return!1;r.push(n),e.push(t);var c=0,f=!0;if("[object Array]"==u){if(c=n.length,f=c==t.length)for(;c--&&(f=S(n[c],t[c],r,e)););}else{for(var s in n)if(j.has(n,s)&&(c++,!(f=j.has(t,s)&&S(n[s],t[s],r,e))))break;if(f){for(s in t)if(j.has(t,s)&&!c--)break;f=!c}}return r.pop(),e.pop(),f};j.isEqual=function(n,t){return S(n,t,[],[])},j.isEmpty=function(n){if(null==n)return!0;if(j.isArray(n)||j.isString(n))return 0===n.length;for(var t in n)if(j.has(n,t))return!1;return!0},j.isElement=function(n){return!(!n||1!==n.nodeType)},j.isArray=x||function(n){return"[object Array]"==l.call(n)},j.isObject=function(n){return n===Object(n)},A(["Arguments","Function","String","Number","Date","RegExp"],function(n){j["is"+n]=function(t){return l.call(t)=="[object "+n+"]"}}),j.isArguments(arguments)||(j.isArguments=function(n){return!(!n||!j.has(n,"callee"))}),"function"!=typeof/./&&(j.isFunction=function(n){return"function"==typeof n}),j.isFinite=function(n){return isFinite(n)&&!isNaN(parseFloat(n))},j.isNaN=function(n){return j.isNumber(n)&&n!=+n},j.isBoolean=function(n){return n===!0||n===!1||"[object Boolean]"==l.call(n)},j.isNull=function(n){return null===n},j.isUndefined=function(n){return n===void 0},j.has=function(n,t){return f.call(n,t)},j.noConflict=function(){return n._=t,this},j.identity=function(n){return n},j.constant=function(n){return function(){return n}},j.property=function(n){return function(t){return t[n]}},j.matches=function(n){return function(t){if(t===n)return!0;for(var r in n)if(n[r]!==t[r])return!1;return!0}},j.times=function(n,t,r){for(var e=Array(Math.max(0,n)),u=0;n>u;u++)e[u]=t.call(r,u);return e},j.random=function(n,t){return null==t&&(t=n,n=0),n+Math.floor(Math.random()*(t-n+1))},j.now=Date.now||function(){return(new Date).getTime()};var T={escape:{"&":"&","<":"<",">":">",'"':""","'":"'"}};T.unescape=j.invert(T.escape);var I={escape:new RegExp("["+j.keys(T.escape).join("")+"]","g"),unescape:new RegExp("("+j.keys(T.unescape).join("|")+")","g")};j.each(["escape","unescape"],function(n){j[n]=function(t){return null==t?"":(""+t).replace(I[n],function(t){return T[n][t]})}}),j.result=function(n,t){if(null==n)return void 0;var r=n[t];return j.isFunction(r)?r.call(n):r},j.mixin=function(n){A(j.functions(n),function(t){var r=j[t]=n[t];j.prototype[t]=function(){var n=[this._wrapped];return a.apply(n,arguments),z.call(this,r.apply(j,n))}})};var N=0;j.uniqueId=function(n){var t=++N+"";return n?n+t:t},j.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var q=/(.)^/,B={"'":"'","\\":"\\","\r":"r","\n":"n"," ":"t","\u2028":"u2028","\u2029":"u2029"},D=/\\|'|\r|\n|\t|\u2028|\u2029/g;j.template=function(n,t,r){var e;r=j.defaults({},r,j.templateSettings);var u=new RegExp([(r.escape||q).source,(r.interpolate||q).source,(r.evaluate||q).source].join("|")+"|$","g"),i=0,a="__p+='";n.replace(u,function(t,r,e,u,o){return a+=n.slice(i,o).replace(D,function(n){return"\\"+B[n]}),r&&(a+="'+\n((__t=("+r+"))==null?'':_.escape(__t))+\n'"),e&&(a+="'+\n((__t=("+e+"))==null?'':__t)+\n'"),u&&(a+="';\n"+u+"\n__p+='"),i=o+t.length,t}),a+="';\n",r.variable||(a="with(obj||{}){\n"+a+"}\n"),a="var __t,__p='',__j=Array.prototype.join,"+"print=function(){__p+=__j.call(arguments,'');};\n"+a+"return __p;\n";try{e=new Function(r.variable||"obj","_",a)}catch(o){throw o.source=a,o}if(t)return e(t,j);var c=function(n){return e.call(this,n,j)};return c.source="function("+(r.variable||"obj")+"){\n"+a+"}",c},j.chain=function(n){return j(n).chain()};var z=function(n){return this._chain?j(n).chain():n};j.mixin(j),A(["pop","push","reverse","shift","sort","splice","unshift"],function(n){var t=e[n];j.prototype[n]=function(){var r=this._wrapped;return t.apply(r,arguments),"shift"!=n&&"splice"!=n||0!==r.length||delete r[0],z.call(this,r)}}),A(["concat","join","slice"],function(n){var t=e[n];j.prototype[n]=function(){return z.call(this,t.apply(this._wrapped,arguments))}}),j.extend(j.prototype,{chain:function(){return this._chain=!0,this},value:function(){return this._wrapped}}),"function"==typeof define&&define.amd&&define("underscore",[],function(){return j})}).call(this); -//# sourceMappingURL=underscore-min.map \ No newline at end of file From c0b61a2a5db2cf8277e4c77ef89681b46eeaf0eb Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Sat, 9 May 2015 04:55:40 -0300 Subject: [PATCH 04/14] adding error stack information to error reporter --- wise-editor/src/main/webapp/js/editor.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wise-editor/src/main/webapp/js/editor.js b/wise-editor/src/main/webapp/js/editor.js index 886770e6..9bb7399d 100644 --- a/wise-editor/src/main/webapp/js/editor.js +++ b/wise-editor/src/main/webapp/js/editor.js @@ -78,7 +78,7 @@ function buildDesigner(options) { headers: {"Content-Type": "application/json", "Accept": "application/json"}, data: JSON.stringify({ jsErrorMsg: "Message: '" + errorMsg + "', line:'" + lineNo + "', url: :" + url, - jsStack: window.errorStack, + jsStack: window.event.errorStack || window.errorStack, userAgent: navigator.userAgent, mapId: options.mapId }) From 6e762880935c83ccf15ad62d569e724531c46007 Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Sat, 9 May 2015 11:01:22 -0300 Subject: [PATCH 05/14] Initial version of Dockerfile generation. --- distribution/Dockerfile | 45 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 distribution/Dockerfile diff --git a/distribution/Dockerfile b/distribution/Dockerfile new file mode 100644 index 00000000..bf83836e --- /dev/null +++ b/distribution/Dockerfile @@ -0,0 +1,45 @@ +# Dockerizing WiseMapping: Dockerfile for building WiseMapping images +# Based on ubuntu:latest, installs WiseMapping (http://ww.wisemapping.org) + +FROM ubuntu:latest +MAINTAINER Paulo Gustavo Veiga + +ENV DEBIAN_FRONTEND noninteractive +ENV MYSQL_ROOT_PASSWORD password +ENV WISE_VERSION 4.0.1 + +# Install utilities +RUN apt-get install -y zip + +# Prepare distribution +COPY target/wisemapping-v${WISE_VERSION}.zip . +RUN unzip wisemapping-v${WISE_VERSION}.zip + +# Install MySQL +RUN echo mysql-server mysql-server/root_password password ${MYSQL_ROOT_PASSWORD} | debconf-set-selections;\ + echo mysql-server mysql-server/root_password_again password ${MYSQL_ROOT_PASSWORD} | debconf-set-selections;\ + apt-get install -y mysql-server + +RUN service mysql start && \ + mysql -uroot -p${MYSQL_ROOT_PASSWORD} < /wisemapping-v${WISE_VERSION}/config/database/mysql/create-database.sql && \ + mysql -uwisemapping -Dwisemapping -ppassword < /wisemapping-v${WISE_VERSION}/config/database/mysql/create-schemas.sql && \ + mysql -uwisemapping -Dwisemapping -ppassword < /wisemapping-v${WISE_VERSION}/config/database/mysql/apopulate-schemas.sql + +# Install Java 8 +RUN apt-get install -y software-properties-common && \ + add-apt-repository ppa:webupd8team/java && \ + apt-get update + +RUN echo oracle-java8-installer shared/accepted-oracle-license-v1-1 select true | debconf-set-selections;\ + echo oracle-java8-installer shared/accepted-oracle-license-v1-1 seen true | debconf-set-selections;\ + sudo apt-get install -y oracle-java8-installer + +# Clean up +RUN apt-get clean +RUN rm wisemapping-v${WISE_VERSION}.zip + + +EXPOSE 8080 + +CMD "echo" "Starting WiseMapping ${WISE_VERSION}" +CMD “cd wisemapping-v${WISE_VERSION};./start.sh” From 2a9fa3f9781ad4aa5c2a2ee65c502d010747d362 Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Sat, 9 May 2015 12:08:53 -0300 Subject: [PATCH 06/14] Finish Docker implementation. --- distribution/Dockerfile | 6 +- distribution/docker-conf/app.properties | 147 ++++++++++++++++++++++++ 2 files changed, 151 insertions(+), 2 deletions(-) create mode 100644 distribution/docker-conf/app.properties diff --git a/distribution/Dockerfile b/distribution/Dockerfile index bf83836e..502ca2d2 100644 --- a/distribution/Dockerfile +++ b/distribution/Dockerfile @@ -34,6 +34,9 @@ RUN echo oracle-java8-installer shared/accepted-oracle-license-v1-1 select true echo oracle-java8-installer shared/accepted-oracle-license-v1-1 seen true | debconf-set-selections;\ sudo apt-get install -y oracle-java8-installer +# Configure instance +COPY docker-conf/app.properties wisemapping-v4.0.1/webapps/wisemapping/WEB-INF/app.properties + # Clean up RUN apt-get clean RUN rm wisemapping-v${WISE_VERSION}.zip @@ -41,5 +44,4 @@ RUN rm wisemapping-v${WISE_VERSION}.zip EXPOSE 8080 -CMD "echo" "Starting WiseMapping ${WISE_VERSION}" -CMD “cd wisemapping-v${WISE_VERSION};./start.sh” +CMD "sh" "-c" "service mysql start;cd wisemapping-v${WISE_VERSION};./start.sh" diff --git a/distribution/docker-conf/app.properties b/distribution/docker-conf/app.properties new file mode 100644 index 00000000..8928c4b0 --- /dev/null +++ b/distribution/docker-conf/app.properties @@ -0,0 +1,147 @@ +################################################################################## +# Database Configuration +################################################################################## + +# MySQL 5.X configuration properties +database.url=jdbc:mysql://localhost/wisemapping?useUnicode=yes&characterEncoding=UTF-8 +database.driver=com.mysql.jdbc.Driver +database.hibernate.dialect=org.hibernate.dialect.MySQL5Dialect +database.username=wisemapping +database.password=password +database.validation.enabled=true +database.validation.query=SELECT 1 + +## PostgreSQL configuration properties +#database.url=jdbc:postgresql:///wisemapping +#database.driver=org.postgresql.Driver +#database.hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect +#database.username= +#database.password= +#database.validation.enabled=true +#database.validation.query= +#database.validation.enabled=false + +################################################################################## +# Mail configuration. Must be configured to enable user registration confirmation. +################################################################################## + +#------------------------ +# Plain SMTP Server Configuration +#------------------------ +mail.smtp.port=25 +mail.smtp.host=localhost +mail.username=root +mail.password= +mail.smtp.auth=false +mail.smtp.starttls.enable=false +mail.smtp.quitwait=false + +#------------------------ +# GMAIL SMTP Configuration +#------------------------ +#mail.smtp.port=587 +#mail.smtp.host=smtp.gmail.com +#mail.username= +#mail.password= +#mail.smtp.auth=true +#mail.smtp.starttls.enable=true +#mail.smtp.quitwait=false + +#------------------------ +# Emails configuration +#------------------------ + +# Required: "from" email account that will appear in the emails sent from the sender. +mail.serverSendEmail=root@localhost + +# Optional: Support account that the users could use to contact you. This address will appear in emails and in some places in the site. +mail.supportEmail=root@localhost + +# Optional: Unexpected errors will be reported to this address. +mail.errorReporterEmail= + +################################################################################## +# Users Registration Configuration +################################################################################## + +# Enable captcha confirmation +google.recaptcha.enabled = true + +# ReCaptcha is the default captcha. Public and private keys are required. +# More Info: http://www.google.com/recaptcha . +google.recaptcha.privateKey = 6LeQ4tISAAAAAMfHMPRKyHupTfA-KE4QeTCnLXhK +google.recaptcha.publicKey = 6LeQ4tISAAAAALzCGKNgRv8UqsDx7Cb0vq4wbJBr + +################################################################################## +# Site configuration +################################################################################## + +# Site administration user. This user will have special permissions for operations such as removing users, set password +# etc. +admin.user = admin@wisemapping.org + +# Base URL where WiseMapping is deployed. By default, It will be automatically inferred. +# If you are planning to put wisemapping behind an Apache using an Apache Proxy setup, you must enable this property. +#site.baseurl = http://example.com:8080/wisemapping + + +# Site Homepage URL. This will be used as URL for homepage location. +site.homepage = c/home + +################################################################################## +# Google Analytics Settings +################################################################################## +google.analytics.enabled=false +google.analytics.account=UA-XXXX + +################################################################################## +# Google Ads enable +################################################################################## +google.ads.enabled=false + +####################################################################################### +# Authentication Configuration Section +####################################################################################### + +# Two type of security are supported: +# - db: User are stored in the database. Registration is required in advance. +# - ldap: Authentication takes place using a LDAP. In this case, security.ldap.* must be configured. +security.type=db + +# LDAP Configuration properties. +security.ldap.server=ldap://localhost:389 + +# If anonymous password is required, change the wisemapping-security-ldap.xml removing the +security.ldap.server.user=cn=pveiga,dc=wisemapping,dc=com +security.ldap.server.password=password + +security.ldap.basedn=dc=wisemapping,dc=com + + +# This will be concatenated as part of the DN. In this case, I will be "ou=people". +# In case this need to be changed, modify the wisemapping-security-ldap.xml. +security.ldap.subDn=ou=people + +# Attribute used as authentication login (Eg: in this case, the user email will be used) +security.ldap.auth.attribute=mail + +security.ldap.lastName.attribute=sn +security.ldap.firstName.attribute=givenName + +# Enable OpenId Authentication. +security.openid.enabled=false + +# REST Documentation +# +# This properties are used for REST API Documentation( http://localhost:8080/wisemapping/doc/rest/index.html) +# Change the URL for proper documentation console setup. +documentation.services.basePath=http://localhost:8080/wisemapping/service +documentation.services.version=3.0.1 + + + + + + + + From 1320bb737c7972971ca7e51de8a2cee1fd0b8acf Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Sat, 9 May 2015 12:10:39 -0300 Subject: [PATCH 07/14] Update lattest version. --- distribution/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/distribution/Dockerfile b/distribution/Dockerfile index 502ca2d2..15d3e9cb 100644 --- a/distribution/Dockerfile +++ b/distribution/Dockerfile @@ -6,7 +6,7 @@ MAINTAINER Paulo Gustavo Veiga ENV DEBIAN_FRONTEND noninteractive ENV MYSQL_ROOT_PASSWORD password -ENV WISE_VERSION 4.0.1 +ENV WISE_VERSION 4.0.2 # Install utilities RUN apt-get install -y zip From c6c825fedc0d83bc50e19fc1eb38e70f088fdb9c Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Sat, 9 May 2015 17:28:59 -0300 Subject: [PATCH 08/14] fix error stack not reporting to autolog --- wise-editor/src/main/webapp/js/editor.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wise-editor/src/main/webapp/js/editor.js b/wise-editor/src/main/webapp/js/editor.js index 9bb7399d..c84e3056 100644 --- a/wise-editor/src/main/webapp/js/editor.js +++ b/wise-editor/src/main/webapp/js/editor.js @@ -78,7 +78,7 @@ function buildDesigner(options) { headers: {"Content-Type": "application/json", "Accept": "application/json"}, data: JSON.stringify({ jsErrorMsg: "Message: '" + errorMsg + "', line:'" + lineNo + "', url: :" + url, - jsStack: window.event.errorStack || window.errorStack, + jsStack: window.event.error.stack || window.errorStack, userAgent: navigator.userAgent, mapId: options.mapId }) From 0633bb589eed7b0f375a35388a04f6ea995f8635 Mon Sep 17 00:00:00 2001 From: Mariela Michalek Date: Sun, 31 May 2015 11:12:27 -0300 Subject: [PATCH 09/14] fix focus link editor --- mindplot/src/main/javascript/widget/LinkEditor.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mindplot/src/main/javascript/widget/LinkEditor.js b/mindplot/src/main/javascript/widget/LinkEditor.js index f1568929..4e363f84 100644 --- a/mindplot/src/main/javascript/widget/LinkEditor.js +++ b/mindplot/src/main/javascript/widget/LinkEditor.js @@ -63,6 +63,9 @@ mindplot.widget.LinkEditor = new Class(/** @lends LinkEditor */{ 'autofocus': 'autofocus', 'class': 'form-control' }); + input.on("keypress", function(event) { + event.stopPropagation(); + }); if (model.getValue() != null){ input.val(model.getValue()); From 0cc08b34cf7a8fea4b3010c7563717b3820f7063 Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Sat, 4 Jul 2015 11:02:48 -0300 Subject: [PATCH 10/14] Move to Java 1.8. --- pom.xml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pom.xml b/pom.xml index 6c703824..63eeccd4 100644 --- a/pom.xml +++ b/pom.xml @@ -1,5 +1,5 @@ - @@ -119,8 +119,8 @@ maven-compiler-plugin 3.1 - 1.7 - 1.7 + 1.8 + 1.8 UTF-8 From 7e440fb9dec991a592d24c28924d4b5690796bfb Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Wed, 26 Aug 2015 23:37:49 -0300 Subject: [PATCH 11/14] firefox 40+ support --- .../src/main/java/com/wisemapping/filter/SupportedUserAgent.java | 1 + 1 file changed, 1 insertion(+) diff --git a/wise-webapp/src/main/java/com/wisemapping/filter/SupportedUserAgent.java b/wise-webapp/src/main/java/com/wisemapping/filter/SupportedUserAgent.java index 9b1d64bd..3b51eee1 100644 --- a/wise-webapp/src/main/java/com/wisemapping/filter/SupportedUserAgent.java +++ b/wise-webapp/src/main/java/com/wisemapping/filter/SupportedUserAgent.java @@ -48,6 +48,7 @@ public class SupportedUserAgent implements Serializable { boolean result = browser == Browser.FIREFOX && majorVersion >= 10; result = result || browser == Browser.FIREFOX2 && majorVersion >= 17; result = result || browser == Browser.FIREFOX3 && majorVersion >= 29; + result = result || browser == Browser.FIREFOX4 && majorVersion >= 40; result = result || browser == Browser.IE8 || browser == Browser.IE9 || browser == Browser.IE11 ; result = result || browser == Browser.IE && majorVersion >= 8; result = result || browser == Browser.OPERA10 && majorVersion >= 11; From 070815c95ce5e1f8db401650d56620ca0179c2f4 Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Wed, 26 Aug 2015 23:38:41 -0300 Subject: [PATCH 12/14] fix api rest for get user by email, email was trimmed --- .../src/main/java/com/wisemapping/rest/AdminController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wise-webapp/src/main/java/com/wisemapping/rest/AdminController.java b/wise-webapp/src/main/java/com/wisemapping/rest/AdminController.java index 6290026d..b2df9709 100644 --- a/wise-webapp/src/main/java/com/wisemapping/rest/AdminController.java +++ b/wise-webapp/src/main/java/com/wisemapping/rest/AdminController.java @@ -72,7 +72,7 @@ public class AdminController extends BaseController { } @ApiOperation("Note: Administration permissions required.") - @RequestMapping(method = RequestMethod.GET, value = "admin/users/email/{email}", produces = {"application/json", "application/xml"}) + @RequestMapping(method = RequestMethod.GET, value = "admin/users/email/{email:.+}", produces = {"application/json", "application/xml"}) @ResponseBody public RestUser getUserByEmail(@PathVariable String email) throws IOException { final User user = userService.getUserBy(email); From f20b4d63d1a9440d1af59ff82e4faa9cf348f1ec Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Sat, 29 Aug 2015 02:14:49 -0300 Subject: [PATCH 13/14] rest user has not password set for rest api --- .../src/main/java/com/wisemapping/rest/model/RestUser.java | 1 + 1 file changed, 1 insertion(+) diff --git a/wise-webapp/src/main/java/com/wisemapping/rest/model/RestUser.java b/wise-webapp/src/main/java/com/wisemapping/rest/model/RestUser.java index 2e86f3f4..df4c7600 100644 --- a/wise-webapp/src/main/java/com/wisemapping/rest/model/RestUser.java +++ b/wise-webapp/src/main/java/com/wisemapping/rest/model/RestUser.java @@ -51,6 +51,7 @@ public class RestUser { public RestUser(@NotNull User user) { this.user = user; + this.password = user.getPassword(); } public Calendar getCreationDate() { From a51846e536be6328b9c1d8c3df2272f146963171 Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Thu, 29 Oct 2015 22:31:40 -0300 Subject: [PATCH 14/14] zoom factor decreased, fixing some js errors due to legacy code --- mindplot/src/main/javascript/Designer.js | 26 +++---------------- .../src/main/webapp/jsp/mindmapEmbed.jsp | 8 ------ .../src/main/webapp/jsp/mindmapPrint.jsp | 8 ------ 3 files changed, 4 insertions(+), 38 deletions(-) diff --git a/mindplot/src/main/javascript/Designer.js b/mindplot/src/main/javascript/Designer.js index 8b7c4368..ea9b2e14 100644 --- a/mindplot/src/main/javascript/Designer.js +++ b/mindplot/src/main/javascript/Designer.js @@ -82,32 +82,14 @@ mindplot.Designer = new Class(/** @lends Designer */{ * @private */ _registerWheelEvents: function () { - var workspace = this._workspace; + var zoomFactor = 1.006; var me = this; // Zoom In and Zoom Out must active event $(document).on('mousewheel', function (event) { - // Change mousewheel handling so we let the default - // event happen if we are outside the container. -> FIXME: it still happening? - /*var coords = screenManager.getContainer().getCoordinates(); - var isOutsideContainer = event.client.y < coords.top || - event.client.y > coords.bottom || - event.client.x < coords.left || - event.client.x > coords.right; - - if (!isOutsideContainer) { - if (event.wheel > 0) { - this.zoomIn(1.05); - } - else { - this.zoomOut(1.05); - } - event.preventDefault(); - }*/ if (event.deltaY > 0) { - me.zoomIn(1.05); - } - else { - me.zoomOut(1.05); + me.zoomIn(zoomFactor); + } else { + me.zoomOut(zoomFactor); } event.preventDefault(); }); diff --git a/wise-webapp/src/main/webapp/jsp/mindmapEmbed.jsp b/wise-webapp/src/main/webapp/jsp/mindmapEmbed.jsp index cf0b94a4..503327ae 100644 --- a/wise-webapp/src/main/webapp/jsp/mindmapEmbed.jsp +++ b/wise-webapp/src/main/webapp/jsp/mindmapEmbed.jsp @@ -58,14 +58,6 @@ var persistence = mindplot.PersistenceManager.getInstance(); var mindmap = mindmap = persistence.load(mapId); designer.loadMap(mindmap); - - $('zoomIn').addEvent('click', function () { - designer.zoomIn(); - }); - - $('zoomOut').addEvent('click', function () { - designer.zoomOut(); - }); }); diff --git a/wise-webapp/src/main/webapp/jsp/mindmapPrint.jsp b/wise-webapp/src/main/webapp/jsp/mindmapPrint.jsp index c8e8cc19..f80a8f13 100644 --- a/wise-webapp/src/main/webapp/jsp/mindmapPrint.jsp +++ b/wise-webapp/src/main/webapp/jsp/mindmapPrint.jsp @@ -90,14 +90,6 @@ var persistence = mindplot.PersistenceManager.getInstance(); var mindmap = mindmap = persistence.load(mapId); designer.loadMap(mindmap); - - $('zoomIn').addEvent('click', function () { - designer.zoomIn(); - }); - - $('zoomOut').addEvent('click', function () { - designer.zoomOut(); - }); });