This file contains hidden or 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
| @Component | |
| class SomeTransactionalService( | |
| private val someDao: SomeDao | |
| ) { | |
| fun handle(parameter: String) { | |
| transaction { | |
| eventDao.updateEvent(parameter) | |
| } | |
| } |
This file contains hidden or 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
| curl -XPOST -H 'Content-Type: application/json' 'http://localhost:9202/some_index/_update_by_query' -d '{ | |
| "script" : "ctx._source.remove(\"some_field\")" | |
| }' |
This file contains hidden or 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 | |
| #Usage in docker-compose.yml: | |
| # scripts: | |
| # build: scripts | |
| # depends_on: | |
| # - "app-tomcat" | |
| # command: sh -c '/wait-for.sh app-tomcat:8080 -- sh /entrypoint.sh' | |
| # | |
| #entrypoint.sh is run after script connect to application /health endpoint |
This file contains hidden or 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
| #Install arch on usb, it have script (arch-chroot) , its very usefull (adds /dev /proc /sys mounts and more) | |
| #When on live usb run: | |
| sudo pacman -S lvm2 | |
| sudo vgchange -a y | |
| #Now you are able to see LVM drives and mount them | |
| #Boot volume is on separte partition | |
| #Prepare and mount volumes: | |
| sudo mkdir /newroot | |
| sudo mount /dev/yourVG/rootLV /newroot | |
| sudo mount /dev/yourbootpartition /newroot/boot |
This file contains hidden or 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
| def jobName = "APP-RELEASE" | |
| def job = Jenkins.instance.getItem(jobName) | |
| job.getBuilds().each { it.delete() } | |
| // uncomment these lines to reset the build number to 1: | |
| job.nextBuildNumber = 1 | |
| job.save() |