Skip to content

Instantly share code, notes, and snippets.

2021-03-22T18:47:40,664 | ERROR | features-3-thread-1 | WebApplication | 203 - org.ops4j.pax.web.pax-web-extender-whiteboard - 7.2.23 | Registration skipped for [ServletWebElement{mapping=DefaultServletMapping{httpContextId=ukelonn,urlPatterns=[/api/*],initParams={jersey.config.server.provider.packages=no.priv.bang.ukelonn.api.resources},servlet=no.priv.bang.ukelonn.api.UkelonnRestApiServlet@5a0c24c9, alias=null, servletNameukelonnapi}}] due to error during registration
javax.servlet.ServletException: servlet already registered with a different alias
at org.ops4j.pax.web.service.spi.model.ServerModel.addServletModel(ServerModel.java:119) ~[?:?]
at org.ops4j.pax.web.service.internal.HttpServiceStarted.registerServlet(HttpServiceStarted.java:246) ~[?:?]
at org.ops4j.pax.web.service.internal.HttpServiceStarted.registerServlet(HttpServiceStarted.java:395) ~[?:?]
at org.ops4j.pax.web.service.internal.HttpServiceProxy.registerServlet(HttpServiceProxy.java:504) ~[?:?]
at org.ops4j.pax.web.exte
@steinarb
steinarb / emacs_desktop_load.profile
Created January 28, 2021 17:37
Emacs profiler capture from starting up from a .emacs.desktop file (maven projects managed by projectile)
[profiler-profile "24.3" cpu #s(hash-table size 1095 test equal rehash-size 1.5 rehash-threshold 0.8125 data ([emacs-lisp-mode lisp-interaction-mode command-line normal-top-level nil nil nil nil nil nil nil nil nil nil nil nil] 4 [require byte-code desktop-read progn eval command-line-1 command-line normal-top-level nil nil nil nil nil nil nil nil] 4 [require byte-code autoload-do-load desktop-load-file desktop-create-buffer eval-buffer load-with-code-conversion load desktop-read progn eval command-line-1 command-line normal-top-level nil nil] 36 [byte-code autoload-do-load desktop-load-file desktop-create-buffer eval-buffer load-with-code-conversion load desktop-read progn eval command-line-1 command-line normal-top-level nil nil nil] 15 [byte-code require byte-code autoload-do-load desktop-load-file desktop-create-buffer eval-buffer load-with-code-conversion load desktop-read progn eval command-line-1 command-line normal-top-level nil] 24 [require byte-code require byte-code autoload-do-load desktop-load-f
@steinarb
steinarb / docker_logs_429
Created September 9, 2020 20:32
docker logs from starting oldalbum on karaf 4.2.9
sb@lorenzo:~/workspaces/ws06/oldalbum/docker$ docker logs d56ade30de95
karaf: Ignoring predefined value for KARAF_HOME
Sep 09, 2020 8:29:50 PM org.apache.karaf.main.Main launch
INFO: Installing and starting initial bundles
Sep 09, 2020 8:29:50 PM org.apache.karaf.main.Main launch
INFO: All initial bundles installed and set to start
Sep 09, 2020 8:29:50 PM org.apache.karaf.main.lock.SimpleFileLock lock
INFO: Trying to lock /opt/apache-karaf-4.2.9/lock
Sep 09, 2020 8:29:50 PM org.apache.karaf.main.lock.SimpleFileLock lock
INFO: Lock acquired
@steinarb
steinarb / docker_logs
Created September 9, 2020 20:26
docker logs from starting oldalbum on karaf 4.2.8
sb@lorenzo:~/workspaces/ws06/oldalbum/docker$ docker logs 2b155a0f01e2
karaf: Ignoring predefined value for KARAF_HOME
Sep 09, 2020 8:20:10 PM org.apache.karaf.main.Main launch
INFO: Installing and starting initial bundles
Sep 09, 2020 8:20:10 PM org.apache.karaf.main.Main launch
INFO: All initial bundles installed and set to start
Sep 09, 2020 8:20:10 PM org.apache.karaf.main.lock.SimpleFileLock lock
INFO: Trying to lock /opt/apache-karaf-4.2.8/lock
Sep 09, 2020 8:20:10 PM org.apache.karaf.main.lock.SimpleFileLock lock
INFO: Lock acquired
@steinarb
steinarb / emptyalbum.sql
Created September 8, 2020 19:59
Oldalbum database containing just the root album
--liquibase formatted sql
--changeset sb:empty_album
insert into albumentries (albumentry_id, parent, localpath, album, title, description, imageurl, thumbnailurl, sort, lastmodified, contenttype, contentlength) values (1, 0, '/', true, 'Pictures from the past', 'Old images 90, served up in a mobile friendly responsive layout and with OpenGraph-tags and twitter cards', '', '', 0, null, null, 0);
ALTER TABLE albumentries ALTER COLUMN albumentry_id RESTART WITH 2
@steinarb
steinarb / dumproutes.sql
Last active September 14, 2020 15:31
oldalbum demo database
--liquibase formatted sql
--changeset sb:saved_albumentries
insert into albumentries (albumentry_id, parent, localpath, album, title, description, imageurl, thumbnailurl, sort, lastmodified, contenttype, contentlength) values (1, 0, '/', true, 'Bilder fra 90-tallet', 'Gamle bilder fra 90-tallet, servert mobilvennlig (responsive layout) med OpenGraph-tagger og twitter cards', '', '', 0, null, null, 0);
insert into albumentries (albumentry_id, parent, localpath, album, title, description, imageurl, thumbnailurl, sort, lastmodified, contenttype, contentlength) values (2, 1, '/misc/', true, 'Miscellaneous unsorted pictures', 'Contains a lot of pictures, most of marginal interest, which will be thrown away or transferred to other directories in time', null, null, 1, null, null, 0);
insert into albumentries (albumentry_id, parent, localpath, album, title, description, imageurl, thumbnailurl, sort, lastmodified, contenttype, contentlength) values (3, 1, '/moto/', true, 'Motorcycle pictures', 'Here are some of my mot
@steinarb
steinarb / MANIFEST.MF
Created July 26, 2020 08:14
MANIFEST.MF of liquibase-core 3.10.1
Manifest-Version: 1.0
Liquibase-Package: liquibase.change,liquibase.command,liquibase.change
log,liquibase.database,liquibase.parser,liquibase.precondition,liquib
ase.datatype,liquibase.serializer,liquibase.sqlgenerator,liquibase.ex
ecutor,liquibase.snapshot,liquibase.logging,liquibase.diff,liquibase.
structure,liquibase.structurecompare,liquibase.lockservice,liquibase.
sdk.database,liquibase.ext,liquibase.pro,com.datical.liquibase
Bundle-License: http://www.apache.org/licenses/LICENSE-2.0
Bundle-SymbolicName: org.liquibase.core
Build-Number: 17
@steinarb
steinarb / feature.xml
Created July 26, 2020 08:01
Feature repository for liquibase sample application
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<features xmlns="http://karaf.apache.org/xmlns/features/v1.6.0" name="handlereg.db.liquibase.test">
<repository>mvn:no.priv.bang.karaf/liquibase-core-karaf/3.8.1-SNAPSHOT/xml/features</repository>
<feature name="liquibase-sample-hook" description="Sample bundle for liquibase" version="1.0.0.SNAPSHOT">
<feature>scr</feature>
<feature>pax-jdbc-derby</feature>
<feature version="3.10.1" prerequisite="false" dependency="false">liquibase-core</feature>
<bundle start-level="80">mvn:no.priv.bang.karaf.liquibase/liquibase.sample/1.0.0-SNAPSHOT</bundle>
</feature>
<feature name="liquibase-sample" description="liquibase-sample DataSource" version="1.0.0.SNAPSHOT">
@steinarb
steinarb / feature.xml
Created July 26, 2020 07:57
Feature repository for liquibase 3.10.1
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<features xmlns="http://karaf.apache.org/xmlns/features/v1.6.0" name="ukelonn.bundle.db.liquibase">
<feature name="liquibase-core" start-level="40" version="3.10.1">
<bundle>mvn:org.yaml/snakeyaml/1.24</bundle>
<bundle>mvn:org.liquibase/liquibase-core/3.10.1</bundle>
<bundle start-level="35">mvn:no.priv.bang.karaf/liquibase-slf4j-osgi/3.8.1-SNAPSHOT</bundle>
<bundle start-level="30">mvn:org.apache.servicemix.specs/org.apache.servicemix.specs.activation-api-1.1/2.9.0</bundle>
</feature>
</features>
@steinarb
steinarb / karaf.log
Created July 25, 2020 14:07
karaf.log message when liquibase is unable to load javax.activation.DataSource
2020-07-25T12:13:49,797 | ERROR | features-3-thread-1 | Felix | 5 - org.ops4j.pax.logging.pax-logging-api - 1.11.4 | Bundle org.ops4j.pax.jdbc.config [57] EventDispatcher: Error during dispatch. (java.lang.NoClassDefFoundError: javax/activation/DataSource)
java.lang.NoClassDefFoundError: javax/activation/DataSource
at java.lang.ClassLoader.defineClass1(Native Method) ~[?:?]
at java.lang.ClassLoader.defineClass(ClassLoader.java:1017) ~[?:?]
at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.defineClass(BundleWiringImpl.java:2410) ~[?:?]
at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.findClass(BundleWiringImpl.java:2194) ~[?:?]
at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1607) ~[?:?]
at org.apache.felix.framework.BundleWiringImpl.access$200(BundleWiringImpl.java:80) ~[?:?]
at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:2053) ~[?:?]
at java.