Note to self: In order to check out a pull request from either Codeberg or GitHub to the local machine, first get the number ( ID ) of the PR (look it up in the Web UI) and then create a branch and check it out ( BRANCHNAME ): $ git fetch origin pull/$ID/head:$BRANCHNAME $ git checkout $BRANCHNAME Update 26.07.2026 Another solution which allows to fetch updated PRs: Add the following to the…
Motivation In Spring Data Elasticsearch recently a issue was raised to include to possibility to use Elasticsearch SQL . While it is easy with Spring Data Elasticsearch 5.1 to use this directly from within an application, the integration into Spring Data Elasticsearch is more complicated, as the returned values (column definitions and rows) cannot easily and automatically be mapped on to the…
Motivation In the Spring Data Elasticsearch issue tracker recently someone asked if it is possible to access two different Elasticsearch clusters in an application that is using Spring Data Elasticsearch. The reason they needed this weas because that application should do some migration - I assume that data from one cluster should be transferred to a second cluster. In this blog post I will show…
Why? When developing and testing code for Spring Data Elasticsearch I often use the OWASP ZAP proxy to monitor the data that is sent to and returned from Elasticsearch. I now had the situation that I needed to check how the library behaves when the server returns a code 429 (too many requests) status. Rather than trying to set up a test that tries to flood my local Elasticsearch instance, I…
The Problem It recently came to my mind that it might be handy to have a list of all the accounts that I follow on Mastodon. I can surely see them on the web or in any decent client, but as a backup it would be great to have a list to store somewhere. As I already played a little with the Mastodon API I decided to write a short script that downloads a list of user@instance values. And as I am…
Note to self: In order to see which commands (latest on top) were used to create a docker image run: docker history --no-trunc --format 'RUN {{.CreatedBy}}' <image>
Yesterday and today I migrated my web site / blog from Wordpress to Hugo . It was less effort and pain than I had anticipated. It was done with these steps: Install Hugo (I am running on macOS using macPorts, so: sudo port install hugo ) In my wordpress installation, I aded the “Wordpress to Jekyll Exporter” plugin and exported the blog posts to a local zip file. After unzipping this…
I wrote my first programs in the year 1980 on a Commodore PET. Ever since that time, the fascination of software development has not left. After using Pascal, Assembler, C, Perl, C++, PHP and Objective-C I nowadays work mainly with Kotlin and Java as programming languages. Spring Data Elasticsearch project lead since 2019. For comments on my posts, use the email or Mastodon links provided in the…
Who we are Our website address is: https://www.sothawo.com . What personal data we collect and why we collect it We do not collect any from our visitors. Cookies We do not send or store any cookies. Embedded content from other websites Articles on this site may include embedded content (e.g. videos, images, articles, etc.). Embedded content from other websites behaves in the exact same way as if…
The problem When starting an Elasticsearch instance in version 8 (the current version being 8.7.0) for the first time, the Elasticsearch server is by default automatically configured with a random generated password and a self signed certificate to secure the connection between clients and the Elasticsearch server. The password and the fingerprint for the certificate are shown in the output of the…
The problem In Elasticsearch (the the current version at the time of writing this post is 7.12.1) every index holds exactly one type of data. This type is defined by the index mapping which describes the fields of the index and their types. Spring Data Elasticsearch (the current version is 4.2) automatically maps between a Java class – the entity type – with its properties and the data in the…
A Throwable in Java can have a cause which in turn is a Throwable as well. This cause can have a cause and we can have a chain of Throwable objects which we can follow until a Throwable has no cause. Let me explain this with a small example: 1 class Scratch { 2 public static void main (String [] args) { 3 try { 4 try { 5 int division = divide(4, 0); 6 } catch (Exception e) { 7 throw new…
Just playing with https://artillery.io/ . If you need to see which requests are sent during setting up your test script, set the DEBUG environment variable: DEBUG = http:request,http:response,http:full_body $( npm bin ) /artillery run test.yml
With the release of version 4.1 Spring Data Elasticsearch now supports the index templates of Elasticsearch. Index templates allow the user to define settings, mappings and aliases for indices that are automatically created by Elasticsearch when documents are saved to a not yet existing index. In this blog post I will show how index templates can be used in combination with Spring Data Repository…
Sometimes I like to know what the latest version of a library in maven central is. As I don’t like to always open a browser tab for search but almost always have a terminal window at hand, I just wrote s small script that uses httpie and jq to get the information I want (that’s all one line in the script): #!/usr/bin/env sh http search.maven.org/solrsearch/select rows == 10000 q == " $1 " | jq…
Elasticsearch allows the data, that is stored in a document, to be not only of elementary types, but also of a range of types, see the documentation . With a short example I will explain this range type and how to use it in Spring Data Elasticsearch (the current version being 4.0.3). For this example we want be able to answer the question: “Who was president of the United States of America in the…
A couple of months ago I published the post Using geo-distance sort in Spring Data Elasticsearch 4 . In the comments there came up the question “What about searching within a distance?” Well, this is not supported by query derivation from the method name, but it can easily be done with a custom repository implementation (see the documentation for more information about that). I updated the example…
For some time now there was a bug that the map was not displaying properly on some Windows systems, see mapjfx problems https://codeberg.org/sothawo/mapjfx/issues/36 https://codeberg.org/sothawo/mapjfx/issues/81 It seems this was because of a bug in the WebView from JavaFX https://bugs.openjdk.java.net/browse/JDK-8234471 . Thanks to https://github.com/vewert and https://github.com/Abu-Abdullah…
When using Spring Data Elasticsearch (I am referencing the current version 4.0.2) , normally the name of the index where the documents are stored is taken from the @Document annotation of the entity class – here it’s books : @Document (indexName = "books" ) public class Book { // ... } Recently in a discussion of a Pull Request in Spring Data Elasticsearch, someone told that she needed a…
I just released mapjfx versions 1.33.0 and 2.15.0, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.33.0 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.15.0 </version> </dependency> 1.33.0 is built using Java 8 and 2.15.0 uses Java 11. Circles…
In Spring Data Elasticsearch – at the time of writing, version 4.0 is the current version – the name of an index is normally defined by the @Document annotation on the entity class. For the following examples let’s assume we want to write some log entries to Elasticsearch with our application. We use the following entity: @Document (indexName = "log" ) public class LogEntity { @Id private String…
The release of Spring Data Elasticsearch in version 4.0 (see the documentation) brings two new features that now enable users to use geo-distance sorts in repository queries: The first is a new class GeoDistanceOrder and the second is a new return type for repository methods SearchHit<T> . In this post I will show how easy it is to use these classes to answer questions like “Which pubs are the…
For the last two years a problem was coming up occasionally with some users, that only the top left area of the map is displayed, and the rest is not loading: https://codeberg.org/sothawo/mapjfx/issues/36 https://codeberg.org/sothawo/mapjfx/issues/81 Thanks to the analysis of Martin Stiel in a comment and Victor Ewert in issue 81 it seems that this can be traced to a problem when running the…
I just released mapjfx versions 1.32.0 and 2.14.0, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.32.0 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.14.0 </version> </dependency> 1.32.0 is built using Java 8 and 2.14.0 uses Java 11. Markers…
After working on Spring Data Elasticsearch for nearly a year now, I’m proud that I will have a talk “ Next Level Elasticsearch Integration with Spring Data Elasticsearch ” at Spring I/O 2020 in Barcelona! Edit: Spring I/O is postponed to October 2020 due to Covid-19. Edit 2: Alas the conferebnce was cancelled.
I just released mapjfx versions 1.31.1 and 2.13.1, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.31.1 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.13.1 </version> </dependency> 1.31.1 is built using Java 8 and 2.13.1 uses Java 11. These…
I just released mapjfx version 2.13.0, it will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.13.0 </version> </dependency> I switched back to use Java 11 (LTS) as SceneBuilder is only available for Java 11 ( https://gluonhq.com/products/scene-builder/ ) and libraries built with version 12 or 13 cannot be used in…
I just released mapjfx versions 1.30.0 and 2.11.0, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.30.0 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.11.0 </version> </dependency> 1.30.0 is built using Java 8 and 2.11.0 uses Java 12. In these…
I just released mapjfx versions 1.29.0 and 2.10.0, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.29.0 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.10.0 </version> </dependency> 1.29.0 is built using Java 8 and 2.10.0 uses Java 12. This…
I just released mapjfx versions 1.28.0 and 2.9.0, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.28.0 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.9.0 </version> </dependency> 1.28.0 is bilt using Java 8 and 2.9.0 uses Java 12. These releases…
it is now possible to disable the zoom controls on the Map ( Issue #59 ) using the new introduced configuration object like this: mapView. initialize (Configuration. builder () . showZoomControls ( false ) . build ()); versions 1.27.0 and 2.8.0 will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.27.0 </version>…
I just released mapjfx versions 1.26.3 and 2.7.3, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.26.3 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.7.3 </version> </dependency> These releases contain a fix for the regression that caused…
I just released mapjfx versions 1.26.1 and 2.7.1, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.26.1 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.7.1 </version> </dependency> These releases contain 2 fixes in handling WMS servers (…
I just released mapjfx versions 1.26.0 and 2.7.0, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.26.0 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.7.0 </version> </dependency> When initializing the MapView element, it is now possible to pass…
I just released mapjfx versions 1.25.0 and 2.6.0, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.25.0 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.6.0 </version> </dependency> when zooming out, the world map can show some areas more than…
note to self : sometimes it happens that applications cannot find a camera on my system, although it is definitely built in and not broken. This can be solved by stopping all applications that may be using the camera and then in a terminal run sudo killall VDCAssistant thanks to http://osxdaily.com/2013/12/27/fix-there-is-no-connected-camera-error-mac/ for this solution (check that link for…
just came about this tweet from @cabel: Pro MacBook Pro Tip: have a Touch Bar with Touch ID? If you edit /etc/pam.d/sudo and add the following line to the top… auth sufficient pam_tid.so …you can now use your fingerprint to sudo! Edit 28.05.2019: in iTerm 3.2.9 you have to set under “Preferences/Advanced” the value of “Allow sessions to survive logging out and back in.” to “No” for this to work.
I just released mapjfx versions 1.24.0 and 2.5.0, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.24.0 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.5.0 </version> </dependency> Now slf4j is used as logging framework and zooming by using the…
The latest versions of mapjfx – 1.22.0 and 2.3.0 – have the possibility to have different projections for the map used in OpenLayers. The possible projections are: Web Mercator (EPSG:3857); this is used if no other projection is specified and is the projection that was hardcoded up to now WGS84 (EPSG:4326); this can be set when initializing the MapView object. Check the mapjfx-demo description and…
I just needed to insert line numbers in a file in vim. Thanks to https://vi.stackexchange.com/questions/8179/replace-a-pattern-with-current-line-number I now know how to do this by replacing the start of every line using the following command: :%s/^/\=printf("%4d: ", line('.')) which adds the current line number formatted to 4 characters with leading spaces.
I just released mapjfx versions 1.21.0 and 2.2.0, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.21.0 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.2.0 </version> </dependency> Now it is possible to close CoordinateLines to polygons with a…
I just released mapjfx versions 1.20.1 and 2.1.1, they will be available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.20.1 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.1.1 </version> </dependency> mapjfx now uses OpenLayers version 5.3.0. Version 1.20.1 is built…
The new versions are 1.20.0 and 2.1.o, available in maven central: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.20.0 </version> </dependency> <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 2.1.0 </version> </dependency> Version 1.20.0 is built using OracleJDK8, whereas version 2.1.0 is built with OpenJDK11.
I released mapjfx version 1.19.0 it can be found at maven central, the artifact coordinates are: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.19.0 </version> </dependency> The source is available at GitHub . This version adds support for XYZ map sources. The code was contributed by Erik Jaehne , thanks a lot for that.
I just published a blog post on the codecentric blog site: How to write a Kotlin DSL – e.g. for Apache Kafka and in German: Wie schreibt man eine Kotlin DSL – z.B. für Apache Kafka? Edit 2. May 2023: After the relaunch of the codecentric website, the english version has been lost it seems.
I just released mapjfx version 1.18.0 it should be found shortly at maven central, the artifact coordinates are: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.18.0 </version> </dependency> The source is available at GitHub . The first change in this verison is that the OfflineCache instance now is a Singleton and shared between all instances of MapView…
I just came upon the possibility that in Java it is possible within regular expressions to turn case sensitivity on and off. This is no new feature, it has been there since Java 1.4, but I never saw it before and thought it might be worth a post. So let’s assume I want to have a regular expression which matches the three words “goodbye bLuE SKIES” – the first in lowercase, the second mixed and the…
I just released mapjfx version 1.17.0 it should be found shortly at maven central, the artifact coordinates are: <dependency> <groupId> com.sothawo </groupId> <artifactId> mapjfx </artifactId> <version> 1.17.0 </version> </dependency> The source is available at GitHub . mapjfx now ow uses OpenLayers 4.6.5. As a new feature, the MapView object now emits events whenever the extent of the map…
Recently I was testing some applications in a local kubernetes installation running in minikube , especially the access via an ingress. For this I defined the ingress endpoints using a custom otherwise not existing top level domain to produce names like application1.foobar or application2.foobar . (The list of officially registered TLDs can be found at https://www.iana.org/domains/root/db). Now in…