{"id":16436,"date":"2014-12-20T16:02:37","date_gmt":"2014-12-20T10:32:37","guid":{"rendered":"http:\/\/www.tothenew.com\/blog\/?p=16436"},"modified":"2014-12-20T16:16:08","modified_gmt":"2014-12-20T10:46:08","slug":"grails-performance-optimization-unique-constraint","status":"publish","type":"post","link":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/","title":{"rendered":"Grails performance optimization &#8211; Unique constraint"},"content":{"rendered":"<p>Grails unique constraint is very powerful way to check duplicate keys in any DBMS, but it has some impact on application performance. Lets check it by one example:<\/p>\n<p>Suppose we have one domain having the following structure:<\/p>\n<p>[code]<\/p>\n<p>class User {<\/p>\n<p>String firstName<br \/>\nString lastName<br \/>\nString emailId<\/p>\n<p>static constraints = {<br \/>\n     emailId nullable: false, blank: true, unique: true, email: true<br \/>\n  }<br \/>\n}<\/p>\n<p>[\/code]<\/p>\n<p>To check database queries for this transaction enable the logging sql into Datasource.groovy. This will print all\u00a0database\u00a0queries trigger by grails application.<\/p>\n<p>[code]<\/p>\n<p>dataSource {<br \/>\nusername = &#8221;<br \/>\npassword = &#8221;<br \/>\ndbCreate = &#8216;create-drop&#8217; \/\/ one of &#8216;create&#8217;, &#8216;create-drop&#8217;, &#8216;update&#8217;, &#8216;validate&#8217;, &#8221;<br \/>\nurl = &#8216;jdbc:mysql:\/\/localhost:3306\/db_test?autoReconnect=true&#8217;<br \/>\nloggingSql\u00a0= true<br \/>\n}<\/p>\n<p>[\/code]<\/p>\n<p>We can also log sql for a piece of code as well, read this <a href=\"http:\/\/www.tothenew.com\/blog\/log-sql-in-grails-for-a-piece-of-code\/\" title=\"Log Sql for piece of code\" target=\"_blank\">blog<\/a>.<br \/>\nNow create object of User domain and save it.<\/p>\n<p>[code]<br \/>\nUser user = new User(firstName: &#8216;Deepak&#8217;, lastName: &#8216;Mittal&#8217;, emailId: &#8216;deepak.krmittal@intelligrape.com&#8217;)<br \/>\nuser.save(flush: true)<br \/>\n[\/code]<br \/>\nIn case, your unique validation pass and\u00a0if you check your console, then there are 3 queries triggered by grails application :<\/p>\n<p>[code]<\/p>\n<p>Hibernate: select this_.id as id1_3_0_, this_.version as version2_3_0_, this_.email_id as email_id3_3_0_, this_.first_name as first_na4_3_0_, this_.last_name as last_nam5_3_0_ from user this_ where this_.email_id=?<br \/>\nHibernate: select this_.id as id1_3_0_, this_.version as version2_3_0_, this_.email_id as email_id3_3_0_, this_.first_name as first_na4_3_0_, this_.last_name as last_nam5_3_0_ from user this_ where this_.email_id=?<br \/>\nHibernate: insert into user (version, email_id, first_name, last_name) values (?, ?, ?, ?)<\/p>\n<p>[\/code]<\/p>\n<p>This might be a bug but we can fix it as well using following solution code:<\/p>\n<p>[code]<\/p>\n<p>User user = new User(firstName: &#8216;Deepak&#8217;, lastName: &#8216;Mittal&#8217;, emailId: &#8216;deepak.krmittal@intelligrape.com&#8217;)<\/p>\n<p>if(user.validate() &amp;&amp; user.save(flush: true, validate: false)) {<br \/>\n    println(&#8216;Success&#8217;)<br \/>\n} else {<br \/>\n    println(&#8216;Error&#8217;)<br \/>\n}<\/p>\n<p>[\/code]<\/p>\n<p>When you run this code, then this will trigger only 2 queries like:<\/p>\n<p>[code]<\/p>\n<p>Hibernate: select this_.id as id1_3_0_, this_.version as version2_3_0_, this_.email_id as email_id3_3_0_, this_.first_name as first_na4_3_0_, this_.last_name as last_nam5_3_0_ from user this_ where this_.email_id=?<br \/>\nHibernate: insert into user (version, email_id, first_name, last_name) values (?, ?, ?, ?)<\/p>\n<p>[\/code]<\/p>\n<p>Now your purpose is solved with a little bit optimized code. We can further optimize this code in the next blog.<\/p>\n<p>Code written with Grails 2.4.3.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Grails unique constraint is very powerful way to check duplicate keys in any DBMS, but it has some impact on application performance. Lets check it by one example: Suppose we have one domain having the following structure: [code] class User { String firstName String lastName String emailId static constraints = { emailId nullable: false, blank: [&hellip;]<\/p>\n","protected":false},"author":145,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"iawp_total_views":12,"footnotes":""},"categories":[7],"tags":[29,1576,1579,1577,442,648,1578],"class_list":["post-16436","post","type-post","status-publish","format-standard","hentry","category-grails","tag-gorm","tag-grails-constraints","tag-grails-hibernate","tag-grails-hibernate-query-logging","tag-grails-performance","tag-grails-sql-logging","tag-grails-unique-constraint"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.0.1 - aioseo.com -->\n\t<meta name=\"description\" content=\"Grails unique constraint is very powerful way to check duplicate keys in any DBMS, but it has some impact on application performance. Lets check it by one example: Suppose we have one domain having the following structure: [code] class User { String firstName String lastName String emailId static constraints = { emailId nullable: false, blank:\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Deepak Kumar Mittal\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.0.1\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"TO THE NEW BLOG\" \/>\n\t\t<meta property=\"og:type\" content=\"blog\" \/>\n\t\t<meta property=\"og:title\" content=\"Grails performance optimization \u2013 Unique constraint | TO THE NEW Blog\" \/>\n\t\t<meta property=\"og:description\" content=\"Grails unique constraint is very powerful way to check duplicate keys in any DBMS, but it has some impact on application performance. Lets check it by one example: Suppose we have one domain having the following structure: [code] class User { String firstName String lastName String emailId static constraints = { emailId nullable: false, blank:\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/\" \/>\n\t\t<meta property=\"og:image\" content=\"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png\" \/>\n\t\t<meta property=\"og:image:secure_url\" content=\"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary\" \/>\n\t\t<meta name=\"twitter:site\" content=\"@tothenew\" \/>\n\t\t<meta name=\"twitter:title\" content=\"Grails performance optimization \u2013 Unique constraint | TO THE NEW Blog\" \/>\n\t\t<meta name=\"twitter:description\" content=\"Grails unique constraint is very powerful way to check duplicate keys in any DBMS, but it has some impact on application performance. Lets check it by one example: Suppose we have one domain having the following structure: [code] class User { String firstName String lastName String emailId static constraints = { emailId nullable: false, blank:\" \/>\n\t\t<meta name=\"twitter:image\" content=\"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/grails-performance-optimization-unique-constraint\\\/#article\",\"name\":\"Grails performance optimization \\u2013 Unique constraint | TO THE NEW Blog\",\"headline\":\"Grails performance optimization &#8211; Unique constraint\",\"author\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/deepak-krmittal\\\/#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#organization\"},\"datePublished\":\"2014-12-20T16:02:37+05:30\",\"dateModified\":\"2014-12-20T16:16:08+05:30\",\"inLanguage\":\"en-US\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/grails-performance-optimization-unique-constraint\\\/#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/grails-performance-optimization-unique-constraint\\\/#webpage\"},\"articleSection\":\"Grails, GORM, grails constraints, grails hibernate, grails hibernate query logging, Grails performance, grails sql logging, grails unique constraint\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/grails-performance-optimization-unique-constraint\\\/#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.tothenew.com\\\/blog\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/#listItem\",\"name\":\"Grails\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/#listItem\",\"position\":2,\"name\":\"Grails\",\"item\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/grails-performance-optimization-unique-constraint\\\/#listItem\",\"name\":\"Grails performance optimization &#8211; Unique constraint\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/grails-performance-optimization-unique-constraint\\\/#listItem\",\"position\":3,\"name\":\"Grails performance optimization &#8211; Unique constraint\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/#listItem\",\"name\":\"Grails\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#organization\",\"name\":\"TO THE NEW Blog\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/deepak-krmittal\\\/#author\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/deepak-krmittal\\\/\",\"name\":\"Deepak Kumar Mittal\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/grails-performance-optimization-unique-constraint\\\/#authorImage\",\"url\":\"https:\\\/\\\/newersworld-sf-static.tothenew.net\\\/prod\\\/profilePicFolder\\\/da9e6037-b214-46e2-8db4-ead6ae22187e_310-Deepak-Kumar-Mittal-PROFILEPICTURE.jpeg\",\"width\":96,\"height\":96,\"caption\":\"Deepak Kumar Mittal\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/grails-performance-optimization-unique-constraint\\\/#webpage\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/grails-performance-optimization-unique-constraint\\\/\",\"name\":\"Grails performance optimization \\u2013 Unique constraint | TO THE NEW Blog\",\"description\":\"Grails unique constraint is very powerful way to check duplicate keys in any DBMS, but it has some impact on application performance. Lets check it by one example: Suppose we have one domain having the following structure: [code] class User { String firstName String lastName String emailId static constraints = { emailId nullable: false, blank:\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/grails-performance-optimization-unique-constraint\\\/#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/deepak-krmittal\\\/#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/deepak-krmittal\\\/#author\"},\"datePublished\":\"2014-12-20T16:02:37+05:30\",\"dateModified\":\"2014-12-20T16:16:08+05:30\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/\",\"name\":\"TO THE NEW Blog\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Grails performance optimization \u2013 Unique constraint | TO THE NEW Blog","description":"Grails unique constraint is very powerful way to check duplicate keys in any DBMS, but it has some impact on application performance. Lets check it by one example: Suppose we have one domain having the following structure: [code] class User { String firstName String lastName String emailId static constraints = { emailId nullable: false, blank:","canonical_url":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/#article","name":"Grails performance optimization \u2013 Unique constraint | TO THE NEW Blog","headline":"Grails performance optimization &#8211; Unique constraint","author":{"@id":"https:\/\/www.tothenew.com\/blog\/author\/deepak-krmittal\/#author"},"publisher":{"@id":"https:\/\/www.tothenew.com\/blog\/#organization"},"datePublished":"2014-12-20T16:02:37+05:30","dateModified":"2014-12-20T16:16:08+05:30","inLanguage":"en-US","mainEntityOfPage":{"@id":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/#webpage"},"isPartOf":{"@id":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/#webpage"},"articleSection":"Grails, GORM, grails constraints, grails hibernate, grails hibernate query logging, Grails performance, grails sql logging, grails unique constraint"},{"@type":"BreadcrumbList","@id":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog#listItem","position":1,"name":"Home","item":"https:\/\/www.tothenew.com\/blog","nextItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/category\/grails\/#listItem","name":"Grails"}},{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/category\/grails\/#listItem","position":2,"name":"Grails","item":"https:\/\/www.tothenew.com\/blog\/category\/grails\/","nextItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/#listItem","name":"Grails performance optimization &#8211; Unique constraint"},"previousItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/#listItem","position":3,"name":"Grails performance optimization &#8211; Unique constraint","previousItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/category\/grails\/#listItem","name":"Grails"}}]},{"@type":"Organization","@id":"https:\/\/www.tothenew.com\/blog\/#organization","name":"TO THE NEW Blog","url":"https:\/\/www.tothenew.com\/blog\/"},{"@type":"Person","@id":"https:\/\/www.tothenew.com\/blog\/author\/deepak-krmittal\/#author","url":"https:\/\/www.tothenew.com\/blog\/author\/deepak-krmittal\/","name":"Deepak Kumar Mittal","image":{"@type":"ImageObject","@id":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/#authorImage","url":"https:\/\/newersworld-sf-static.tothenew.net\/prod\/profilePicFolder\/da9e6037-b214-46e2-8db4-ead6ae22187e_310-Deepak-Kumar-Mittal-PROFILEPICTURE.jpeg","width":96,"height":96,"caption":"Deepak Kumar Mittal"}},{"@type":"WebPage","@id":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/#webpage","url":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/","name":"Grails performance optimization \u2013 Unique constraint | TO THE NEW Blog","description":"Grails unique constraint is very powerful way to check duplicate keys in any DBMS, but it has some impact on application performance. Lets check it by one example: Suppose we have one domain having the following structure: [code] class User { String firstName String lastName String emailId static constraints = { emailId nullable: false, blank:","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/www.tothenew.com\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/#breadcrumblist"},"author":{"@id":"https:\/\/www.tothenew.com\/blog\/author\/deepak-krmittal\/#author"},"creator":{"@id":"https:\/\/www.tothenew.com\/blog\/author\/deepak-krmittal\/#author"},"datePublished":"2014-12-20T16:02:37+05:30","dateModified":"2014-12-20T16:16:08+05:30"},{"@type":"WebSite","@id":"https:\/\/www.tothenew.com\/blog\/#website","url":"https:\/\/www.tothenew.com\/blog\/","name":"TO THE NEW Blog","inLanguage":"en-US","publisher":{"@id":"https:\/\/www.tothenew.com\/blog\/#organization"}}]},"og:locale":"en_US","og:site_name":"TO THE NEW BLOG","og:type":"blog","og:title":"Grails performance optimization \u2013 Unique constraint | TO THE NEW Blog","og:description":"Grails unique constraint is very powerful way to check duplicate keys in any DBMS, but it has some impact on application performance. Lets check it by one example: Suppose we have one domain having the following structure: [code] class User { String firstName String lastName String emailId static constraints = { emailId nullable: false, blank:","og:url":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/","og:image":"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png","og:image:secure_url":"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png","twitter:card":"summary","twitter:site":"@tothenew","twitter:title":"Grails performance optimization \u2013 Unique constraint | TO THE NEW Blog","twitter:description":"Grails unique constraint is very powerful way to check duplicate keys in any DBMS, but it has some impact on application performance. Lets check it by one example: Suppose we have one domain having the following structure: [code] class User { String firstName String lastName String emailId static constraints = { emailId nullable: false, blank:","twitter:image":"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png"},"aioseo_meta_data":{"post_id":"16436","title":null,"description":null,"keywords":null,"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"Article","isEnabled":true},"graphs":[]},"schema_type":null,"schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"limit_modified_date":false,"created":"2021-04-30 07:45:54","updated":"2024-02-29 10:17:17","focus_keyword":null,"additional_keywords":null,"truseo_locale":null,"ai":null,"breadcrumb_settings":null,"seo_analyzer_scan_date":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.tothenew.com\/blog\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.tothenew.com\/blog\/category\/grails\/\" title=\"Grails\">Grails<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tGrails performance optimization \u2013 Unique constraint\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/www.tothenew.com\/blog"},{"label":"Grails","link":"https:\/\/www.tothenew.com\/blog\/category\/grails\/"},{"label":"Grails performance optimization &#8211; Unique constraint","link":"https:\/\/www.tothenew.com\/blog\/grails-performance-optimization-unique-constraint\/"}],"_links":{"self":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/16436","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/users\/145"}],"replies":[{"embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/comments?post=16436"}],"version-history":[{"count":0,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/16436\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/media?parent=16436"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/categories?post=16436"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/tags?post=16436"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}