Thursday, October 3, 2019

Mongodb aggregate: convert date to another timezone

Mongo version 3.6 timezone operator in  dateToString

Mongo version 3.4 DateToString and Add:

project()
.and(DateOperators.DateToString.dateOf(ArithmeticOperators.Add.valueOf(DATE).add(offsetMilliseconds))
.toString("%Y-%m-%d")).as(DATE_DAYS);


"dateDays": {
"$dateToString": {
"format": "%Y-%m-%d",
"date": {
"$add": ["$date", -36000000]
}
}
}

Wednesday, July 17, 2019

Totalcommander search exact filename

Total Commander how to search exact filename:

use dot sign at the end


Thursday, March 28, 2019

PROBLEM: Karaf restarting bundles twice at startup with logs:

BlueprintExtender Starting BlueprintContainer destruction process for bundle
LifecycleManager Closing application context OsgiBundleXmlApplicationContext
DependencyWaiterApplicationContextExecutor Shutting down normally appCtx OsgiBundleXmlApplicationContext
OsgiBundleXmlApplicationContext Unpublishing application context OSGi service for bundle
DefaultListableBeanFactory Destroying singletons in 
OsgiServiceFactoryBean Unregistered service 


SOLUTION:
Remove versions in manifest file. A specially for jackson.


Friday, March 15, 2019

Как выделить текст на сайте - отмена блокировки мышки

javascript:(function(){function ats(){var styles='*,p,div{user-select:text !important;-moz-user-select:text !important;-webkit-user-select:text !important;}';jQuery('head').append(jQuery('